| 1 | use 5.014; | ||
| 2 | use warnings; # no default before Perl 5.35 | ||
| 3 | |||
| 4 | package Mail::Qmail::Filter::VerifyFrom; | ||
| 5 | |||
| 6 | our $VERSION = '0.41'; | ||
| 7 | |||
| 8 | use Mo qw(coerce default); | ||
| 9 | extends 'Mail::Qmail::Filter::Base::CalloutVerify'; | ||
| 10 | |||
| 11 | has address_type => 'From'; | ||
| 12 | |||
| 13 | sub filter { | ||
| 14 | my $self = shift; | ||
| 15 | my $header_from = $self->message->header_from or return; | ||
| 16 | my $header_from_address = $header_from->address; | ||
| 17 | $self->callout_verify($header_from_address); | ||
| 18 | } | ||
| 19 | |||
| 20 | 1; | ||
| 21 | |||
| 22 | __END__ |