| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r314659:
usr.sbin: normalize paths using SRCTOP-relative paths or :H when possible
This simplifies make logic/output
r314676:
Fix build after r314656
Some of the changes I introduced to use .ALLSRC were correct in spirit,
but incorrect in reality -- in particular, ../Makefile.inc hadn't been
pulled in via bsd.init.mk (via bsd.lib.mk, bsd.prog.mk), so the value
of .ALLSRC (evaluated immediately) was empty. .include bsd.init.mk
explicitly so we can be certain that the values used as dependencies in
the targets are defined when the target recipe has been evaluated.
Reminder: thou shalt separate out separate functional changes before
committing them.
(YUGE) Pointyhat to: ngie
In collaboration with: bdrewery
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
r308139:
cron(8): add support for /etc/cron.d and /usr/local/etc/cron.d
For automation tools it is way easier to maintain files in directories rather
than modifying /etc/crontab.
The files in those directories are in the same format as /etc/crontab
Reviewed by: adrian
MFC after: 2 weeks
Relnotes: yes
Sponsored by: Gandi.net
Differential Revision: https://reviews.freebsd.org/D8400
r308157:
Fix typo in cron(8) date
Reported by: jilles
r308158:
Allow symlinks to be followed in cron.d directories and fix detection of
regular files on NFS
Reported by: jilles
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Off by default, build behaves normally.
WITH_META_MODE we get auto objdir creation, the ability to
start build from anywhere in the tree.
Still need to add real targets under targets/ to build packages.
Differential Revision: D2796
Reviewed by: brooks imp
|
| | |
|
| | |
|
| |\ \
| |/ /
|/| | |
|
| |/
| |
| |
| | |
Requested by: Simon Gerraty <sjg@juniper.net>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
requests, default to the previous 60-seconds scheduling method
unless there is any @every_second entries to conserve CPU cycles and
power.
This change also improves scheduling in the default mode by running
as close to the beginning of the minnute as possible by replacing
sleep(3) with nanosleep(2). Previously, the tasks would run anywhere
within the first second of the minute and that offset drifted back
and forth each time cron(8) was engaged.
MFC after: 1 month
|
| |
| |
| |
| | |
Pointy hat to: sobomax
|
| |
| |
| |
| | |
Requested by: few
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
only available via the new @every_second shortcut. ENOTIME to
implement crontab(5) format extensions to allow more flexible
scheduling.
In order to address some concerns expressed by Terry Lambert
while discussing the topic few years ago, about per-second cron
possibly causing some bad effects on /etc/crontab by stat()ing
it every second instead of every minute now (i.e. atime update),
only check that database needs to be reloaded on every 60-th
loop run. This should be close enough to the current behaviour.
Add "@every_minute" shortcut while I am here.
MFC after: 1 month
|
|/ |
|
| |
|
|
|
|
| |
MFC after: 3 days
|
|
|
|
| |
MFC after: 3 days
|
|
|
|
|
|
| |
Tested with: make universe
MFC after: 3 days
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
by unavailable accounts, e.g., those locked, expired, not allowed in at
the moment by nologin(5), or whatever, depending on cron's pam.conf(5).
This applies to personal crontabs only, /etc/crontab is unaffected.
In other words, now the account management policy will apply to
commands scheduled by users via crontab(1) so that a user can no
longer use cron(8) to set up a delayed backdoor and run commands
during periods when the admin doesn't want him to.
The PAM check is done just before running a command, not when loading
a crontab, because accounts can get locked, expired, and re-enabled
any time with no changes to their crontabs. E.g., imagine that you
provide a system with payed access, or better a cluster of such
systems with centralized account management via PAM. When a user
pays for some days of access, you set his expire field respectively.
If the account expires before its owner pays more, its crontab
commands won't run until the next payment is made. Then it'll be
enough to set the expire field in future for the commands to run
again. And so on.
Document this change in the cron(8) manpage, which includes adding
a FILES section and touching the document date.
X-Security: should benefit as users have access to cron(8) by default
|
|
|
|
|
|
|
|
| |
as crontab(5) states it can be. This is supported by all vixie-cron derived
implementations; not sure why FreeBSD was any different.
PR: bin/106442
MFC after: 2 weeks
|
|
|
|
|
|
| |
rather than mis-parsing them as "X".
MFC after: 1 day
|
|
|
|
|
|
|
| |
Note, that when cron(8) cannot create pidfile, it'll exit. I didn't
changed this behaviour, but its better to ignore errors other than
EEXIST, so daemon can be started on systems where /var/ file system
doesn't support locking (like NFS without rpc.lockd(8)).
|
|
|
|
|
|
|
|
|
|
| |
entry having stepping value of zero can cause crontab to hang there,
and if the main crontab is being changed in this way, then cron(8)
will keep spining.
Obtained from: OpenBSD [src/usr.sbin/cron/entry.c,v 1.17]
PR: 68683 (my own, but forgot to commit it...)
MFC After: 1 week
|
| |
|
|
|
|
| |
any fake value.
|
|
|
|
|
|
|
|
| |
assignment even if it is not quoted (as advertised by the man page).
This fixes a regression wrt RELENG_4 introduced in rev. 1.11.
Problem noted and patch tested by: CHOI Junho <cjh@kr.FreeBSD.org>
Reviewed by: roberto
|
|
|
|
|
|
|
|
| |
for any reason other than ENOENT (think resource limits). Close allow and
deny files before allowed() returns to stop the user's EDITOR being able to
read them.
Obtained from: OpenBSD (partially)
|
|
|
|
|
|
|
|
|
|
|
| |
line as an environment variable assignment, is broken
and not conformant to its description in the manual page.
I think it is worthwhile to have that fix in 4.6.
PR: bin/38374
Submitted by: Thomas Quinot <thomas@cuivre.fr.eu.org>
MFC after: 2 days
|
| |
|
|
|
|
|
|
|
|
| |
I missed this as part of the fix to the PR below.
PR: 31265
Submitted by: Matthew D. Fuller <fullermd@over-yonder.net>
MFC after: 1 week
|
|
|
|
|
|
|
|
| |
monthly and weekly, respectively. Also fix the @yearly shortcut so
that it doesn't execute daily during January. OpenBSD and NetBSD also
appear to have this bug.
PR: bin/21152
|
|
|
|
|
|
| |
by invalid input in /etc/crontab.
MFC after: 2 days
|
|
|
|
|
| |
These are not perfectly in agreement with each other style-wise, but they
are orders of orders of magnitude more consistent style-wise than before.
|
|
|
|
| |
Submitted by: Mark Peek <mark@whistle.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
e->cmd. free_entry() now does the right thing with
partially-initialized structures.
load_entry(): Don't call env_free() on e->envp throughout the routine
before jumping to eof; the free_entry() call at that label will take
care of it. The previous behavior resulted in e->envp being free'd
twice (well, the second time would usually result in a crash, but
that's besides the point); once in load_entry(), and once in
free_entry() after the former called the latter. Also note that the
check added to free_entry() (above) doesn't help, since e->envp wasn't
reset to NULL after env_free().
Submitted by: Mark Peek <mark@whistle.com>
|
|
|
|
|
|
|
| |
use free_entry() instead of free() to free a struct _entry.
PR: 28108
Submitted by: Mark Peek <mark@whistle.com>
|
|
|
|
| |
Use _PATH_* where where possible.
|
| |
|
|
|
|
|
|
| |
Rev 1.8 made the type consistently incorrect.
Noted by: Ben Smithurst <ben@scientia.demon.co.uk>
|
|
|
|
|
|
|
|
|
|
|
| |
allocated memory was instead pointed to a static string. A later
free() on the value of the pointer was a possible source of reported
"warning: pointer to wrong page" messages from cron.
Use consistent types in sizeof when malloc'ing memory for the
environment.
PR: kern/12248, bin/11169, bin/9722
|
|
|
|
|
|
|
|
| |
Fix setting of "hour" bitmap when @hourly keyword is specified.
MFC candidate after 4.0-RELEASE.
Problem-found-by: Sheldon Hearn <sheldonh@uunet.co.za>
|
| |
|
|
|
|
|
| |
PR: 9506
Submitted by: Peter Jeremy <peter.jeremy@alcatel.com.au>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use getpwnam before getpwuid since two users with same uids can exists
(affects new login classes code only)
The same fixes as in inetd: by default run `system crontab things' with
daemon login class now, not restrict them to user class breaking
compatibility with old way (so-called nobody limits problem)
Implement user[:group][/login-class] syntax in system crontab
for more flexible control (the same as in inetd)
|
| |
|
|
|
|
|
|
| |
NOPIC is used to not generate a shared library, not NOSHARED.
Make NOSHARED advisory where appropriate.
Remove bogus NOSHARED (kbdio).
|
| |
|
|
|
|
|
|
|
|
| |
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.
Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.
|
|
|
|
|
|
|
|
|
|
| |
used by OpenBSD. (Quite frankly, I think it's perfectly reasonable to
use snprintf to copy strings, given that the semantics for strncpy()
are utterly idiotic and there is no POSIX sstrncpy().)
While I'm at it, incorporate some of OpenBSD's bugfixes to cron.
NOT for 2.2
|
| |
|