[ntp:questions] Problem with date since a few hours
Ulrich.Windl at RZ.Uni-Regensburg.DE
Mon Dec 11 13:59:25 UTC 2006
Fabrice <fabrice at raspberry.maison> writes:
> Hi all,
> It seems that I get 1st january 2000 as a date from pool.ntp.org, using
> /usr/sbin/netdate tcp pool.ntp.org
If the code does check validity of time like this, don't be surprised:
memcpy((void *)&tim, buf, sizeof tim);
rem_time = (unsigned long)ntohl(tim) - EPOCH_DEVIATION;
I think back in 1993 I realized that NetWare 3.11 doesn't serve that protocol
correctly (with a similar result than yours)...
Let me quote http://en.wikipedia.org/wiki/TIME_protocol maybe:
>From Wikipedia, the free encyclopedia
Jump to: navigation, search
The TIME service is an Internet protocol defined in RFC 868. Its purpose is to
provide a site-independent, machine readable date and time.
TIME can operate over either TCP or UDP. When operating over TCP, a host
connects to a server that supports the TIME protocol on TCP port 37. The
server then sends the time as 32-bit binary number in network order
representing a number of seconds since 00:00 (midnight) 1 January, 1900
GMT. The host receives the time and closes the connection.
When operating over UDP, the client sends a (typically empty) datagram to UDP
port 37. The server responds with a single datagram of length 4 containing the
time. There is no connection setup or teardown.
In modern practice, the TIME protocol is completely superseded by the Network
time protocol (NTP).''
> Has anyone noticed anything?
More information about the questions