From stevesommarsntp at gmail.com Tue Jan 30 18:52:26 2024 From: stevesommarsntp at gmail.com (Steven Sommars) Date: Tue, 30 Jan 2024 12:52:26 -0600 Subject: Extension fields Message-ID: I'm sending NTP mode 3 requests to another person's ntpsec server with one extension field. Field type 0x0, length variable. ntpsec doesn't like this, why? My goal is to create variable length mode 3 requests that will be accepted by ntpsec, chrony and NTP classic. Any suggestions? -------------- next part -------------- An HTML attachment was scrubbed... URL: From halmurray at sonic.net Tue Jan 30 21:09:43 2024 From: halmurray at sonic.net (Hal Murray) Date: Tue, 30 Jan 2024 13:09:43 -0800 Subject: Extension fields Message-ID: <20240130210943.1693E28C25C@107-137-68-211.lightspeed.sntcca.sbcglobal.net> Steven Sommars said: > I'm sending NTP mode 3 requests to another person's ntpsec server with one > extension field. Field type 0x0, length variable. ntpsec doesn't like > this, why? The current code drops a packet when it encounters an extension that it doesn't know about. The only extensions it does know about are for NTS. > My goal is to create variable length mode 3 requests that will be accepted by > ntpsec, chrony and NTP classic. Any suggestions? I don't have any good ideas. What do chrony or NTP classic do? It would seem easy to hack the code to ignore any particular extension type. But that actually gets complicated. Do I have to ignore it when it is in the middle of a NTS clump of requests? ... There is a NONCE extension for NTS. The current code doesn't support that except as part of a NTS collection. It would be possible to support that stand alone. -------- I think we need an extension for shared key authentication. Do you want to work on an RFC to cover simple extensions? Are there other simple things that might get added? What would you call te extension you want? How many variants are there? drop this send it back send back N bytes of ?? Do we really want to add stuff like this to the protocol? On the surface, it seems simple, but if you look carefully the possible interactions between extension types make the code ugly and hence attract bugs. Can we add a rule to avoid that? Or maybe I just have to see a clean/simple way to write the code? -- These are my opinions. I hate spam.