line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::LDNS::RR; |
2
|
|
|
|
|
|
|
|
3
|
13
|
|
|
13
|
|
4043
|
use Net::LDNS::RR::A; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
258
|
|
4
|
13
|
|
|
13
|
|
3451
|
use Net::LDNS::RR::A6; |
|
13
|
|
|
|
|
26
|
|
|
13
|
|
|
|
|
256
|
|
5
|
13
|
|
|
13
|
|
3802
|
use Net::LDNS::RR::AAAA; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
322
|
|
6
|
13
|
|
|
13
|
|
3495
|
use Net::LDNS::RR::AFSDB; |
|
13
|
|
|
|
|
18
|
|
|
13
|
|
|
|
|
265
|
|
7
|
13
|
|
|
13
|
|
3482
|
use Net::LDNS::RR::APL; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
275
|
|
8
|
13
|
|
|
13
|
|
3421
|
use Net::LDNS::RR::ATMA; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
277
|
|
9
|
13
|
|
|
13
|
|
3470
|
use Net::LDNS::RR::CAA; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
290
|
|
10
|
13
|
|
|
13
|
|
3445
|
use Net::LDNS::RR::CDS; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
290
|
|
11
|
13
|
|
|
13
|
|
3492
|
use Net::LDNS::RR::CERT; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
297
|
|
12
|
13
|
|
|
13
|
|
3565
|
use Net::LDNS::RR::CNAME; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
315
|
|
13
|
13
|
|
|
13
|
|
3421
|
use Net::LDNS::RR::DHCID; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
313
|
|
14
|
13
|
|
|
13
|
|
3479
|
use Net::LDNS::RR::DLV; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
321
|
|
15
|
13
|
|
|
13
|
|
3505
|
use Net::LDNS::RR::DNAME; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
337
|
|
16
|
13
|
|
|
13
|
|
3492
|
use Net::LDNS::RR::DNSKEY; |
|
13
|
|
|
|
|
30
|
|
|
13
|
|
|
|
|
332
|
|
17
|
13
|
|
|
13
|
|
3468
|
use Net::LDNS::RR::DS; |
|
13
|
|
|
|
|
18
|
|
|
13
|
|
|
|
|
329
|
|
18
|
13
|
|
|
13
|
|
3375
|
use Net::LDNS::RR::EID; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
335
|
|
19
|
13
|
|
|
13
|
|
3498
|
use Net::LDNS::RR::EUI48; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
339
|
|
20
|
13
|
|
|
13
|
|
3360
|
use Net::LDNS::RR::EUI64; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
353
|
|
21
|
13
|
|
|
13
|
|
3340
|
use Net::LDNS::RR::GID; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
380
|
|
22
|
13
|
|
|
13
|
|
3511
|
use Net::LDNS::RR::GPOS; |
|
13
|
|
|
|
|
19
|
|
|
13
|
|
|
|
|
366
|
|
23
|
13
|
|
|
13
|
|
3364
|
use Net::LDNS::RR::HINFO; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
392
|
|
24
|
13
|
|
|
13
|
|
3523
|
use Net::LDNS::RR::HIP; |
|
13
|
|
|
|
|
18
|
|
|
13
|
|
|
|
|
406
|
|
25
|
13
|
|
|
13
|
|
3862
|
use Net::LDNS::RR::IPSECKEY; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
484
|
|
26
|
13
|
|
|
13
|
|
3494
|
use Net::LDNS::RR::ISDN; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
386
|
|
27
|
13
|
|
|
13
|
|
3460
|
use Net::LDNS::RR::KEY; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
396
|
|
28
|
13
|
|
|
13
|
|
3493
|
use Net::LDNS::RR::KX; |
|
13
|
|
|
|
|
19
|
|
|
13
|
|
|
|
|
392
|
|
29
|
13
|
|
|
13
|
|
3418
|
use Net::LDNS::RR::L32; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
437
|
|
30
|
13
|
|
|
13
|
|
3452
|
use Net::LDNS::RR::L64; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
428
|
|
31
|
13
|
|
|
13
|
|
3430
|
use Net::LDNS::RR::LOC; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
409
|
|
32
|
13
|
|
|
13
|
|
3471
|
use Net::LDNS::RR::LP; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
427
|
|
33
|
13
|
|
|
13
|
|
3656
|
use Net::LDNS::RR::MAILA; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
441
|
|
34
|
13
|
|
|
13
|
|
3657
|
use Net::LDNS::RR::MAILB; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
436
|
|
35
|
13
|
|
|
13
|
|
3920
|
use Net::LDNS::RR::MB; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
489
|
|
36
|
13
|
|
|
13
|
|
3594
|
use Net::LDNS::RR::MD; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
455
|
|
37
|
13
|
|
|
13
|
|
3464
|
use Net::LDNS::RR::MF; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
463
|
|
38
|
13
|
|
|
13
|
|
3384
|
use Net::LDNS::RR::MG; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
457
|
|
39
|
13
|
|
|
13
|
|
3526
|
use Net::LDNS::RR::MINFO; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
490
|
|
40
|
13
|
|
|
13
|
|
3454
|
use Net::LDNS::RR::MR; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
464
|
|
41
|
13
|
|
|
13
|
|
3486
|
use Net::LDNS::RR::MX; |
|
13
|
|
|
|
|
27
|
|
|
13
|
|
|
|
|
481
|
|
42
|
13
|
|
|
13
|
|
3474
|
use Net::LDNS::RR::NAPTR; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
504
|
|
43
|
13
|
|
|
13
|
|
3495
|
use Net::LDNS::RR::NID; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
549
|
|
44
|
13
|
|
|
13
|
|
3486
|
use Net::LDNS::RR::NIMLOC; |
|
13
|
|
|
|
|
19
|
|
|
13
|
|
|
|
|
538
|
|
45
|
13
|
|
|
13
|
|
3449
|
use Net::LDNS::RR::NINFO; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
546
|
|
46
|
13
|
|
|
13
|
|
3458
|
use Net::LDNS::RR::NS; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
513
|
|
47
|
13
|
|
|
13
|
|
3548
|
use Net::LDNS::RR::NSAP; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
534
|
|
48
|
13
|
|
|
13
|
|
3405
|
use Net::LDNS::RR::NSEC; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
516
|
|
49
|
13
|
|
|
13
|
|
3568
|
use Net::LDNS::RR::NSEC3; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
567
|
|
50
|
13
|
|
|
13
|
|
3523
|
use Net::LDNS::RR::NSEC3PARAM; |
|
13
|
|
|
|
|
636
|
|
|
13
|
|
|
|
|
577
|
|
51
|
13
|
|
|
13
|
|
3573
|
use Net::LDNS::RR::NULL; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
601
|
|
52
|
13
|
|
|
13
|
|
3523
|
use Net::LDNS::RR::NXT; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
551
|
|
53
|
13
|
|
|
13
|
|
4042
|
use Net::LDNS::RR::PTR; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
1787
|
|
54
|
13
|
|
|
13
|
|
3442
|
use Net::LDNS::RR::PX; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
597
|
|
55
|
13
|
|
|
13
|
|
4305
|
use Net::LDNS::RR::RKEY; |
|
13
|
|
|
|
|
20
|
|
|
13
|
|
|
|
|
597
|
|
56
|
13
|
|
|
13
|
|
3488
|
use Net::LDNS::RR::RP; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
592
|
|
57
|
13
|
|
|
13
|
|
3649
|
use Net::LDNS::RR::RRSIG; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
769
|
|
58
|
13
|
|
|
13
|
|
3550
|
use Net::LDNS::RR::RT; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
589
|
|
59
|
13
|
|
|
13
|
|
3631
|
use Net::LDNS::RR::SINK; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
669
|
|
60
|
13
|
|
|
13
|
|
3513
|
use Net::LDNS::RR::SOA; |
|
13
|
|
|
|
|
25
|
|
|
13
|
|
|
|
|
598
|
|
61
|
13
|
|
|
13
|
|
4085
|
use Net::LDNS::RR::SPF; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
637
|
|
62
|
13
|
|
|
13
|
|
3448
|
use Net::LDNS::RR::SRV; |
|
13
|
|
|
|
|
24
|
|
|
13
|
|
|
|
|
608
|
|
63
|
13
|
|
|
13
|
|
3453
|
use Net::LDNS::RR::SSHFP; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
637
|
|
64
|
13
|
|
|
13
|
|
3551
|
use Net::LDNS::RR::TA; |
|
13
|
|
|
|
|
18
|
|
|
13
|
|
|
|
|
607
|
|
65
|
13
|
|
|
13
|
|
3581
|
use Net::LDNS::RR::TALINK; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
747
|
|
66
|
13
|
|
|
13
|
|
3686
|
use Net::LDNS::RR::TKEY; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
637
|
|
67
|
13
|
|
|
13
|
|
3434
|
use Net::LDNS::RR::TLSA; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
631
|
|
68
|
13
|
|
|
13
|
|
3458
|
use Net::LDNS::RR::TXT; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
642
|
|
69
|
13
|
|
|
13
|
|
3520
|
use Net::LDNS::RR::TYPE; |
|
13
|
|
|
|
|
19
|
|
|
13
|
|
|
|
|
1030
|
|
70
|
13
|
|
|
13
|
|
3449
|
use Net::LDNS::RR::UID; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
707
|
|
71
|
13
|
|
|
13
|
|
3434
|
use Net::LDNS::RR::UINFO; |
|
13
|
|
|
|
|
23
|
|
|
13
|
|
|
|
|
692
|
|
72
|
13
|
|
|
13
|
|
3619
|
use Net::LDNS::RR::UNSPEC; |
|
13
|
|
|
|
|
22
|
|
|
13
|
|
|
|
|
675
|
|
73
|
13
|
|
|
13
|
|
3434
|
use Net::LDNS::RR::URI; |
|
13
|
|
|
|
|
21
|
|
|
13
|
|
|
|
|
856
|
|
74
|
13
|
|
|
13
|
|
3308
|
use Net::LDNS::RR::WKS; |
|
13
|
|
|
|
|
18
|
|
|
13
|
|
|
|
|
673
|
|
75
|
13
|
|
|
13
|
|
3387
|
use Net::LDNS::RR::X25; |
|
13
|
|
|
|
|
95
|
|
|
13
|
|
|
|
|
733
|
|
76
|
|
|
|
|
|
|
|
77
|
13
|
|
|
13
|
|
52
|
use Carp; |
|
13
|
|
|
|
|
13
|
|
|
13
|
|
|
|
|
2525
|
|
78
|
|
|
|
|
|
|
|
79
|
13
|
|
|
13
|
|
8850
|
use overload '<=>' => \&do_compare, 'cmp' => \&do_compare, '""' => \&to_string; |
|
13
|
|
|
|
|
6984
|
|
|
13
|
|
|
|
|
927
|
|
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
sub new { |
82
|
10
|
|
|
10
|
1
|
248376
|
my ( $class, $string ) = @_; |
83
|
|
|
|
|
|
|
|
84
|
10
|
50
|
|
|
|
28
|
if ( $string ) { |
85
|
10
|
|
|
|
|
803
|
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
|
1416
|
my ( $self ) = @_; |
94
|
|
|
|
|
|
|
|
95
|
1
|
|
|
|
|
33
|
return $self->owner; |
96
|
|
|
|
|
|
|
} |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
sub do_compare { |
99
|
3
|
|
|
3
|
1
|
411750
|
my ( $self, $other, $swapped ) = @_; |
100
|
|
|
|
|
|
|
|
101
|
3
|
|
|
|
|
29
|
return $self->compare( $other ); |
102
|
|
|
|
|
|
|
} |
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
sub to_string { |
105
|
13
|
|
|
13
|
1
|
20621
|
my ( $self ) = @_; |
106
|
|
|
|
|
|
|
|
107
|
13
|
|
|
|
|
412
|
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 |