JC Denton Apprentice
Joined: 16 Apr 2003 Posts: 151 Location: USA
|
Posted: Sun Oct 07, 2007 11:49 am Post subject: Postfix milter change breaking my MIMEDefang filter |
|
|
So I have this MIMEDefang filter:
Code: | sub filter_begin {
($entity) = @_;
$header_object = $entity->head;
$first_received = $header_object->get('Received', 0);
if ($first_received =~ /\(Authenticated sender: (\w+)\)\s*by mailserver\.mydomain\.com/) {
$auth_user = $1;
$auth_user_length = length($auth_user);
$new_auth_user = 'X' x $auth_user_length;
$first_received =~ s/$auth_user/$new_auth_user/;
$first_received =~ s/\n$//;
action_change_header('Received', "$first_received");
}
} | It basically X's out the authenticated sender's username. MIMEDefang is coupled with Postfix via the milter support in smtpd_milters and non_smtpd_milters.
This filter worked in 2.4.3, but doesn't work in 2.4.5. I enabled MIMEDefang's debug option (-d) and examined the HEADERS temporary file. No received headers on local mail, or authenticated sender (SASL) mail.
Any ideas? I don't see anything in the Postfix changelog to indicate why this is misbehaving now. |
|