[Ntp] Re: NTPv4 client behavior to ntpv3 reply
Harlan Stenn <stenn@ntp.org> Tue, 30 July 2024 09:18 UTC
Return-Path: <stenn@ntp.org>
X-Original-To: ntp@ietfa.amsl.com
Delivered-To: ntp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id D2672C14F6EE for <ntp@ietfa.amsl.com>; Tue, 30 Jul 2024 02:18:46 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.907
X-Spam-Level:
X-Spam-Status: No, score=-1.907 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ciySlqcAI8fM for <ntp@ietfa.amsl.com>; Tue, 30 Jul 2024 02:18:42 -0700 (PDT)
Received: from chessie.everett.org (chessie.fmt1.pfcs.com [IPv6:2001:470:1:205::234]) by ietfa.amsl.com (Postfix) with ESMTP id AF162C14F600 for <ntp@ietf.org>; Tue, 30 Jul 2024 02:18:42 -0700 (PDT)
Received: from [10.208.75.149] (syn-075-139-201-040.res.spectrum.com [75.139.201.40]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by chessie.everett.org (Postfix) with ESMTPSA id 4WY8mK4zqWzMQhj; Tue, 30 Jul 2024 09:18:41 +0000 (UTC)
Message-ID: <b4e9c5dd-537f-49e3-94a7-99cbd7b4d941@ntp.org>
Date: Tue, 30 Jul 2024 02:18:40 -0700
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
To: rémy decrock <rmdck@rmdck.fr>, ntp@ietf.org
References: <499016286.658450.1722265918944@ichabod.co-bxl> <89926b1b-e909-4f4d-8d13-ecf43d6ddd59@ntp.org> <633834849.717533.1722326425298@ichabod.co-bxl>
Content-Language: en-US
From: Harlan Stenn <stenn@ntp.org>
In-Reply-To: <633834849.717533.1722326425298@ichabod.co-bxl>
Content-Type: text/plain; charset="UTF-8"; format="flowed"
Content-Transfer-Encoding: 8bit
Message-ID-Hash: IJXDIUFXZDQDUZRQIT4SCLGHSCIBNONA
X-Message-ID-Hash: IJXDIUFXZDQDUZRQIT4SCLGHSCIBNONA
X-MailFrom: stenn@ntp.org
X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-ntp.ietf.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header
X-Mailman-Version: 3.3.9rc4
Precedence: list
Subject: [Ntp] Re: NTPv4 client behavior to ntpv3 reply
List-Id: Network Time Protocol <ntp.ietf.org>
Archived-At: <https://mailarchive.ietf.org/arch/msg/ntp/hcihWn5Wthx4jJUSo50-rBowBbQ>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ntp>
List-Help: <mailto:ntp-request@ietf.org?subject=help>
List-Owner: <mailto:ntp-owner@ietf.org>
List-Post: <mailto:ntp@ietf.org>
List-Subscribe: <mailto:ntp-join@ietf.org>
List-Unsubscribe: <mailto:ntp-leave@ietf.org>
On 7/30/2024 1:00 AM, rémy decrock wrote: > Thank you Harlan for the answer. > > The issue behind my question is that I have an equipment that uses a > NTPv4 client and so perform ntpv4 requests to a server that only support > NTPv3 "Windows..." > The server replies to my equipment but with a NTPv3 answer and seems to > be ignored. > Before creating a bug request to the vendor, I want to be sure that this > behavior is illegitimate or not. Ah, thanks for the clarification. The part that won't matter because it's in the NTPv4 spec: https://datatracker.ietf.org/doc/html/rfc5905#page-88 which shows: /* * Initialize header and transmit timestamp. Note that the * transmit version is copied from the receive version. This is * for backward compatibility. */ x.version = r->version; https://datatracker.ietf.org/doc/html/rfc1305 (NTPv3) does it a bit differently: Version Number (NTP.VERSION): This is the current NTP version number (3). and in the "Transmit Procedure" section: ... <$Eroman pkt.version~<<-~roman NTP.VERSION>; ... (please excuse the horrible formatting instructions that are actually part of RFC1305). In the reference implementation, in ntp_proto.c:receive() we see: ... /* * Version check must be after the query packets, since they * intentionally use an early version. */ if (hisversion == NTP_VERSION) { sys_newversion++; /* new version */ } else if ( !(restrict_mask & RES_VERSION) && hisversion >= NTP_OLDVERSION) { sys_oldversion++; /* previous version */ } else { DPRINTF(2, ("receive: drop: RES_VERSION\n")); sys_badlength++; return; /* old version */ } and NTP_OLDVERSION is '1', so as long as you don't have 'restrict version' in your ntp.conf file you should be fine. H > Le 30 juil. 2024 à 02:09, Harlan Stenn <stenn=40ntp.org@dmarc.ietf.org> > a écrit : >> On 7/29/2024 8:11 AM, rémy decrock wrote: >> > Hello, >> > >> > I have a question about the NTP v4-v3 compatiblity. >> > According to the RFC https://datatracker.ietf.org/doc/rfc5905/, <https://datatracker.ietf.org/doc/rfc5905/,> v3 and >> > v4 are compatible. >> > By compatible, I understand that if a client perform an NTPv3 request >> > to a NTPv4 server, this one is able to answer in an understandable way >> > to the client. >> > But what if a NTPv4 client receives an NTPv3 reply to his NTPv4 requests? >> >> "It depends." I say this because the reference implementation replies >> with the packet format it knows about, using the version field from the >> request. So you will not see the case you describe from the reference >> implementation. We took great pains to make sure clients and servers >> running different NTP versions would interoperate successfully. >> >> If the V3 server was written by somebody else, it will behave the way it >> will behave. >> >> The first/early release of NTPv4 happened before February 1998. >> >> The last release of NTPv3 was in November of 1998. >> >> There were no interoperability complaints around the switch from v3 to v4. >> >> NTPv3 has not been supported for over 25 years' time. I gotta wonder >> how many v3 servers are actually still running out there. >> >> > Thanks. >> > >> > _______________________________________________ >> > ntp mailing list -- ntp@ietf.org <mailto:ntp@ietf.org> >> > To unsubscribe send an email to ntp-leave@ietf.org <mailto:ntp-leave@ietf.org> >> -- >> Harlan Stenn <stenn@ntp.org> >> The NTP Project is part of >> https://www.nwtime.org <https://www.nwtime.org>/ - be a member! >> >> _______________________________________________ >> ntp mailing list --ntp@ietf.org <mailto:ntp@ietf.org> >> To unsubscribe send an email tontp-leave@ietf.org <mailto:ntp-leave@ietf.org> -- Harlan Stenn <stenn@ntp.org> The NTP Project is part of https://www.nwtime.org/ - be a member!
- [Ntp] Re: NTPv4 client behavior to ntpv3 reply Harlan Stenn
- [Ntp] NTPv4 client behavior to ntpv3 reply rémy decrock
- [Ntp] Re: NTPv4 client behavior to ntpv3 reply rémy decrock
- [Ntp] Re: NTPv4 client behavior to ntpv3 reply Harlan Stenn
- [Ntp] Re: NTPv4 client behavior to ntpv3 reply Martin Burnicki