Skip Menu |
 

This queue is for tickets about the Sys-Syslog CPAN distribution.

Report information
The Basics
Id: 78044
Status: resolved
Priority: 0/
Queue: Sys-Syslog

People
Owner: SAPER [...] cpan.org
Requestors: cwilson [...] meadow.net
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.29
Fixed in: 0.30



Subject: Incorrectly requires /etc/services entries for TCP usage
Download (untitled) / with headers
text/plain 219b
The current way the 'check' sub is done for the TCP service *requires* a services entry of syslog/tcp or syslogng/tcp. Neither of these need be true if the port is also specified. UDP suffers from this same problem.
Subject: Re: [rt.cpan.org #78044] Incorrectly requires /etc/services entries for TCP usage
Date: Tue, 14 Aug 2012 18:49:55 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <saper [...] cpan.org>
Download (untitled) / with headers
text/plain 675b
Hello, Chan Wilson wrote via RT: Show quoted text
> The current way the 'check' sub is done for the TCP service *requires* a > services entry of syslog/tcp or syslogng/tcp. > > Neither of these need be true if the port is also specified. > > UDP suffers from this same problem.
Do you mean this part of the code? » https://github.com/maddingue/Sys-Syslog/blob/master/Syslog.pm#L228 It makes a call to getservbyname(), which may indeed look into a /etc/services if your operating system uses one. AFAIK that this is the traditional way for Unix administrators to enable or disable some services not their systems. -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.
Subject: Re: [rt.cpan.org #78044] Incorrectly requires /etc/services entries for TCP usage
Date: Tue, 14 Aug 2012 14:13:52 -0500
To: bug-Sys-Syslog [...] rt.cpan.org
From: Chan Wilson <cwilson [...] meadow.net>
Download (untitled) / with headers
text/plain 1.1k
On 8/14/12 11:50 :16AM, Sébastien Aperghis-Tramoni via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=78044 > > > Hello, > > > Chan Wilson wrote via RT: >
>> The current way the 'check' sub is done for the TCP service *requires* a >> services entry of syslog/tcp or syslogng/tcp. >> >> Neither of these need be true if the port is also specified. >> >> UDP suffers from this same problem.
> > Do you mean this part of the code? > » https://github.com/maddingue/Sys-Syslog/blob/master/Syslog.pm#L228 > > It makes a call to getservbyname(), which may indeed look into a /etc/services if your operating system uses one. AFAIK that this is the traditional way for Unix administrators to enable or disable some services not their systems. > >
It is that section of code (for both TCP and UDP), yes. The bug is, that when you desire to use a syslog connection via TCP, it will *fail* because there is no standard TCP syslog port (as just checked on several recent and vintage unix-like O/S). The check sub should be modified so that if the port is specified, the getservbyname() call is skipped -- it's not needed. --Chan
Subject: Re: [rt.cpan.org #78044] Incorrectly requires /etc/services entries for TCP usage
Date: Wed, 15 Aug 2012 00:14:03 +0200
To: bug-Sys-Syslog [...] rt.cpan.org
From: Sébastien Aperghis-Tramoni <saper [...] cpan.org>
Download (untitled) / with headers
text/plain 1.2k
Chan Wilson wrote via RT: Show quoted text
>> Chan Wilson wrote via RT: >>
>>> The current way the 'check' sub is done for the TCP service *requires* a >>> services entry of syslog/tcp or syslogng/tcp. >>> >>> Neither of these need be true if the port is also specified. >>> >>> UDP suffers from this same problem.
>> >> Do you mean this part of the code? >> » https://github.com/maddingue/Sys-Syslog/blob/master/Syslog.pm#L228 >> >> It makes a call to getservbyname(), which may indeed look into a /etc/services if your operating system uses one. AFAIK that this is the traditional way for Unix administrators to enable or disable some services not their systems.
> > It is that section of code (for both TCP and UDP), yes. > > The bug is, that when you desire to use a syslog connection via TCP, it will *fail* because there is no standard TCP syslog port (as just checked on several recent and vintage unix-like O/S). The check sub should be modified so that if the port is specified, the getservbyname() call is skipped -- it's not needed.
Oh, right. I completely forgot that one can now specify the remote port. Sorry. The code has been fixed and will be in Sys::Syslog version 0.30. Thanks for submitting this bug report. -- Sébastien Aperghis-Tramoni Close the world, txEn eht nepO.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.