summaryrefslogtreecommitdiff
path: root/usr.sbin/syslogd/syslogd.c
AgeCommit message (Collapse)Author
2003-09-19whack getopt ? matching; jeffi@rcn.comTheo de Raadt
2003-08-18Call tzset() to stash the current timezone before we chroot.Todd C. Miller
OK deraadt@ and avsm@
2003-07-31Privilege separated syslog daemon. The child listening to log requests dropsAnil Madhavapeddy
to user _syslogd and chroots itself, while the privileged parent grants it access to open logfiles and other calls it needs. The only difference from existing behaviour is that if syslog.conf changes and syslogd receives a HUP, it will re-exec itself and have two new PIDs. A HUP with an unchanged config will make syslogd reopen logfiles as before. Lots of help and code from deraadt@ , and advice from millert@ Various versions tested by todd, cloder, mpech, markus, tdeval and others
2003-07-08dont silently truncate a domain socket specified via the -p argument;Anil Madhavapeddy
error out instead if its too long. deraadt@ ok
2003-06-02Remove the advertising clause in the UCB license which BerkeleyTodd C. Miller
rescinded 22 July 1999. Proofed by myself and Theo.
2003-05-17Fix typo in last commit, spotted by Brian Poole. That'll teach meTodd C. Miller
to commit on an empty stomach.
2003-05-17Cannot use strlcpy() for strings in struct utmp since they are not guaranteedTodd C. Miller
to be NUL-terminated. Fixes a bug introduced in rev 1.37; noticed by deraadt@
2003-03-21Fix default facility when none is specified (should be LOG_USER,Todd C. Miller
was LOG_UUCP due to a bug); Javier Kohen
2002-12-22fix cutnpaste; from hunter@comsys.com.uaMichael Shalayeff
2002-11-21Add -n option to print message source addresses numerically rather thanChad Loder
symbolically. This saves address->name lookups, which is nice on log servers without a DNS cache. millert@, jakob@ ok
2002-09-06use more socklen_t; pvalchevTheo de Raadt
2002-08-08Pass correct buffer length to snprintf on error condition; ericj@, fgsch@ ok.Aaron Campbell
2002-07-24Sanity check snprintf() return values before using them. It is legal forTodd C. Miller
snprintf(3) to return -1.
2002-07-20ansiTheo de Raadt
2002-06-14spelling; from Brian Poole <raj@cerias.purdue.edu>Todd T. Fries
2002-06-05Double socket receive buffer size; deraadt@ OKTodd C. Miller
2002-05-26pid_t cleanupTheo de Raadt
2002-05-25fix usage; from Sam Smith <S@mSmith.net>.Federico G. Schwindt
2002-02-16Part one of userland __P removal. Done with a simple regexp with some minor ↵Todd C. Miller
hand editing to make comments line up correctly. Another pass is forthcoming that handles the cases that could not be done automatically.
2001-12-02KNF, and remove unneccessary signal blocking and errno saving, since not ↵Theo de Raadt
signal handlers anymore; millert ok
2001-11-17use volatile sig_atomic_t where possible; simply volatile i other placesTheo de Raadt
2001-11-17missing prototype (getmsgbufsize).Markus Friedl
2001-11-17reread config from main loop instead of signal hander; ok deraadt@Markus Friedl
2001-11-16no need for setjmp.hTheo de Raadt
2001-08-03Open files with O_NONBLOCK but turn off non-blocking mode forTodd C. Miller
non-ttys. If write(2) returns EAGAIN just ignore the error and move on. This prevents a locked terminal from causing syslogd grief. If we ever want to support logging to a fifo this will probably have to be revisited.
2001-08-03fix typo; jcs@rt.fmTheo de Raadt
2001-07-27Wall cleanupPeter Valchev
2001-02-07Remove support for #!. It's not intuitive and if you happen to addFederico G. Schwindt
lines as the end of a stock syslog.conf you're going to spend some time figuring why is not working as it should; problem found by riq@core-sdi.com, millert@ ok.
2001-01-19mark remaining signal races which are difficult to fixTheo de Raadt
2001-01-16fix another signal race, and check signal flags even in non-EINTR from ↵Theo de Raadt
select case
2001-01-11fd_set overflows, move races out of signal handlers, and fd_set repairs;Theo de Raadt
some conversations with alejo@core-sdi.com, not sure yet if this is 100% perfect, but i have tested it and it works..
2000-09-13Use vis(3) when escaping non-printable characters instead of doing itTodd C. Miller
(poorly) by hand. Also fixes a potential one byte overflow noted by Solar Designer.
2000-08-17do the save_errno thing, but other races still exist in hereTheo de Raadt
2000-02-22enlarge msgbuf, somewhat line netbsd didTheo de Raadt
1999-07-06union wait -> intTodd C. Miller
wait3 -> waitpid (for portability)
1999-02-03The necessary defs are in paths.h now.Angelos D. Keromytis
1999-01-05careful about sunx.sun_path termination; matter@research.suspicious.orgTheo de Raadt
1998-06-26make it 21 total log devsTheo de Raadt
1998-06-23Fix snprintf return value usage.Todd C. Miller
1998-06-11bogus use of variable for two purposes; guido@gvr.orgTheo de Raadt
1998-05-18MAXHOSTNAMELEN not MAXHOSTNAMELEN+1Theo de Raadt
1998-05-05select on nfds+1, not nfds. ficus@openbsd.orgTodd C. Miller
1998-03-01use sigset_t all over the placeTheo de Raadt
1998-02-11syslogd gets a new -a argument: specify additional AF_UNIX log devicesTheo de Raadt
syslogd should create & listen to. As in "syslogd -a /chroot/dev/log", I'm sure you get the idea.
1998-02-03workaround gethostbyaddr() race in signal handler; more correct fix wouldTheo de Raadt
change SIGHUP handler to only set a flag that the main loop catches. But I'm lazy, and starting to believe noone gives a damn...
1997-11-07Rewrite bad code.bri
Suggested by: Theo
1997-11-06indentTheo de Raadt
1997-11-06indentTheo de Raadt
1997-11-06Understand sections in syslog.conf.bri
Current syslog.conf files are still understood andtreated the same.
1997-09-15F_FORW has no associated fd; init sin_len tooTheo de Raadt