- implemented Miroslav Lichvars <mlichvar@redhat.com> suggestion
to skip interface updates based on incoming packets
* [Bug 3116] unit tests for NTP time stamp expansion. <perlinger@ntp.org>
+* [Bug 3102] Zero origin issues. HStenn.
* [Bug 3100] ntpq can't retrieve daemon_version <perlinger@ntp.org>
- fixed extended sysvar lookup (bug introduced with bug 3008 fix)
* [Bug 3095] Compatibility with openssl 1.1 <perlinger@ntp.org>
} else if (peer->flip == 0) {
INSIST(0 != hisstratum);
INSIST(STRATUM_UNSPEC != hisstratum);
+
if (0) {
} else if (L_ISZERO(&p_org)) {
+ char *action;
+
+ L_CLR(&peer->aorg);
+ /**/
+ switch (hismode) {
+ /* We allow 0org for: */
+ case UCHAR_MAX:
+ action = "Allow";
+ break;
+ /* We disallow 0org for: */
+ case MODE_UNSPEC:
+ case MODE_ACTIVE:
+ case MODE_PASSIVE:
+ case MODE_CLIENT:
+ case MODE_SERVER:
+ case MODE_BROADCAST:
+ action = "Drop";
+ peer->bogusorg++;
+ peer->flash |= TEST2; /* bogus */
+ break;
+ default:
+ INSIST(!"receive(): impossible hismode");
+ break;
+ }
+ /**/
msyslog(LOG_INFO,
- "receive: Got 0 origin timestamp from %s@%s xmt %#010x.%08x",
- hm_str, ntoa(&peer->srcadr),
+ "receive: %s 0 origin timestamp from %s@%s xmt %#010x.%08x",
+ action, hm_str, ntoa(&peer->srcadr),
ntohl(pkt->xmt.l_ui), ntohl(pkt->xmt.l_uf));
- L_CLR(&peer->aorg);
} else if (!L_ISEQU(&p_org, &peer->aorg)) {
/* are there cases here where we should bail? */
/* Should we set TEST2 if we decide to try xleave? */