Skip to content

NTP

netverdict models NTP as a deterministic UDP/123 service for lab time-sync scenarios. It tracks configured servers and peers, source selection, stratum, reachability, authentication, access-groups, and show output.

AreaLevelNotes
NTP client/server associationSupportedClients poll configured servers and track reach/sync state.
NTP peer associationSupportedSynchronized peers can serve time to each other.
Stratum solverSupportedMulti-tier stratum cascades and unsynchronized state are modelled.
Best source selectionSupportedLower stratum wins; prefer wins among equal-stratum reachable sources.
Source interfaceSupportedPer-server source overrides global source interface.
AuthenticationBehaviour modelKey ID plus deterministic shared-key token gates replies.
Access groupsSupportedACL-backed serve/access checks apply to structured NTP packets.
Wire fidelityPartialMode-3/mode-4 request/reply semantics, timestamps, and validation are modelled; no real cryptographic MAC.
StandardCoverageNotes
RFC 5905Behaviour modelClient/server and peer synchronization, stratum, timestamps, reachability.
Cisco NTP auth/access syntaxBehaviour modelntp authenticate, keys, trusted keys, access-groups.
FeatureStatusNotes
ntp server <ip>SupportedAdds a configured source.
ntp peer <ip>SupportedAdds a peer association.
preferSupportedPreferred source wins among equal-stratum reachable sources.
version <1-4>SupportedStored/emitted; invalid versions are rejected.
key <id>SupportedSelects authentication key for the association.
source <iface>SupportedPer-association source interface.
ntp source <iface>SupportedGlobal source interface.
ntp master <stratum>SupportedLocal master source.
ntp authenticateSupportedEnables auth enforcement.
ntp authentication-key <id> md5 <secret>Behaviour modelStable token derived from key material.
ntp trusted-key <id>SupportedMarks key as trusted.
ntp access-group serve <acl>SupportedACL-gated service.
ntp update-calendarConfig-backedStored/emitted for config fidelity.
ntp loggingConfig-backedStored/emitted for config fidelity.
Originate timestamp validationSupportedReplies must echo the active client transmit timestamp.
Invalid sample rejectionSupportedInvalid stratum and negative-delay replies are dropped.
CommandIOS-styleJunos-styleVyOS-styleNotes
ntp server 10.0.0.1 prefer version 4 key 7 source Gi0/0Supportedn/aPartialIOS options are stored and emitted.
ntp peer 10.0.0.1 prefer version 4 key 7 source Gi0/0Supportedn/an/aPeer association.
ntp authenticateSupportedn/aPartialEnables auth behaviour.
ntp authentication-key 7 md5 SECRETSupportedn/aPartialShared-key model.
ntp trusted-key 7Supportedn/aPartialTrust list.
ntp access-group serve NTP_SERVESupportedn/an/aACL-gated service.
set system ntp server 10.0.0.10 version 4n/aSupportedn/aJunos commit lowers into canonical services.
set system ntp server 10.0.0.11 prefern/aSupportedn/aJunos preferred source.
set system ntp server 10.0.0.1n/an/aSupportedVyOS parser/import surface.
show ntp statusSupportedSupportedPartialRuntime sync status.
show ntp associationsSupportedSupportedPartialAssociation table.

NTP polling is event-driven. The simulator does not sleep for wall-clock poll intervals; it schedules deterministic exchanges so shared URLs and tests replay the same way.

Access-groups are evaluated against structured NTP packets. If an ACL denies a client, reach remains 0 and the client does not synchronize.

Authentication is a behaviour model, not a real RFC MAC. A request carries the configured key ID plus a stable token derived from algorithm and secret; the server replies only when the trusted key material matches.

Authenticated client and preferred source
configure terminal
ntp authenticate
ntp authentication-key 7 md5 SECRET
ntp trusted-key 7
ntp server 10.0.0.1 prefer version 4 key 7 source Gi0/0
end
show ntp status
show ntp associations

Vendor styles

IOS-style
ntp authenticate
ntp authentication-key 7 md5 SECRET
ntp trusted-key 7
ntp server 10.0.0.1 prefer version 4 key 7 source Gi0/0
show ntp status
show ntp associations
Junos-style
set system ntp server 10.0.0.10 version 4
set system ntp server 10.0.0.11 prefer
commit
run show ntp status
run show ntp associations
VyOS-style
set system ntp server 10.0.0.10
set system ntp server 10.0.0.11 prefer
Serve access-group with local master
configure terminal
access-list 10 permit 10.0.0.0 0.0.0.255
ntp access-group serve 10
ntp master 3
end
show ntp status

Real cryptographic MAC calculation, leap-second handling, orphan mode, manycast and broadcast modes, clock discipline PLL/FLL detail, and vendor-specific poll backoff are not modelled.