line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
## Domain Registry Interface, .IT Domain extension |
2
|
|
|
|
|
|
|
## |
3
|
|
|
|
|
|
|
## Copyright (C) 2009-2010 Tower Technologies. All rights reserved. |
4
|
|
|
|
|
|
|
## |
5
|
|
|
|
|
|
|
## This program free software; you can redistribute it and/or modify |
6
|
|
|
|
|
|
|
## it under the terms of the GNU General Public License v2. |
7
|
|
|
|
|
|
|
## |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
package Net::DRI::Protocol::EPP::Extensions::IT::Domain; |
10
|
|
|
|
|
|
|
|
11
|
1
|
|
|
1
|
|
693
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
42
|
|
12
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
272
|
|
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
=pod |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=head1 NAME |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
Net::DRI::Protocol::EPP::Extensions::IT::Domain - .IT EPP Domain extension for Net::DRI |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=head1 SUPPORT |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
For now, support questions should be sent to: |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
Enoc@towertech.itE |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
Please also see the SUPPORT file in the distribution. |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=head1 AUTHOR |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
Alessandro Zummo, Ea.zummo@towertech.itE |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head1 COPYRIGHT |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
Copyright (C) 2009-2010 Tower Technologies. |
35
|
|
|
|
|
|
|
All rights reserved. |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
This program is free software; you can redistribute it and/or modify |
38
|
|
|
|
|
|
|
it under the terms of the GNU General Public License v2 as published by |
39
|
|
|
|
|
|
|
the Free Software Foundation. |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
See the LICENSE file that comes with this distribution for more details. |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=cut |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
sub register_commands { |
46
|
|
|
|
|
|
|
|
47
|
0
|
|
|
0
|
0
|
|
my ($class, $version) = @_; |
48
|
|
|
|
|
|
|
|
49
|
0
|
|
|
|
|
|
my $ops = { |
50
|
|
|
|
|
|
|
'info' => [ undef, \&parse ], |
51
|
|
|
|
|
|
|
}; |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
return { |
54
|
0
|
|
|
|
|
|
'domain' => $ops, |
55
|
|
|
|
|
|
|
}; |
56
|
|
|
|
|
|
|
} |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
sub parse |
59
|
|
|
|
|
|
|
{ |
60
|
0
|
|
|
0
|
0
|
|
my ($po, $type, $action, $name, $info) = @_; |
61
|
|
|
|
|
|
|
|
62
|
0
|
|
|
|
|
|
my $msg = $po->message; |
63
|
0
|
|
|
|
|
|
my $ns = $msg->ns('it_domain'); |
64
|
|
|
|
|
|
|
|
65
|
0
|
|
|
|
|
|
my $infdata = $msg->get_extension('it_domain', 'infData'); |
66
|
0
|
|
|
|
|
|
my $infns = $msg->get_extension('it_domain', 'infNsToValidateData'); |
67
|
|
|
|
|
|
|
|
68
|
0
|
0
|
|
|
|
|
if (defined $infdata) { |
69
|
|
|
|
|
|
|
|
70
|
0
|
|
|
|
|
|
$info->{'domain'}{$name}{'own_status'} = |
71
|
|
|
|
|
|
|
$infdata->getChildrenByTagNameNS($ns, 'ownStatus') |
72
|
|
|
|
|
|
|
->shift |
73
|
|
|
|
|
|
|
->getAttribute('s'); |
74
|
|
|
|
|
|
|
} |
75
|
|
|
|
|
|
|
|
76
|
0
|
0
|
|
|
|
|
if (defined $infns) { |
77
|
|
|
|
|
|
|
|
78
|
|
|
|
|
|
|
# cannot match ./extdom:nsToValidate/domain:hostAttr/domain:hostName |
79
|
|
|
|
|
|
|
# due to mixed namespace |
80
|
0
|
|
|
|
|
|
foreach ($infns->findnodes('./extdom:nsToValidate/*/*')) { |
81
|
|
|
|
|
|
|
|
82
|
0
|
0
|
|
|
|
|
push(@{$info->{'domain'}{$name}{'ns_to_validate'}}, |
|
0
|
|
|
|
|
|
|
83
|
|
|
|
|
|
|
$_->textContent) |
84
|
|
|
|
|
|
|
if $_->getName eq 'domain:hostName'; |
85
|
|
|
|
|
|
|
} |
86
|
|
|
|
|
|
|
} |
87
|
|
|
|
|
|
|
|
88
|
0
|
|
|
|
|
|
return 1; |
89
|
|
|
|
|
|
|
} |
90
|
|
|
|
|
|
|
|
91
|
|
|
|
|
|
|
1; |