line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::DNS::RR::MINFO; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
15
|
use strict; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
63
|
|
4
|
2
|
|
|
2
|
|
9
|
use warnings; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
120
|
|
5
|
|
|
|
|
|
|
our $VERSION = (qw$Id: MINFO.pm 1896 2023-01-30 12:59:25Z willem $)[2]; |
6
|
|
|
|
|
|
|
|
7
|
2
|
|
|
2
|
|
12
|
use base qw(Net::DNS::RR); |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
198
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
=head1 NAME |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
Net::DNS::RR::MINFO - DNS MINFO resource record |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
=cut |
15
|
|
|
|
|
|
|
|
16
|
2
|
|
|
2
|
|
15
|
use integer; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
12
|
|
17
|
|
|
|
|
|
|
|
18
|
2
|
|
|
2
|
|
513
|
use Net::DNS::Mailbox; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
899
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub _decode_rdata { ## decode rdata from wire-format octet string |
22
|
1
|
|
|
1
|
|
2
|
my ( $self, @argument ) = @_; |
23
|
1
|
|
|
|
|
3
|
my ( $data, $offset, @opaque ) = @argument; |
24
|
|
|
|
|
|
|
|
25
|
1
|
|
|
|
|
7
|
( $self->{rmailbx}, $offset ) = Net::DNS::Mailbox1035->decode(@argument); |
26
|
1
|
|
|
|
|
4
|
( $self->{emailbx}, $offset ) = Net::DNS::Mailbox1035->decode( $data, $offset, @opaque ); |
27
|
1
|
|
|
|
|
4
|
return; |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub _encode_rdata { ## encode rdata as wire-format octet string |
32
|
5
|
|
|
5
|
|
10
|
my ( $self, @argument ) = @_; |
33
|
5
|
|
|
|
|
8
|
my ( $offset, @opaque ) = @argument; |
34
|
|
|
|
|
|
|
|
35
|
5
|
|
|
|
|
16
|
my $rdata = $self->{rmailbx}->encode(@argument); |
36
|
5
|
|
|
|
|
15
|
$rdata .= $self->{emailbx}->encode( $offset + length $rdata, @opaque ); |
37
|
5
|
|
|
|
|
16
|
return $rdata; |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
sub _format_rdata { ## format rdata portion of RR string. |
42
|
4
|
|
|
4
|
|
11
|
my $self = shift; |
43
|
|
|
|
|
|
|
|
44
|
4
|
|
|
|
|
33
|
my @rdata = ( $self->{rmailbx}->string, $self->{emailbx}->string ); |
45
|
2
|
|
|
|
|
7
|
return @rdata; |
46
|
|
|
|
|
|
|
} |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
sub _parse_rdata { ## populate RR from rdata in argument list |
50
|
1
|
|
|
1
|
|
3
|
my ( $self, @argument ) = @_; |
51
|
|
|
|
|
|
|
|
52
|
1
|
|
|
|
|
10
|
for (qw(rmailbx emailbx)) { $self->$_( shift @argument ) } |
|
2
|
|
|
|
|
8
|
|
53
|
1
|
|
|
|
|
5
|
return; |
54
|
|
|
|
|
|
|
} |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
sub rmailbx { |
58
|
4
|
|
|
4
|
1
|
15
|
my ( $self, @value ) = @_; |
59
|
4
|
|
|
|
|
7
|
for (@value) { $self->{rmailbx} = Net::DNS::Mailbox1035->new($_) } |
|
2
|
|
|
|
|
9
|
|
60
|
4
|
100
|
|
|
|
24
|
return $self->{rmailbx} ? $self->{rmailbx}->address : undef; |
61
|
|
|
|
|
|
|
} |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
sub emailbx { |
65
|
6
|
|
|
6
|
1
|
1082
|
my ( $self, @value ) = @_; |
66
|
6
|
|
|
|
|
13
|
for (@value) { $self->{emailbx} = Net::DNS::Mailbox1035->new($_) } |
|
4
|
|
|
|
|
16
|
|
67
|
6
|
100
|
|
|
|
27
|
return $self->{emailbx} ? $self->{emailbx}->address : undef; |
68
|
|
|
|
|
|
|
} |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
1; |
72
|
|
|
|
|
|
|
__END__ |