postfix prepends an ipv6 address in the xforward message with 'IPv6:'
we did not remove it and our later checks in who objects fail silently.
we now check if the addr is prefixed with this and remove it to
allow the who objects to work.
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Tested-By: Stoiko Ivanov <s.ivanov@proxmox.com>
Reviewed-By: Stoiko Ivanov <s.ivanov@proxmox.com>
return 1 if !defined ($from);
+ # postfix prefixes ipv6 addresses with IPv6:
+ if ($ip =~ /^IPv6:(.*)/) {
+ $ip = $1;
+ }
+
foreach my $obj (@$from) {
return 1 if $obj->who_match($addr, $ip, $ldap);
}