diff options
author | Guilhem Moulin <guilhem@fripost.org> | 2017-06-13 18:27:55 +0200 |
---|---|---|
committer | Guilhem Moulin <guilhem@fripost.org> | 2017-06-13 18:39:25 +0200 |
commit | 402799906a53aeb3c6feff9b3e98d750acd559e0 (patch) | |
tree | 2036651d23a27ecd53f30efefffe69f6e2bd8ad5 | |
parent | 8a227e93b1f8d6ffbdde9433b99ac820db513c9f (diff) |
postfix-sender-login: strip extension before lookup.
Users can add an extension (following postconf(5)'s
$recipient_delimiter) to the local part of any envelope sender address
already allowed.
-rwxr-xr-x | roles/MSA/files/usr/local/bin/postfix-sender-login.pl | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/roles/MSA/files/usr/local/bin/postfix-sender-login.pl b/roles/MSA/files/usr/local/bin/postfix-sender-login.pl index 3248e15..374cc70 100755 --- a/roles/MSA/files/usr/local/bin/postfix-sender-login.pl +++ b/roles/MSA/files/usr/local/bin/postfix-sender-login.pl @@ -125,6 +125,7 @@ sub process_request($) { $key =~ /\A(.+)@([^\@]+)\z/ or return "NOTFOUND "; # invalid sender address my ($localpart, $domainpart) = ($1, $2); + $localpart =~ s/\+.*//; # strip extension, cf. postconf(5)'s $recipient_delimiter my $ldap = Net::LDAPI::->new( $LDAPI ) // return "TEMP couldn't create Net::LDAPI object"; |