perl-Mail-DMARC/Mail-DMARC-1.20200214-handle_undef_domains.patch

12 lines
569 B
Diff
Raw Normal View History

diff -Nur --no-dereference Mail-DMARC-1.20200214.old/lib/Mail/DMARC/Base.pm Mail-DMARC-1.20200214/lib/Mail/DMARC/Base.pm
--- Mail-DMARC-1.20200214.old/lib/Mail/DMARC/Base.pm 2020-02-18 00:02:32.000000000 -0500
+++ Mail-DMARC-1.20200214/lib/Mail/DMARC/Base.pm 2022-04-19 15:52:12.805000000 -0400
@@ -265,6 +265,7 @@
sub is_valid_domain {
my ( $self, $domain ) = @_;
+ return 0 unless $domain;
return 0 if $domain !~ /^$RE{net}{domain}{-rfc1101}{-nospace}$/x;
my $tld = ( split /\./, lc $domain )[-1];
return 1 if $self->is_public_suffix($tld);