Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Net-SSH2 CPAN distribution.

Report information
The Basics
Id:
37090
Status:
rejected
Priority:
Low/Low
Queue:

People
Owner:
Nobody in particular
Requestors:
Claus.Brunzema [...] offis.de
Ray.Bellis [...] nominet.org.uk
Cc:
AdminCc:

BugTracker
Severity:
(no value)
Broken in:
(no value)
Fixed in:
(no value)



Subject: CD=1 support incomplete in Net::DNS
Date: Wed, 25 Jun 2008 16:25:47 +0100
To: bug-Net-DNS@rt.cpan.org
From: Ray.Bellis@nominet.org.uk
Olaf, I believe I've found a bug in Net::DNS (up to and including version 0.63). The "cdflag" variable from the Resolver object is never copied into the Header when making a DNSSEC (DO=1) request. I've had to add a line: $packet->header->cd($self->{'cdflag'}); in the DNSSEC portion of the make_query_packet function in Resolver/Base.pm cheers, Ray -- Ray Bellis, MA(Oxon) Senior Researcher in Advanced Projects, Nominet e: ray@nominet.org.uk, t: +44 1865 332211
Subject: personal install of libssh2 not detected
Date: Wed, 25 Jun 2008 17:35:37 +0200
To: bug-Net-SSH2@rt.cpan.org
From: Claus Brunzema <Claus.Brunzema@offis.de>
The Makefile.PL of Net::SSH2 version 0.18 doesn't detect a personal install of libssh2 that is correctly registered in the environment variables C_INCLUDE_PATH/LIBRARY_PATH. The appended patch fixes this. Versions: Net::SSH2 0.18 perl 5.8.8 Linux pallas 2.6.18.2008-01-07-0 #1 SMP Mon Jan 7 16:18:23 CET 2008 i686 GNU/Linux Patch: diff -cr Net-SSH2-0.18/Makefile.PL Net-SSH2-0.18.patched/Makefile.PL *** Net-SSH2-0.18/Makefile.PL Sun Nov 11 01:29:00 2007 --- Net-SSH2-0.18.patched/Makefile.PL Wed Jun 25 17:21:22 2008 *************** *** 16,30 **** # try to find libSSH2 if we're not given a location unless($lib and $inc) { for my $prefix($Config{siteprefixexp},$Config{prefixexp}, ! '/usr','/usr/local','/opt') { $lib ||= "$prefix/lib" if -f "$prefix/lib/libssh2$Config{_a}" or -f "$prefix/lib/libssh2.$Config{so}"; $lib ||= "$prefix/lib64" if -f "$prefix/lib64/libssh2$Config{_a}" or -f "$prefix/lib64/libssh2.$Config{so}"; $inc ||= "$prefix/include" if -f "$prefix/include/libssh2.h"; last if $lib and $inc; } } --- 16,37 ---- # try to find libSSH2 if we're not given a location unless($lib and $inc) { for my $prefix($Config{siteprefixexp},$Config{prefixexp}, ! split(':', $ENV{C_INCLUDE_PATH}), ! split(':', $ENV{LIBRARY_PATH}), ! '/usr','/usr/local','/opt') { $lib ||= "$prefix/lib" if -f "$prefix/lib/libssh2$Config{_a}" or -f "$prefix/lib/libssh2.$Config{so}"; $lib ||= "$prefix/lib64" if -f "$prefix/lib64/libssh2$Config{_a}" or -f "$prefix/lib64/libssh2.$Config{so}"; + $lib ||= "$prefix" + if -f "$prefix/libssh2$Config{_a}" or + -f "$prefix/libssh2.$Config{so}"; $inc ||= "$prefix/include" if -f "$prefix/include/libssh2.h"; + $inc ||= "$prefix" + if -f "$prefix/libssh2.h"; last if $lib and $inc; } } -- Dipl.-Inf. (FH) Claus Brunzema Wissenschaftlicher Mitarbeiter | Researcher OFFIS FuE Bereich Verkehr | R&D Division Transportation Escherweg 2 - 26121 Oldenburg - Germany Phone/Fax.: +49 441 9722-287/282 E-Mail: Claus.Brunzema@offis.de URL: http://www.offis.de/
Subject: Re: [rt.cpan.org #37089] CD=1 support incomplete in Net::DNS
Date: Wed, 25 Jun 2008 21:13:40 +0200
To: bug-Net-DNS@rt.cpan.org
From: Olaf Kolkman <olaf@dacht.net>
This is to acknowledge receipt, and I think that both your assessment and patch are correct. I plan to have a stab at a new Net::DNS and Net::DNS:SEC release after my vacation and a few forthcoming events so not earlier than August. --Olaf On Jun 25, 2008, at 5:27 PM, Ray.Bellis@nominet.org.uk via RT wrote:
Show quoted text
> Wed Jun 25 11:27:22 2008: Request 37089 was acted upon. > Transaction: Ticket created by Ray.Bellis@nominet.org.uk > Queue: Net-DNS > Subject: CD=1 support incomplete in Net::DNS > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: Ray.Bellis@nominet.org.uk > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=37089 > > > > Olaf, > > I believe I've found a bug in Net::DNS (up to and including version > 0.63). > > The "cdflag" variable from the Resolver object is never copied into > the > Header when making a DNSSEC (DO=1) request. > > I've had to add a line: > > $packet->header->cd($self->{'cdflag'}); > > in the DNSSEC portion of the make_query_packet function in > Resolver/Base.pm > > cheers, > > Ray > > -- > Ray Bellis, MA(Oxon) > Senior Researcher in Advanced Projects, Nominet > e: ray@nominet.org.uk, t: +44 1865 332211

Message body not shown because it is not plain text.

Subject: CD=1 support incomplete in Net::DNS
This diff should do the trick... Index: lib/Net/DNS/Resolver/Base.pm ========================================================= ========== --- lib/Net/DNS/Resolver/Base.pm (revision 736) +++ lib/Net/DNS/Resolver/Base.pm (working copy) @@ -107,7 +107,8 @@ persistent_udp => 0, dnssec => 0, udppacketsize => 0, # The actual default is lower bound by Net::DNS::PACKETSZ - cdflag => 1, # this is only used when {dnssec} == 1 + cdflag => 0, # this is only used when {dnssec} == 1 + adflag => 1, # this is only used when {dnssec} == 1 force_v4 => 0, # force_v4 is only relevant when we have # v6 support available ignqrid => 0, # normally packets with non-matching ID @@ -1069,7 +1070,10 @@ print ";; Adding EDNS extention with UDP packetsize $self->{'udppacketsize'} and DNS OK bit set\n" if $self->{'debug'}; - my $optrr = Net::DNS::RR->new( + + $packet->header->cd($self->{'cdflag'}); + $packet->header->cd($self->{'adflag'}); + my $optrr = Net::DNS::RR->new( Type => 'OPT', Name => '', Class => $self->{'udppacketsize'}, # Decimal UDPpayload Index: lib/Net/DNS/Resolver.pm ========================================================= ========== --- lib/Net/DNS/Resolver.pm (revision 724) +++ lib/Net/DNS/Resolver.pm (working copy) @@ -612,9 +612,22 @@ $res->cdflag(1); Sets or gets the CD bit for a dnssec query. This bit is always zero -for non dnssec queries. When the dnssec is enabled the flag can be set +for non dnssec queries. When the dnssec is enabled the flag defaults to +0 can be set to 1. + + + +=head2 adflag + + print "checking disabled flag: ", $res->dnssec, "\n"; + $res->dnssec(1); + $res->adflag(1); + +Sets or gets the AD bit for a dnssec query. This bit is always zero +for non dnssec queries. When the dnssec is enabled the flag defaults to 1. + =head2 udppacketsize print "udppacketsize: ", $res->udppacketsize, "\n"; Index: Changes ========================================================= ========== --- Changes (revision 735) +++ Changes (working copy) @@ -5,8 +5,14 @@ ============================= *** NOT RELEASED YET +Fix rt.cpan.org #38390 and 37089 + Added CD and AD bit control to the resolver. + The CD flag defaults to 0 and the AD bit is set by default + whenever DNSSEC is available. + +
Apologies... I merged into the wrong ticket number. You should ignore all this.
Subject: Re: [rt.cpan.org #37090] CD=1 support incomplete in Net::DNS
Date: Wed, 17 Dec 2008 12:12:29 +0000
To: bug-Net-SSH2@rt.cpan.org
From: Ray.Bellis@nominet.org.uk
Show quoted text
> + $packet->header->cd($self->{'cdflag'}); > + $packet->header->cd($self->{'adflag'});
The second of these two lines in the diff appears to be wrong. Also, I'd suggest that it's not necessarily appropriate to _default_ AD=1 in DNSSEC queries. It's supposed to be supported by resolvers as an _alternative_ to DO=1. In practise that means that it should be up to the API client to decide to use $resolver->ad(1) _instead_ of $resolver->dnssec(1). cheers, Ray
This bug doesn't seem about Net::SSH2. Rejecting it.


This service runs on Request Tracker, is sponsored by The Perl Foundation, and maintained by Best Practical Solutions.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.