+sub sanitize_address($$){
+ my $hdrname=shift;
+ my $val=shift;
+
+ if ($hdrname =~ qr/From|To|Reply-To|CC/){
+ my @addrs=Email::Address->parse($val);
+ foreach my $addr (@addrs){
+ $addr->address("DELETED");
+ }
+ $val=join(",",map {$_->format;} @addrs);
+ }
+ return $val;
+ }
+