Skip site navigation (1)Skip section navigation (2)
Date:      Sun,  2 May 1999 19:20:58 -0700 (PDT)
From:      cliff@steam.com
To:        freebsd-gnats-submit@freebsd.org
Subject:   bin/11458: syslogd does not open UDP socket
Message-ID:  <19990503022058.86BA414DDA@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         11458
>Category:       bin
>Synopsis:       syslogd does not open UDP socket
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun May  2 19:30:00 PDT 1999
>Closed-Date:
>Last-Modified:
>Originator:     cliff skolnick
>Release:        3.1-stable
>Organization:
steam.com
>Environment:
FreeBSD lazlo.internal.steam.com 3.1-STABLE FreeBSD 3.1-STABLE #0: Sun May  2 17
:06:47 PDT 1999     cliff@lazlo.internal.steam.com:/usr/src/sys/compile/lazlo  i
386
>Description:
There is a bug in syslogd which makes it not listen on UDP port 514
unless two "-s" options are given on the command line, which is very
contrary to the man page.  It appears a logic error in syslog.c:397 is
to blame.  The program works as stated if changed to:

        if (SecureMode < 2)

Guess this explains why remote logging stopped on my system, but it is
now working after this change.  Fascist mode is cool, but you better
give people a way out!  More importantly the "-s -s" does the opposite
of the man page :/

Cliff
>How-To-Repeat:

run syslog, check netstat -af inet for something listening on
UDP 514.
>Fix:
*** syslogd.c-orig      Sat May  1 11:49:17 1999
--- syslogd.c   Sun May  2 18:45:51 1999
***************
*** 394,400 ****
                                die(0);
                }
        }
!       if (SecureMode > 1)
                finet = socket(AF_INET, SOCK_DGRAM, 0);
        if (finet >= 0) {
                struct servent *sp;
--- 394,400 ----
                                die(0);
                }
        }
!       if (SecureMode < 2)
                finet = socket(AF_INET, SOCK_DGRAM, 0);
        if (finet >= 0) {
                struct servent *sp;

>Release-Note:
>Audit-Trail:
>Unformatted:


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19990503022058.86BA414DDA>