| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
| |
Sort local variables declarations in these functions.
Submitted by: bde
|
|
|
|
|
|
|
|
|
|
|
|
| |
if the line doesn't match ^<%d>, then treat it as a regular kernel
printf line. Previously if a kernel printf message started with "<"
it would be interpreted as a log message, often with LOG_EMERG
level. This was triggered by some printfs in sys/dev/aic7xxx/, and
can also happen with the partial lines that result if syslogd cannot
keep up with the rate of arrival of kernel messages.
Reviewed by: dwmalone
MFC after: 1 week
|
|
|
|
|
|
|
|
|
|
|
|
| |
is possible for an error to occur while trying to log an error, and
this can result in infinite recursion (or at least until we run out
of stack).
Rather than this, we ignore requests to log an error while logging an
error.
PR: 51253
MFC after: 2 weeks
|
| |
|
| |
|
|
|
|
|
|
|
| |
PR: 51587
Submitted by: Dmitry Sivachenko <mitya@cavia.pp.ru>
Approved by: re (rwatson)
MFC after: 3 days
|
|
|
|
|
|
|
|
|
| |
an incorrect re-implementation.
PR: 52223, 52342
Submitted by: Dan Nelson <dnelson@allantgroup.com>
Approved by: re (bmah/rwatson)
MFC after: 2 days
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. Hostnames were not treated case insensitively in all cases.
2. The method for stripping hostnames when reading the syslog.conf
differed from that when finding the hostname of an incoming request.
This lead to a broken match check. In my case, it meant I had to
have '@scooter.smi.example.com.example.com' to have 'logger.example.com'
properly save messages from 'scooter.smi.sendmail.com'.
3. Add paranoia to cfline() such that it doesn't try to access memory
outside of the bounds of the f_host string.
4. While I am here, get rid of an outdated comment, argv[{0,1,2}] are now
checked for NULL after the strdup() calls.
Reviewed by: dwmalone
MFC after: 1 week
|
| |
|
|
|
|
|
|
|
| |
used to separate multiple host names.
Noted by: Dan Nelson <dnelson@allantgroup.com>
Reviewed by: roberto
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
or host specifications, eg:
!foo,bar
*.* /var/log/only_foo_or_bar.log
!-foo,bar
*.* /var/log/all_except_foo_or_bar.log
Reviewed by: roberto
Not objected to by: arch@
|
|
|
|
|
| |
PR: 45604
Submitted by: Chris Pepper <pepper@rockefeller.edu>
|
|
|
|
| |
Approved by: re
|
|
|
|
| |
Approved by: re
|
|
|
|
|
|
|
| |
as a consequence of a host or program name specification into a common
function, skip_pmessage.
Reviewed by: roberto
|
| |
|
|
|
|
|
|
| |
PR: 42620
Submitted by: Jeff Ito
MFC after: 1 month
|
| |
|
|
|
|
|
|
|
|
| |
revision 1.101 (which did not introduce the bug but made it harder to fix)
PR: misc/40363
Submitted by: David Dunham <dwdunham@isilon.com>
MFC after: 2 weeks
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
that already exists for hosts: being able to specify a section that applies
to every program *except* the one in question.
The normal syntax for program specification is still valid. For the new
capability, one uses:
!-program
Since there is no way to specify a program beginning with a dash in the old
syntax, as it would be interpreted as the case above, the following
alternative syntax to the original capability is provided:
!+program
This shouldn't introduce incompatibilities with any syslogd configuration
in production because -stable's syslogd does not support a dash anywhere in
the program specification.
MFC after: 2 weeks
|
|
|
|
|
|
|
|
|
|
|
| |
for it.
While I'm here, add a the ability to say "!level" in a way which
should be compatible with Linux's syslogd.
PR: 28935
No objections: audit
MFC after: 2 weeks
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
EHOSTDOWN. These are often transient errors (when the remote host
reboots, temporary network problems, etc.), and we'd rather err on the
side of caution and keep trying send messages that never arrive than
just give up.
Note that this is not an implementation of the "back-off" methods
given in the PR. Those just seem too complicated. Why not just keep
trying each time? Trying and failing doesn't really consume
significantly more resources than if we were successful for each
message.
PR: bin/31029
MFC after: 1 week
|
|
|
|
|
|
| |
from a client, accept all printable characters as being part
of the program name, except ':' and '[', because each is a
possible delimiter.
|
|
|
|
|
|
|
|
|
|
| |
do not stop copying it into a buffer when encountering a
non-alphanumerical character. Only stop at unprintable characters.
This makes syslogd work correctly with executables like `interp.bin',
`httpd_old', etc.
PR: misc/40941
MFC after: 1 week
|
|
|
|
| |
MFC after: 1 week
|
| |
|
| |
|
|
|
|
|
| |
instead of hand-rolled equivalent. Add curly braces for symmetry
around else.
|
| |
|
|
|
|
|
| |
don't initialize globals to 0, some reindentation of declarations, some
comments added or reworded.
|
| |
|
|
|
|
|
|
|
| |
Reviewed by: ru
Approved by: ru
Obtained from: OpenBSD
MFC after: 1 week
|
|
|
|
|
|
|
|
| |
PR: misc/34839
Reviewed by: ru
Approved by: ru
Obtained from: OpenBSD
MFC after: 2 weeks
|
| |
|
|
|
|
|
| |
I don't know about anyone else, but the compiler was always aborting
on this stupid warning, and has been doing so for weeks.
|
|
|
|
|
|
| |
is a pipe to another program, or, if specified twice, in all cases.
PR: bin/32420
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
with the old behavior available via the -o option (it might still be
useful if one has many kernels and cares which messages came from
which). If the boot file is not used as the prefix, it is still
logged once at startup.
This change is prompted by the fact that the boot file is now much
longer ("/boot/kernel/kernel" vs. "/kernel"), which significanlty
bloats the syslogd output.
Reviewed by: peter
|
|
|
|
|
|
|
|
| |
netmask.
PR: 31947
Submitted by: Aaron Scarisbrick <aaronsca@hotmail.com>
MFC after: 1 week
|
|
|
|
|
| |
Submitted by: Philippe Charnier <charnier@xp11.frmug.org>
MFC after: 2 weeks
|
|
|
|
|
|
|
| |
Without this call, the hostname check would in some cases yield false
positives.
Pointed out by: ru
|
|
|
|
|
|
|
|
|
|
| |
than really solve it. This approach (inspired by Ruslan's patch) solves
the real problem by stripping the local domain off the host name in the
config line structure.
Also mark a bunch of code sections that either do not check the return value
of a strdup(), malloc() or calloc() call, or do not properly handle a NULL
return.
|
|
|
|
|
|
|
|
| |
1.64, i.e. July of last year. Also fix a minor style bug in the same code.
PR: bin/28634
Pointy hat to: dwmalone
Pointed out by: my buggy DSL router's remote logging facility
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
__unused, and change local variables named `sin' (struct
sockaddr_in) to `sin4'. (`sin' conflicts with the definition of
sin(3), which gcc assumes to be defined even if math.h isn't
included (it's a builtin). This is probably a bug in gcc.)
- Apply WARNS=1. WARNS=2 was not used because this program assigns
string literals to (struct iovec).iov_base for writing, and the only
clean way to silence -Wwrite-strings in that case would be to
strdup() and consequently free() those literals, which I considered
too disruptive.
Reviewed by: bde (partially)
|
| |
|
|
|
|
|
|
|
| |
bind to. This is useful for hosts running jails that need syslog to
maintain an open socket to log to a remote host.
Reviewed by: sheldonh
|
|
|
|
|
|
|
|
| |
Fix some string buffer operations.
Based on: OpenBSD
Reviewed by: audit
MFC after: 2 weeks
|