pub fn validate_ntp_packet_length(
payload: &[u8],
) -> Result<(), NtpPacketParseError>Expand description
ยงNTP Validation Process
- The NTP packet must be at least 48 bytes long.
- The Version Number (VN) in the first byte must be between
0and4. - The Mode field (first byte) must be in
[1, 2, 3, 4, 5](Client, Server, Broadcast, etc.). - The Stratum field must be between
0and15for valid servers. - The Timestamps must be logically consistent.