Commit Graph

10 Commits

Author SHA1 Message Date
ed
b57deea6eb Partially revert r227233.
The privs.h header is not only used by at(1), it's also used by
atrun(8). Just let the code the way it used to be (for now).

Reported by:	kwm, tinderbox
Hat to:		me
2011-11-06 20:30:21 +00:00
ed
a2c6b647f1 Add missing static keywords to at(1).
While there, tidy up the privs.h part, where at.c has to #define to
declare some globals. Also group static and non-static global variables
in at.c.
2011-11-06 17:32:29 +00:00
ru
3527c363d5 SECURITY.
Fixed macros for temporarily relinquishing and restoring setuid/setgid
privileges so that they never change the real user and group IDs of
the calling process.

The setre[ug]id() calls are still used in the REDUCE_PERM macro (with
the r[ug]id arguments of -1) so that the call changes the saved user
and group IDs of the process to that specified.

Also, the panic() and perr() functions had insufficient privileges to
delete the problematic file under /var/at.
2001-09-04 16:15:51 +00:00
charnier
345f916537 Correct use of .Nm, .Em, .Ev
Add rcsid. Use errx instead of fprintf + exit.
Various spelling fixes.
1999-12-05 19:57:14 +00:00
ache
5a4e23dc5e Upgrade to 2.9 1995-08-21 12:34:18 +00:00
rgrimes
a14d555c87 Remove trailing whitespace. 1995-05-30 06:41:30 +00:00
ache
7fa24f3661 Remove setre* hacks, we have working thing now 1995-04-27 19:27:42 +00:00
ache
01787c4b0d Fight over non-working setruid 1995-04-15 22:08:10 +00:00
ache
3ec57b4b68 Upgrade. 1995-04-12 02:42:39 +00:00
nate
bef6395210 Added at/atrm/atq/batch from Linux as hacked by Chris Demetriou. 1994-01-05 01:09:14 +00:00