"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "lib/Net/DNS/RR/DS.pm" between
Net-DNS-1.23.tar.gz and Net-DNS-1.23_01.tar.gz

About: Net::DNS is a DNS resolver implemented in Perl. Development version.

DS.pm  (Net-DNS-1.23):DS.pm  (Net-DNS-1.23_01)
package Net::DNS::RR::DS; package Net::DNS::RR::DS;
# #
# $Id: DS.pm 1774 2020-03-18 07:49:22Z willem $ # $Id: DS.pm 1779 2020-05-11 09:11:17Z willem $
# #
our $VERSION = (qw$LastChangedRevision: 1774 $)[1]; our $VERSION = (qw$LastChangedRevision: 1779 $)[1];
use strict; use strict;
use warnings; use warnings;
use base qw(Net::DNS::RR); use base qw(Net::DNS::RR);
=head1 NAME =head1 NAME
Net::DNS::RR::DS - DNS DS resource record Net::DNS::RR::DS - DNS DS resource record
=cut =cut
skipping to change at line 205 skipping to change at line 205
$self->{digestbin} || ""; $self->{digestbin} || "";
} }
sub babble { sub babble {
return BABBLE ? Digest::BubbleBabble::bubblebabble( Digest => shift->dige stbin ) : ''; return BABBLE ? Digest::BubbleBabble::bubblebabble( Digest => shift->dige stbin ) : '';
} }
sub create { sub create {
my $class = shift; my $class = shift;
my $keyrr = shift; my $keyrr = shift;
my %args = $keyrr->ttl ? ( ttl => $keyrr->ttl, @_ ) : (@_); my %args = @_;
my ($type) = reverse split '::', $class; my ($type) = reverse split '::', $class;
my $flags = $keyrr->flags; croak "Unable to create $type record for non-zone key" unless $keyrr->zon
croak "Unable to create $type record for non-DNSSEC key" unless $keyrr->p e;
rotocol == 3; croak "Unable to create $type record for revoked key" if $keyrr->revoke;
croak "Unable to create $type record for non-authentication key" if $flag croak "Unable to create $type record for invalid key" unless $keyrr->prot
s & 0x8000; ocol == 3;
croak "Unable to create $type record for non-ZONE key" unless ( $flags &
0x300 ) == 0x100;
my $self = new Net::DNS::RR( my $self = new Net::DNS::RR(
owner => $keyrr->owner, # per definition, same as keyrr owner => $keyrr->owner, # per definition, same as keyrr
type => $type, type => $type,
class => $keyrr->class, class => $keyrr->class,
ttl => $keyrr->{ttl},
keytag => $keyrr->keytag, keytag => $keyrr->keytag,
algorithm => $keyrr->algorithm, algorithm => $keyrr->algorithm,
digtype => 1, # SHA1 by default digtype => 1, # SHA1 by default
%args %args
); );
my $arglist = $digest{$self->digtype}; my $arglist = $digest{$self->digtype};
croak join ' ', 'digtype', $self->digtype('MNEMONIC'), 'not supported' un less $arglist; croak join ' ', 'digtype', $self->digtype('MNEMONIC'), 'not supported' un less $arglist;
my ( $object, @argument ) = @$arglist; my ( $object, @argument ) = @$arglist;
my $hash = $object->new(@argument); my $hash = $object->new(@argument);
 End of changes. 5 change blocks. 
10 lines changed or deleted 9 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)