[Nagiosplug-devel] [ nagiosplug-Patches-1667488 ] check_dhcp: server identifier(54) as offerer/siaddr
SourceForge.net
noreply at sourceforge.net
Fri Apr 20 19:26:21 CEST 2007
Patches item #1667488, was opened at 2007-02-23 22:54
Message generated for change (Comment added) made by hweiss
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=397599&aid=1667488&group_id=29880
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Bugfix
Group: None
>Status: Closed
>Resolution: Accepted
Priority: 5
Private: No
Submitted By: denis knauf (deac-)
Assigned to: Holger Weiss (hweiss)
Summary: check_dhcp: server identifier(54) as offerer/siaddr
Initial Comment:
check_dhcp doesn't use server identifier (54) as server (siaddr), but this is the real serveraddresse.
source is only the address of the relay-dhcp (giaddr).
this patch adds the server_identifier as siaddr.
btw. please "ident" your code. it's so terrible to patch this files, if somebody wrotes such unreadable code. thanks.
----------------------------------------------------------------------
>Comment By: Holger Weiss (hweiss)
Date: 2007-04-20 19:26
Message:
Logged In: YES
user_id=759506
Originator: NO
JFTR, the plugin does not use 'giaddr' as the server address, it uses
'siaddr', which however also isn't (necessarily) correct:
| DHCP clarifies the interpretation of the 'siaddr' field as the
| address of the server to use in the next step of the client's
| bootstrap process. A DHCP server may return its own address in the
| 'siaddr' field, if the server is prepared to supply the next
| bootstrap service (e.g., delivery of an operating system executable
| image). A DHCP server always returns its own address in the 'server
| identifier' option.
[ ftp://ftp.fu-berlin.de/doc/rfc/rfc2131.txt ]
So, you're right, we should use the 'server identifier' option instead. I
committed your patch (slightly modified) to CVS.
Dankeschön, Holger
----------------------------------------------------------------------
Comment By: denis knauf (deac-)
Date: 2007-04-18 14:26
Message:
Logged In: YES
user_id=608083
Originator: YES
if nothing happens, everybody thinks, the project is dead.
my patch we (fachhochschule koeln - netzwerkzentrum/university of applied
siences cologne - network operations center) use productive.
we are highliy interested, that this patch is officially in
nagios-plugins.
and i'm interested in a clean coding standard.
for example this: indent -nbfde -nbfda -npsl -nbad -bap -br -nce -bli0
-ncdw -ut -l80 -i4 -ts4 -cbi0 -nss -pcs -cs -bs -saf -sai -saw -nbc -brs
-bls -ppi4 -ci8 -nlp
i had to indent all the code to understand this program and patch one.
then i had to backport it to unclean code. this had taken many time.
----------------------------------------------------------------------
Comment By: Holger Weiss (hweiss)
Date: 2007-04-18 13:59
Message:
Logged In: YES
user_id=759506
Originator: NO
1) We're all doing this on a voluntary basis.
2) Looking into a patch (that is, understanding it, testing it, making
sure that it does the right thing[tm], that it's portable, that it doesn't
introduce subtle side effects, and so on) takes time.
3) Adding such comments and increasing the tracker item priority *without*
an apparent reason generally won't speed things up.
4) Although I personally prefer other styles of indentation than the one
used in check_dhcp.c (but that's just a matter of taste), the critical
point is to be *consistent* with your indentation, which check_dhcp.c *is*.
As a side note, it would be nice to have a consistent indentation style
across *all* plugins, which we currently haven't. However, changing
indentation style has the *big* drawback that it makes cvs diffs which
cross the indentation change unreadable.
5) When contributing patches, it is generally considered bad style to
break such consistency and/or to include changes other than the actual
fix/feature within the same diff.
6) However, thank you for your patch.
----------------------------------------------------------------------
Comment By: denis knauf (deac-)
Date: 2007-04-18 11:16
Message:
Logged In: YES
user_id=608083
Originator: YES
how much time you need to submit this patch to cvs?
i don't understand, that the nagios-plugins-project is so slow.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=397599&aid=1667488&group_id=29880
More information about the Devel
mailing list