[ECOS] Limitations with the SNTP client?

Andrew Lunn andrew@lunn.ch
Wed Nov 8 08:47:00 GMT 2006


On Tue, Nov 07, 2006 at 06:09:42PM -0500, Andre-John Mas wrote:
> Hi,
> 
> After analysing the packets I noticed that the data being sent from
> my reference client were shorter than the one sent from the eCos
> SNTP client. Looking at RFC 2030 it turns out that difference in
> length is to do with the 'KeyIdentifier' and the 'Message Digest',
> both of which are optional.
> 
> I confirmed with another client (MacOS X) that it worked too
> with the Solaris server. MacOS X also omits the 'KeyIdentifier' and
> the 'Message Digest' in the request.
> 
> Changing the SNTP client on eCos to also omit those fields resulted
> in a response from the SNTP server on the Solaris machine. Linux
> probably handles nulled filled values for these two fields, whereas
> Solaris seems to consider them invalid.
> 
> Given this observation and the fact that they are even set to anything by eCos, is there any reason for including them in the
> NTP_PACKET
> structure?

They are at least initialized to zero. Any SNTP server should ignore
these fields anyway since only NTP uses it. I also checked RFC2030 and
RFC1305. It does not indicate when the fields should/should not be
included in the packet. So it seems to be it is ambiguous and really
the server should handle both cases.

However, since the fields are not used, it seems reasonable to remove
them. Please submit a patch with a ChangeLog entry.

      Andrew

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss



More information about the Ecos-discuss mailing list