From: Ian Kelling Date: Sun, 3 May 2020 02:22:54 +0000 (-0400) Subject: fix for abbreviated ipv6 X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;ds=inline;p=p0f-client-exim.git fix for abbreviated ipv6 --- diff --git a/p0f-client.c b/p0f-client.c index d53bda6..ea815fd 100644 --- a/p0f-client.c +++ b/p0f-client.c @@ -73,10 +73,15 @@ static void parse_addr6(char* str, u8* ret) { while (isxdigit(*str)) str++; if (*str) str++; + // ian: added this to get beyond :: + if (*str && !isxdigit(*str)) str++; } - if (seg != 8) FATAL("Malformed IPv6 address (don't abbreviate)."); + // iank: commented. exim abbreviates but its consistent. and ip addr is only used + // to identify host, some misplaced leading zeros will not end up making 2 + // ipv6 addresses from the internet be the same in practice. + //if (seg != 8) FATAL("Malformed IPv6 address (don't abbreviate)."); }