projects
/
p0f-client-exim.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
43fb5a9
)
fix for abbreviated ipv6
master
author
Ian Kelling
<iank@fsf.org>
Sun, 3 May 2020 02:22:54 +0000
(22:22 -0400)
committer
Ian Kelling
<iank@fsf.org>
Sun, 3 May 2020 02:22:54 +0000
(22:22 -0400)
p0f-client.c
patch
|
blob
|
blame
|
history
diff --git
a/p0f-client.c
b/p0f-client.c
index d53bda6a23c25bdbc17babf91684d61e21d9d1e8..ea815fdc741104909508a9ec558d3d7dea2dc6b9 100644
(file)
--- 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++;
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).");
}
}