In NTPv4 (RFC 5905) the refid field for stratum > 1 is an IPv4 address
or first 32 bits of MD5 sum of an IPv6 address. It's not possible to
tell which of the two it actually is. Print the field as a hexadecimal
number in order to not confuse refids generated from IPv6 addresses with
IPv4 addresses.
return;
default:
- ND_PRINT((ndo, "%s", ipaddr_string(ndo, &(bp->refid))));
+ /* In NTPv4 (RFC 5905) refid is an IPv4 address or first 32 bits of
+ MD5 sum of IPv6 address */
+ ND_PRINT((ndo, "%08x", EXTRACT_32BITS(&bp->refid)));
break;
}