Mail archive
alpine-devel

Re: [alpine-devel] SpamAssassin DNSBL tests fail after changes in perl (patch included)

From: Johan Dahlberg <johan_at_dnix.se>
Date: Thu, 25 Dec 2014 13:32:48 +0200

On Thu, 25 Dec 2014 at 10:55:08, Leonardo Arena wrote:
> On lun, 2014-12-22 at 21:11 +0200, Johan Dahlberg wrote:
> > On Mon, 22 Dec 2014 at 19:05:29, Johan Dahlberg wrote:
> > > On Mon, 22 Dec 2014 at 17:12:13, Leonardo Arena wrote:
> > > > On mer, 2014-12-17 at 11:49 +0200, Johan Dahlberg wrote:
> > > > > --- SpamAssassin/DnsResolver.pm.bak
> > > > > +++ SpamAssassin/DnsResolver.pm
> > > > > _at_@ -204,8 +204,10 @@
> > > > > _at_ns_addr_port = @{$self->{conf}->{dns_servers}};
> > > > > dbg("dns: servers set by config to: %s", join(',
> > > > > ',_at_ns_addr_port));
> > > > > } elsif ($res) { # default as provided by Net::DNS, e.g.
> > > > > /etc/resolv.conf
> > > > > - _at_ns_addr_port = map(untaint_var("[$_]:" . $res->{port}),
> > > > > - _at_{$res->{nameservers}});
> > > > > + my _at_ns = $res->UNIVERSAL::can('nameservers') ? $res->nameservers
> > > > > + :
> > > > > _at_{$res->{nameservers}};
> > > > > + my $port = $res->UNIVERSAL::can('port') ? $res->port :
> > > > > $res->{port};
> > > > > + _at_ns_addr_port = map(untaint_var("[$_]:" . $port), @ns);
> > > > > dbg("dns: servers obtained from Net::DNS : %s", join(',
> > > > > ',_at_ns_addr_port));
> > > > > }
> > > > > return _at_ns_addr_port;
> > > >
> > > >
> > > > Hi,
> > > > thanks for your contribution.
> > > > Would it be possible to have a GIT patch? It would be easier and 100%
> > > > error-free to apply.
> > > > Thanks!
> > > >
> > > > R,
> > > > leo
> > >
> > > Hello, I'm not so used to working with git, but I think the attached
> > > patch is correct.
> > >
> > > Johan
> >
> > > diff --git a/lib/Mail/SpamAssassin/DnsResolver.pm.orig b/lib/Mail/SpamAssassin/DnsResolver.pm
> > > index 41ae81c..fdc1e5e 100644
> > > --- a/lib/Mail/SpamAssassin/DnsResolver.pm.orig
> > > +++ b/lib/Mail/SpamAssassin/DnsResolver.pm
> > > _at_@ -204,8 +204,10 @@ sub configured_nameservers {
> > > _at_ns_addr_port = @{$self->{conf}->{dns_servers}};
> > > dbg("dns: servers set by config to: %s", join(', ',_at_ns_addr_port));
> > > } elsif ($res) { # default as provided by Net::DNS, e.g. /etc/resolv.conf
> > > - _at_ns_addr_port = map(untaint_var("[$_]:" . $res->{port}),
> > > - _at_{$res->{nameservers}});
> > > + my _at_ns = $res->UNIVERSAL::can('nameservers') ? $res->nameservers
> > > + : _at_{$res->{nameservers}};
> > > + my $port = $res->UNIVERSAL::can('port') ? $res->port : $res->{port};
> > > + _at_ns_addr_port = map(untaint_var("[$_]:" . $port), @ns);
> > > dbg("dns: servers obtained from Net::DNS : %s", join(', ',_at_ns_addr_port));
> > > }
> > > return _at_ns_addr_port;
> >
> >
> >
> >
> > I took some time to figure out git a bit so I guess the following
> > attached patch is more accurate(?).
> >
> > Regards,
> > Johan
>
> Thanks.
> I applied it to edge, can you please check that it works as expected?
> Then I can backport it to 3.1-stable.
>
> For future patches it would be nice to have a GIT patch against aports
> tree. It would be more straightforward to apply them.
> Thanks!
>
> - leo

I will test is as soon as the package shows up on the mirrors.

However I have a problem downloading your aports git, getting the
following several times now:

#> git clone http://git.alpinelinux.org/cgit/aports/

# Cloning into 'aports'...
# error: Unable to get pack file
# http://git.alpinelinux.org/cgit/aports/objects/pack/pack-1f504ab51e1954e77d4841ca04d0a395bec1e1af.pack
# Recv failure: Connection timed out
# error: Unable to find e24b2cb6f0edf60b9bc766902715f25076ad591a under
# http://git.alpinelinux.org/cgit/aports
# Cannot obtain needed tree e24b2cb6f0edf60b9bc766902715f25076ad591a
# while processing commit 934775c391ac937f8c7a4f952cc7498df51abd7e.
# error: fetch failed.

It's temporary perhaps. Are there any mirrors?

If I have any future patches I will create them against the aports tree.

Regards,
Johan

--FCuugMFkClbJLl1L
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAABCAAGBQJUm/XfAAoJEAcoCTcJhy3fa8YQAIqApYX6uaTN8lbUkzlynqX1
dgILH5vpGKOeN4w1uJxJKTfuhIi9TCQQPzjGdNyhqxuaOB1cUwUeTLSQ5IymfJz0
7TneZU7dpWMpcGmkbZLl/REln0B9c86nDImVenADKEe4mPGCAP/R4ZbSq+Wmrmwd
mxQbCjezfE/X3m78YqUQvIZn5J1CcZUxKeVv3RyI8JaHdFB3bDwBUppCWi1DCCra
4BTRGqWoZJRdvQ0Ofp3B7XOOJ0kEu2kopgWoaM9TKybJ9JWC4l3MdbINtLe8EIdV
AmMnbS/K1nlXoOwbuWlnjnnQ7nHrUMUxeYWkWh8HCpaVNN2y6n1vOliZgUcFosdp
OTzXEHsEvnfx1BoDdQDJWT0G/bpdxxDJ0044zuF9lGGgZD+BQGr78tnt+UvvLjy9
VF6ByOFY3c3DLvm6Bi5ob4sBYxVvuGe/12unyhLxvGdIzi6b3FLKCfi11/po1e4/
f8rHBz7iVWPfq5w+DiX8sY+XzIDEGv2ti06jrkQtJDyqkjFYMqF0kzjKlEQCwbIT
yAr8rQo5gZ6OCZi+zHtea0dhZfqD1EYXMZ3vuuOsTuNsM21C0a4RpxxBQ9OhIrNW
/+sfL/NfMiG7ocoyjlkDUuRY8zx8IFJp6uJoAbfYaNmCcLnlkHQZFAUNh3EzDz+C
3LIoB7fUBLCMCSq8JoLt
06
-----END PGP SIGNATURE-----

--FCuugMFkClbJLl1L--


---
Unsubscribe:  alpine-devel+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-devel+help_at_lists.alpinelinux.org
---
Received on Thu Dec 25 2014 - 13:32:48 UTC