Skip to content

Commit

Permalink
Exacttarget improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
bigio committed Feb 1, 2024
1 parent d39bbfe commit d31e199
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
4 changes: 3 additions & 1 deletion Esp-rbl.cf
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,9 @@ if (version >= 4.000000)
header __ESP_EXACTT_RBL eval:check_hashbl_tag('exacttarget.espbl.snb.it/A', 'raw', 'EXACTTARGET_ID', '^127\.')
header __ESP_EXACTT_UID x-messageKey =~ /undelivered\+(?<EXACTTARGET_UID>\d+)\+(?:\d+)\@pd25\.com/
header __ESP_EXACTT_URBL eval:check_hashbl_tag('exacttarget.espbl.snb.it/A', 'raw', 'EXACTTARGET_UID', '^127\.')
meta RBL_ESP_EXACTTARGET ( __ESP_EXACTT_CSA && __ESP_EXACTT_SFMC && ( __ESP_EXACTT_RBL || __ESP_EXACTT_URBL ) )
header __ESP_EXACTT_RET EnvelopeFrom:addr =~ /bounce\-(?:\d+)_HTML\-(?:\d+)\-(?<EXACTTARGET_RID>\d+)\-(?:\d+)\-(?:\d+)\@/
header __ESP_EXACTT_RRBL eval:check_hashbl_tag('exacttarget.espbl.snb.it/A', 'raw', 'EXACTTARGET_RID', '^127\.')
meta RBL_ESP_EXACTTARGET ( __ESP_EXACTT_CSA && __ESP_EXACTT_SFMC && ( __ESP_EXACTT_RBL || __ESP_EXACTT_URBL || __ESP_EXACTT_RRBL ) )
describe RBL_ESP_EXACTTARGET Esp ExactTarget Id blacklist
tflags RBL_ESP_EXACTTARGET net

Expand Down
7 changes: 5 additions & 2 deletions Esp.pm
Original file line number Diff line number Diff line change
Expand Up @@ -819,9 +819,12 @@ sub esp_exacttarget_check {
# x-messageKey: [email protected]
$fid = $pms->get("x-messageKey", undef);
return if not defined $fid;
if($fid =~ /(\d+)\-(?:\d+)\-(?:\d+)/) {
my $envfrom = $pms->get("Return-Path", undef);
if(defined $fid and $fid =~ /(\d+)\-(?:\d+)\-(?:\d+)/) {
$uid = $1;
} elsif ($fid =~ /undelivered\+(\d+)\+(?:\d+)\@pd25\.com/) {
} elsif (defined $fid and $fid =~ /undelivered\+(\d+)\+(?:\d+)\@pd25\.com/) {
$uid = $1;
} elsif (defined $envfrom and $envfrom =~ /bounce\-(?:\d+)_HTML\-(?:\d+)\-(\d+)\-(?:\d+)\-(?:\d+)\@/) {
$uid = $1;
}
return if not defined $uid;
Expand Down

0 comments on commit d31e199

Please sign in to comment.