line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::LDNS::RR; |
2
|
|
|
|
|
|
|
|
3
|
13
|
|
|
13
|
|
4230
|
use Net::LDNS::RR::A; |
|
13
|
|
|
|
|
29
|
|
|
13
|
|
|
|
|
298
|
|
4
|
13
|
|
|
13
|
|
3899
|
use Net::LDNS::RR::A6; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
293
|
|
5
|
13
|
|
|
13
|
|
4437
|
use Net::LDNS::RR::AAAA; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
348
|
|
6
|
13
|
|
|
13
|
|
3951
|
use Net::LDNS::RR::AFSDB; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
290
|
|
7
|
13
|
|
|
13
|
|
3785
|
use Net::LDNS::RR::APL; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
292
|
|
8
|
13
|
|
|
13
|
|
3863
|
use Net::LDNS::RR::ATMA; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
309
|
|
9
|
13
|
|
|
13
|
|
3827
|
use Net::LDNS::RR::CAA; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
321
|
|
10
|
13
|
|
|
13
|
|
3973
|
use Net::LDNS::RR::CDS; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
321
|
|
11
|
13
|
|
|
13
|
|
3868
|
use Net::LDNS::RR::CERT; |
|
13
|
|
|
|
|
27
|
|
|
13
|
|
|
|
|
343
|
|
12
|
13
|
|
|
13
|
|
4014
|
use Net::LDNS::RR::CNAME; |
|
13
|
|
|
|
|
32
|
|
|
13
|
|
|
|
|
344
|
|
13
|
13
|
|
|
13
|
|
4030
|
use Net::LDNS::RR::DHCID; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
346
|
|
14
|
13
|
|
|
13
|
|
3925
|
use Net::LDNS::RR::DLV; |
|
13
|
|
|
|
|
34
|
|
|
13
|
|
|
|
|
380
|
|
15
|
13
|
|
|
13
|
|
3883
|
use Net::LDNS::RR::DNAME; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
356
|
|
16
|
13
|
|
|
13
|
|
3819
|
use Net::LDNS::RR::DNSKEY; |
|
13
|
|
|
|
|
37
|
|
|
13
|
|
|
|
|
361
|
|
17
|
13
|
|
|
13
|
|
3985
|
use Net::LDNS::RR::DS; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
378
|
|
18
|
13
|
|
|
13
|
|
3952
|
use Net::LDNS::RR::EID; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
387
|
|
19
|
13
|
|
|
13
|
|
3937
|
use Net::LDNS::RR::EUI48; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
376
|
|
20
|
13
|
|
|
13
|
|
4015
|
use Net::LDNS::RR::EUI64; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
388
|
|
21
|
13
|
|
|
13
|
|
3820
|
use Net::LDNS::RR::GID; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
394
|
|
22
|
13
|
|
|
13
|
|
3871
|
use Net::LDNS::RR::GPOS; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
394
|
|
23
|
13
|
|
|
13
|
|
3980
|
use Net::LDNS::RR::HINFO; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
413
|
|
24
|
13
|
|
|
13
|
|
4080
|
use Net::LDNS::RR::HIP; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
447
|
|
25
|
13
|
|
|
13
|
|
3964
|
use Net::LDNS::RR::IPSECKEY; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
432
|
|
26
|
13
|
|
|
13
|
|
4158
|
use Net::LDNS::RR::ISDN; |
|
13
|
|
|
|
|
29
|
|
|
13
|
|
|
|
|
441
|
|
27
|
13
|
|
|
13
|
|
4204
|
use Net::LDNS::RR::KEY; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
501
|
|
28
|
13
|
|
|
13
|
|
4238
|
use Net::LDNS::RR::KX; |
|
13
|
|
|
|
|
27
|
|
|
13
|
|
|
|
|
443
|
|
29
|
13
|
|
|
13
|
|
4211
|
use Net::LDNS::RR::L32; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
467
|
|
30
|
13
|
|
|
13
|
|
3853
|
use Net::LDNS::RR::L64; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
470
|
|
31
|
13
|
|
|
13
|
|
3810
|
use Net::LDNS::RR::LOC; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
448
|
|
32
|
13
|
|
|
13
|
|
3863
|
use Net::LDNS::RR::LP; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
455
|
|
33
|
13
|
|
|
13
|
|
3985
|
use Net::LDNS::RR::MAILA; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
509
|
|
34
|
13
|
|
|
13
|
|
3784
|
use Net::LDNS::RR::MAILB; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
1073
|
|
35
|
13
|
|
|
13
|
|
4034
|
use Net::LDNS::RR::MB; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
504
|
|
36
|
13
|
|
|
13
|
|
3919
|
use Net::LDNS::RR::MD; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
620
|
|
37
|
13
|
|
|
13
|
|
3919
|
use Net::LDNS::RR::MF; |
|
13
|
|
|
|
|
27
|
|
|
13
|
|
|
|
|
502
|
|
38
|
13
|
|
|
13
|
|
3908
|
use Net::LDNS::RR::MG; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
532
|
|
39
|
13
|
|
|
13
|
|
3842
|
use Net::LDNS::RR::MINFO; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
539
|
|
40
|
13
|
|
|
13
|
|
3872
|
use Net::LDNS::RR::MR; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
529
|
|
41
|
13
|
|
|
13
|
|
3956
|
use Net::LDNS::RR::MX; |
|
13
|
|
|
|
|
34
|
|
|
13
|
|
|
|
|
564
|
|
42
|
13
|
|
|
13
|
|
4043
|
use Net::LDNS::RR::NAPTR; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
600
|
|
43
|
13
|
|
|
13
|
|
3902
|
use Net::LDNS::RR::NID; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
562
|
|
44
|
13
|
|
|
13
|
|
3933
|
use Net::LDNS::RR::NIMLOC; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
619
|
|
45
|
13
|
|
|
13
|
|
3990
|
use Net::LDNS::RR::NINFO; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
593
|
|
46
|
13
|
|
|
13
|
|
3887
|
use Net::LDNS::RR::NS; |
|
13
|
|
|
|
|
27
|
|
|
13
|
|
|
|
|
631
|
|
47
|
13
|
|
|
13
|
|
4041
|
use Net::LDNS::RR::NSAP; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
607
|
|
48
|
13
|
|
|
13
|
|
3910
|
use Net::LDNS::RR::NSEC; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
576
|
|
49
|
13
|
|
|
13
|
|
4018
|
use Net::LDNS::RR::NSEC3; |
|
13
|
|
|
|
|
29
|
|
|
13
|
|
|
|
|
622
|
|
50
|
13
|
|
|
13
|
|
4061
|
use Net::LDNS::RR::NSEC3PARAM; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
669
|
|
51
|
13
|
|
|
13
|
|
4022
|
use Net::LDNS::RR::NULL; |
|
13
|
|
|
|
|
28
|
|
|
13
|
|
|
|
|
606
|
|
52
|
13
|
|
|
13
|
|
3954
|
use Net::LDNS::RR::NXT; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
640
|
|
53
|
13
|
|
|
13
|
|
5298
|
use Net::LDNS::RR::PTR; |
|
13
|
|
|
|
|
594
|
|
|
13
|
|
|
|
|
1515
|
|
54
|
13
|
|
|
13
|
|
3797
|
use Net::LDNS::RR::PX; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
651
|
|
55
|
13
|
|
|
13
|
|
4778
|
use Net::LDNS::RR::RKEY; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
649
|
|
56
|
13
|
|
|
13
|
|
4942
|
use Net::LDNS::RR::RP; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
654
|
|
57
|
13
|
|
|
13
|
|
4180
|
use Net::LDNS::RR::RRSIG; |
|
13
|
|
|
|
|
28
|
|
|
13
|
|
|
|
|
859
|
|
58
|
13
|
|
|
13
|
|
3781
|
use Net::LDNS::RR::RT; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
635
|
|
59
|
13
|
|
|
13
|
|
3777
|
use Net::LDNS::RR::SINK; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
692
|
|
60
|
13
|
|
|
13
|
|
3897
|
use Net::LDNS::RR::SOA; |
|
13
|
|
|
|
|
28
|
|
|
13
|
|
|
|
|
664
|
|
61
|
13
|
|
|
13
|
|
4535
|
use Net::LDNS::RR::SPF; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
704
|
|
62
|
13
|
|
|
13
|
|
3725
|
use Net::LDNS::RR::SRV; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
631
|
|
63
|
13
|
|
|
13
|
|
3808
|
use Net::LDNS::RR::SSHFP; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
652
|
|
64
|
13
|
|
|
13
|
|
3897
|
use Net::LDNS::RR::TA; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
666
|
|
65
|
13
|
|
|
13
|
|
3810
|
use Net::LDNS::RR::TALINK; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
738
|
|
66
|
13
|
|
|
13
|
|
3730
|
use Net::LDNS::RR::TKEY; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
684
|
|
67
|
13
|
|
|
13
|
|
3794
|
use Net::LDNS::RR::TLSA; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
662
|
|
68
|
13
|
|
|
13
|
|
3654
|
use Net::LDNS::RR::TXT; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
670
|
|
69
|
13
|
|
|
13
|
|
3641
|
use Net::LDNS::RR::TYPE; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
1185
|
|
70
|
13
|
|
|
13
|
|
4062
|
use Net::LDNS::RR::UID; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
679
|
|
71
|
13
|
|
|
13
|
|
3584
|
use Net::LDNS::RR::UINFO; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
714
|
|
72
|
13
|
|
|
13
|
|
3642
|
use Net::LDNS::RR::UNSPEC; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
734
|
|
73
|
13
|
|
|
13
|
|
3711
|
use Net::LDNS::RR::URI; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
967
|
|
74
|
13
|
|
|
13
|
|
3632
|
use Net::LDNS::RR::WKS; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
728
|
|
75
|
13
|
|
|
13
|
|
3581
|
use Net::LDNS::RR::X25; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
727
|
|
76
|
|
|
|
|
|
|
|
77
|
13
|
|
|
13
|
|
80
|
use Carp; |
|
13
|
|
|
|
|
15
|
|
|
13
|
|
|
|
|
3145
|
|
78
|
|
|
|
|
|
|
|
79
|
13
|
|
|
13
|
|
10002
|
use overload '<=>' => \&do_compare, 'cmp' => \&do_compare, '""' => \&to_string; |
|
13
|
|
|
|
|
7421
|
|
|
13
|
|
|
|
|
1125
|
|
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
sub new { |
82
|
10
|
|
|
10
|
1
|
190663
|
my ( $class, $string ) = @_; |
83
|
|
|
|
|
|
|
|
84
|
10
|
50
|
|
|
|
24
|
if ( $string ) { |
85
|
10
|
|
|
|
|
757
|
return $class->new_from_string( $string ); |
86
|
|
|
|
|
|
|
} |
87
|
|
|
|
|
|
|
else { |
88
|
0
|
|
|
|
|
0
|
croak "Must provide string to create RR"; |
89
|
|
|
|
|
|
|
} |
90
|
|
|
|
|
|
|
} |
91
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
sub name { |
93
|
1
|
|
|
1
|
1
|
1907
|
my ( $self ) = @_; |
94
|
|
|
|
|
|
|
|
95
|
1
|
|
|
|
|
29
|
return $self->owner; |
96
|
|
|
|
|
|
|
} |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
sub do_compare { |
99
|
3
|
|
|
3
|
1
|
298893
|
my ( $self, $other, $swapped ) = @_; |
100
|
|
|
|
|
|
|
|
101
|
3
|
|
|
|
|
25
|
return $self->compare( $other ); |
102
|
|
|
|
|
|
|
} |
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
sub to_string { |
105
|
13
|
|
|
13
|
1
|
22753
|
my ( $self ) = @_; |
106
|
|
|
|
|
|
|
|
107
|
13
|
|
|
|
|
423
|
return $self->string; |
108
|
|
|
|
|
|
|
} |
109
|
|
|
|
|
|
|
|
110
|
|
|
|
|
|
|
1; |
111
|
|
|
|
|
|
|
|
112
|
|
|
|
|
|
|
=head1 NAME |
113
|
|
|
|
|
|
|
|
114
|
|
|
|
|
|
|
Net::LDNS::RR - common baseclass for all classes representing resource records. |
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
=head1 SYNOPSIS |
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
my $rr = Net::LDNS::RR->new('www.iis.se IN A 91.226.36.46'); |
119
|
|
|
|
|
|
|
|
120
|
|
|
|
|
|
|
=head1 OVERLOADS |
121
|
|
|
|
|
|
|
|
122
|
|
|
|
|
|
|
This class overloads stringify and comparisons ('""', '<=>' and 'cmp'). |
123
|
|
|
|
|
|
|
|
124
|
|
|
|
|
|
|
=head1 CLASS METHOD |
125
|
|
|
|
|
|
|
|
126
|
|
|
|
|
|
|
=over |
127
|
|
|
|
|
|
|
|
128
|
|
|
|
|
|
|
=item new($string) |
129
|
|
|
|
|
|
|
|
130
|
|
|
|
|
|
|
Creates a new RR object of a suitable subclass, given a string representing an RR in common presentation format. |
131
|
|
|
|
|
|
|
|
132
|
|
|
|
|
|
|
=back |
133
|
|
|
|
|
|
|
|
134
|
|
|
|
|
|
|
=head1 INSTANCE METHODS |
135
|
|
|
|
|
|
|
|
136
|
|
|
|
|
|
|
=over |
137
|
|
|
|
|
|
|
|
138
|
|
|
|
|
|
|
=item owner() |
139
|
|
|
|
|
|
|
|
140
|
|
|
|
|
|
|
=item name() |
141
|
|
|
|
|
|
|
|
142
|
|
|
|
|
|
|
These two both return the owner name of the RR. |
143
|
|
|
|
|
|
|
|
144
|
|
|
|
|
|
|
=item ttl() |
145
|
|
|
|
|
|
|
|
146
|
|
|
|
|
|
|
Returns the ttl of the RR. |
147
|
|
|
|
|
|
|
|
148
|
|
|
|
|
|
|
=item type() |
149
|
|
|
|
|
|
|
|
150
|
|
|
|
|
|
|
Return the type of the RR. |
151
|
|
|
|
|
|
|
|
152
|
|
|
|
|
|
|
=item class() |
153
|
|
|
|
|
|
|
|
154
|
|
|
|
|
|
|
Returns the class of the RR. |
155
|
|
|
|
|
|
|
|
156
|
|
|
|
|
|
|
=item string() |
157
|
|
|
|
|
|
|
|
158
|
|
|
|
|
|
|
Returns a string with the RR in presentation format. |
159
|
|
|
|
|
|
|
|
160
|
|
|
|
|
|
|
=item do_compare($other) |
161
|
|
|
|
|
|
|
|
162
|
|
|
|
|
|
|
Calls the XS C method with the arguments it needs, rather than the ones overloading gives. |
163
|
|
|
|
|
|
|
|
164
|
|
|
|
|
|
|
=item to_string |
165
|
|
|
|
|
|
|
|
166
|
|
|
|
|
|
|
Calls the XS C method with the arguments it needs, rather than the ones overloading gives. Functionally identical to L from the |
167
|
|
|
|
|
|
|
Perl level, except for being a tiny little bit slower. |
168
|
|
|
|
|
|
|
|
169
|
|
|
|
|
|
|
=item rd_count() |
170
|
|
|
|
|
|
|
|
171
|
|
|
|
|
|
|
The number of RDATA objects in this RR. |
172
|
|
|
|
|
|
|
|
173
|
|
|
|
|
|
|
=item rdf($postion) |
174
|
|
|
|
|
|
|
|
175
|
|
|
|
|
|
|
The raw data of the RDATA object in the given position. The first item is in |
176
|
|
|
|
|
|
|
position 0. If an attempt is made to fetch RDATA from a position that doesn't |
177
|
|
|
|
|
|
|
have any, an exception will be thrown. |
178
|
|
|
|
|
|
|
|
179
|
|
|
|
|
|
|
=back |