whois 1.5.1 → 1.6.0
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.rdoc +53 -1
- data/lib/whois/answer/parser/NOTES.txt +37 -13
- data/lib/whois/answer/parser/kero.yachay.pe.rb +78 -0
- data/lib/whois/answer/parser/whois.audns.net.au.rb +1 -9
- data/lib/whois/answer/parser/whois.domain-registry.nl.rb +1 -0
- data/lib/whois/answer/parser/whois.domainregistry.my.rb +81 -0
- data/lib/whois/answer/parser/whois.educause.edu.rb +3 -3
- data/lib/whois/answer/parser/whois.na-nic.com.na.rb +90 -0
- data/lib/whois/answer/parser/whois.netcom.cm.rb +2 -0
- data/lib/whois/answer/parser/whois.nic.ac.rb +12 -7
- data/lib/whois/answer/parser/whois.nic.ag.rb +1 -1
- data/lib/whois/answer/parser/whois.nic.cd.rb +1 -1
- data/lib/whois/answer/parser/whois.nic.fr.rb +3 -0
- data/lib/whois/answer/parser/whois.nic.gl.rb +11 -7
- data/lib/whois/answer/parser/whois.nic.gs.rb +3 -3
- data/lib/whois/answer/parser/whois.nic.io.rb +38 -6
- data/lib/whois/answer/parser/whois.nic.ki.rb +90 -0
- data/lib/whois/answer/parser/whois.nic.md.rb +35 -6
- data/lib/whois/answer/parser/whois.nic.mg.rb +90 -0
- data/lib/whois/answer/parser/whois.nic.ms.rb +90 -0
- data/lib/whois/answer/parser/whois.nic.mu.rb +5 -3
- data/lib/whois/answer/parser/whois.nic.net.nf.rb +90 -0
- data/lib/whois/answer/parser/whois.nic.net.ng.rb +90 -0
- data/lib/whois/answer/parser/whois.nic.tm.rb +99 -0
- data/lib/whois/answer/parser/whois.nic.uk.rb +7 -4
- data/lib/whois/answer/parser/whois.nic.ve.rb +8 -5
- data/lib/whois/answer/parser/whois.pnina.ps.rb +86 -0
- data/lib/whois/answer/parser/whois.tznic.or.tz.rb +85 -0
- data/lib/whois/definitions/tlds.rb +8 -8
- data/lib/whois/version.rb +2 -2
- data/whois.gemspec +3 -3
- metadata +16 -5
data/CHANGELOG.rdoc
CHANGED
@@ -1,10 +1,62 @@
|
|
1
1
|
= Changelog
|
2
2
|
|
3
|
+
|
4
|
+
== Release 1.6.0
|
5
|
+
|
6
|
+
* SERVER: Updated the .nc TLD definition.
|
7
|
+
|
8
|
+
* SERVER: Updated the .nf TLD definition.
|
9
|
+
|
10
|
+
* SERVER: Updated the .ng TLD definition.
|
11
|
+
|
12
|
+
* SERVER: Updated the .pe TLD definition.
|
13
|
+
|
14
|
+
* SERVER: Updated the .sb TLD definition.
|
15
|
+
|
16
|
+
* SERVER: Updated the .ki/.mu TLD definition.
|
17
|
+
|
18
|
+
* SERVER: Updated the .tf TLD definition.
|
19
|
+
|
20
|
+
* NEW: Added simple .mg TLD parser (whois.nic.mg).
|
21
|
+
|
22
|
+
* NEW: Added simple .ms TLD parser (whois.nic.ms).
|
23
|
+
|
24
|
+
* NEW: Added simple .ms TLD parser (whois.domainregistry.my).
|
25
|
+
|
26
|
+
* NEW: Added simple .na TLD parser (whois.na-nic.com.na).
|
27
|
+
|
28
|
+
* NEW: Added simple .nf TLD parser (whois.nic.net.nf).
|
29
|
+
|
30
|
+
* NEW: Added simple .ng TLD parser (whois.nic.net.ng).
|
31
|
+
|
32
|
+
* NEW: Added simple .pe TLD parser (kero.yachay.pe).
|
33
|
+
|
34
|
+
* NEW: Added simple .ps TLD parser (whois.pnina.ps).
|
35
|
+
|
36
|
+
* NEW: Added simple .ki TLD parser (whois.pnina.ps).
|
37
|
+
|
38
|
+
* NEW: Added .tm TLD parser (whois.nic.tm).
|
39
|
+
|
40
|
+
* NEW: Added .tz TLD parser (whois.tznic.or.tz).
|
41
|
+
|
42
|
+
* CHANGED: Completed .md TLD parser (whois.nic.md).
|
43
|
+
|
44
|
+
* CHANGED: Completed .io TLD parser (whois.nic.io).
|
45
|
+
|
46
|
+
* FIXED: Fixed Unknown status `Registration request being processed.' for whois.nic.uk.
|
47
|
+
|
48
|
+
* FIXED: whois.nic.ve supports expires_on.
|
49
|
+
|
50
|
+
* FIXED: With some .uk domains, whois.nic.uk parser returns invalid values for nameservers.
|
51
|
+
|
52
|
+
* FIXED: whois.audns.net.au record can contain multiple statuses.
|
53
|
+
|
54
|
+
|
3
55
|
== Release 1.5.1
|
4
56
|
|
5
57
|
* NEW: Added simple .kg TLD parser (whois.domain.kg).
|
6
58
|
|
7
|
-
* NEW: Added
|
59
|
+
* NEW: Added .md TLD parser (whois.nic.md).
|
8
60
|
|
9
61
|
* FIXED: Fixed Unknown status `Renewal request being processed.' for whois.nic.uk.
|
10
62
|
|
@@ -1,31 +1,55 @@
|
|
1
1
|
.us
|
2
2
|
.biz
|
3
3
|
.travel
|
4
|
-
whois.nic.co
|
4
|
+
whois.nic.co
|
5
5
|
|
6
|
-
whois.museum
|
7
|
-
whois.cat
|
6
|
+
whois.museum
|
7
|
+
whois.cat
|
8
8
|
|
9
9
|
.ve
|
10
10
|
.uy
|
11
11
|
|
12
|
-
|
13
|
-
whois.dotmobyregistry.net
|
14
|
-
whois.afilias.info
|
15
|
-
whois.afilias-grs.info
|
16
|
-
whois.aero
|
17
|
-
whois.nic.af (.af)
|
18
|
-
whois.registry.in (.in)
|
19
|
-
|
20
|
-
whois.nic.af (.af)
|
21
|
-
whois.nic.gs (.gs)
|
12
|
+
# afilias
|
13
|
+
whois.dotmobyregistry.net
|
14
|
+
whois.afilias.info
|
15
|
+
whois.afilias-grs.info
|
16
|
+
whois.aero
|
22
17
|
|
23
18
|
whois.nic.af
|
19
|
+
whois.nic.mu
|
20
|
+
whois.nic.gl
|
21
|
+
whois.nic.gs
|
22
|
+
whois.nic.mg
|
23
|
+
whois.na-nic.com.na
|
24
|
+
kero.yachay.pe
|
24
25
|
whois.kenic.or.ke
|
25
26
|
|
27
|
+
# http://coccaregistry.net/index.php/whois.html
|
28
|
+
whois.nic.cx
|
29
|
+
whois.nic.gs
|
30
|
+
whois.nic.ki
|
31
|
+
whois.nic.net.nf
|
32
|
+
whois.nic.net.sb
|
33
|
+
whois.nic.tl
|
34
|
+
whois.nic.ms
|
35
|
+
|
36
|
+
# AFNIC
|
37
|
+
whois.nic.fr
|
38
|
+
whois.nic.pm (CNAME whois.nic.fr)
|
39
|
+
whois.nic.re (CNAME whois.nic.fr)
|
40
|
+
whois.nic.wf (CNAME whois.nic.fr)
|
41
|
+
whois.nic.tf (CNAME whois.nic.fr)
|
42
|
+
whois.nic.yt (CNAME whois.nic.fr)
|
43
|
+
|
44
|
+
whois.nic.cz
|
45
|
+
whois.tznic.or.tz
|
26
46
|
whois.pandi.or.id
|
27
47
|
whois.nic.ir
|
28
48
|
ripe.net
|
29
49
|
|
50
|
+
whois.nic.ac
|
51
|
+
whois.nic.io
|
52
|
+
whois.nic.tm
|
53
|
+
|
30
54
|
whois.gg
|
31
55
|
whois.je
|
@@ -0,0 +1,78 @@
|
|
1
|
+
#
|
2
|
+
# = Ruby Whois
|
3
|
+
#
|
4
|
+
# An intelligent pure Ruby WHOIS client and parser.
|
5
|
+
#
|
6
|
+
#
|
7
|
+
# Category:: Net
|
8
|
+
# Package:: Whois
|
9
|
+
# Author:: Simone Carletti <weppos@weppos.net>
|
10
|
+
# License:: MIT License
|
11
|
+
#
|
12
|
+
#--
|
13
|
+
#
|
14
|
+
#++
|
15
|
+
|
16
|
+
|
17
|
+
require 'whois/answer/parser/base'
|
18
|
+
|
19
|
+
|
20
|
+
module Whois
|
21
|
+
class Answer
|
22
|
+
class Parser
|
23
|
+
|
24
|
+
#
|
25
|
+
# = kero.yachay.pe parser
|
26
|
+
#
|
27
|
+
# Parser for the kero.yachay.pe server.
|
28
|
+
#
|
29
|
+
# NOTE: This parser is just a stub and provides only a few basic methods
|
30
|
+
# to check for domain availability and get domain status.
|
31
|
+
# Please consider to contribute implementing missing methods.
|
32
|
+
# See WhoisNicIt parser for an explanation of all available methods
|
33
|
+
# and examples.
|
34
|
+
#
|
35
|
+
class KeroYachayPe < Base
|
36
|
+
|
37
|
+
property_supported :status do
|
38
|
+
@status ||= if content_for_scanner =~ /Status:\s+(.+?)\n/
|
39
|
+
case $1.downcase
|
40
|
+
when "active" then :registered
|
41
|
+
when "not registered" then :available
|
42
|
+
else
|
43
|
+
Whois.bug!(ParserError, "Unknown status `#{$1}'.")
|
44
|
+
end
|
45
|
+
else
|
46
|
+
Whois.bug!(ParserError, "Unable to parse status.")
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
property_supported :available? do
|
51
|
+
@available ||= (status == :available)
|
52
|
+
end
|
53
|
+
|
54
|
+
property_supported :registered? do
|
55
|
+
@registered ||= !available?
|
56
|
+
end
|
57
|
+
|
58
|
+
|
59
|
+
property_not_supported :created_on
|
60
|
+
|
61
|
+
property_not_supported :updated_on
|
62
|
+
|
63
|
+
property_not_supported :expires_on
|
64
|
+
|
65
|
+
|
66
|
+
property_supported :nameservers do
|
67
|
+
@nameservers ||= if content_for_scanner =~ /Name Servers:\n((.+\n)+)\n/
|
68
|
+
$1.split("\n").map(&:strip)
|
69
|
+
else
|
70
|
+
[]
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
74
|
+
end
|
75
|
+
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
@@ -35,15 +35,7 @@ module Whois
|
|
35
35
|
class WhoisAudnsNetAu < Base
|
36
36
|
|
37
37
|
property_supported :status do
|
38
|
-
@status ||=
|
39
|
-
case $1.downcase
|
40
|
-
when "ok" then :registered
|
41
|
-
else
|
42
|
-
Whois.bug!(ParserError, "Unknown status `#{$1}'.")
|
43
|
-
end
|
44
|
-
else
|
45
|
-
:available
|
46
|
-
end
|
38
|
+
@status ||= content_for_scanner.scan(/Status:\s+(.+?)\n/).flatten
|
47
39
|
end
|
48
40
|
|
49
41
|
property_supported :available? do
|
@@ -0,0 +1,81 @@
|
|
1
|
+
#
|
2
|
+
# = Ruby Whois
|
3
|
+
#
|
4
|
+
# An intelligent pure Ruby WHOIS client and parser.
|
5
|
+
#
|
6
|
+
#
|
7
|
+
# Category:: Net
|
8
|
+
# Package:: Whois
|
9
|
+
# Author:: Simone Carletti <weppos@weppos.net>
|
10
|
+
# License:: MIT License
|
11
|
+
#
|
12
|
+
#--
|
13
|
+
#
|
14
|
+
#++
|
15
|
+
|
16
|
+
|
17
|
+
require 'whois/answer/parser/base'
|
18
|
+
|
19
|
+
|
20
|
+
module Whois
|
21
|
+
class Answer
|
22
|
+
class Parser
|
23
|
+
|
24
|
+
#
|
25
|
+
# = whois.domainregistry.my parser
|
26
|
+
#
|
27
|
+
# Parser for the whois.domainregistry.my server.
|
28
|
+
#
|
29
|
+
# NOTE: This parser is just a stub and provides only a few basic methods
|
30
|
+
# to check for domain availability and get domain status.
|
31
|
+
# Please consider to contribute implementing missing methods.
|
32
|
+
# See WhoisNicIt parser for an explanation of all available methods
|
33
|
+
# and examples.
|
34
|
+
#
|
35
|
+
class WhoisDomainregistryMy < Base
|
36
|
+
|
37
|
+
property_supported :status do
|
38
|
+
@status ||= if available?
|
39
|
+
:available
|
40
|
+
else
|
41
|
+
:registered
|
42
|
+
end
|
43
|
+
end
|
44
|
+
|
45
|
+
property_supported :available? do
|
46
|
+
@available ||= !!(content_for_scanner =~ /Domain Name [^ ]+ does not exist in database/)
|
47
|
+
end
|
48
|
+
|
49
|
+
property_supported :registered? do
|
50
|
+
@registered ||= !available?
|
51
|
+
end
|
52
|
+
|
53
|
+
|
54
|
+
property_supported :created_on do
|
55
|
+
@created_on ||= if content_for_scanner =~ /\[Record Created\]\s+(.+?)\n/
|
56
|
+
Time.parse($1)
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
property_supported :updated_on do
|
61
|
+
@updated_on ||= if content_for_scanner =~ /\[Record Last Modified\]\s+(.+?)\n/
|
62
|
+
Time.parse($1)
|
63
|
+
end
|
64
|
+
end
|
65
|
+
|
66
|
+
property_supported :expires_on do
|
67
|
+
@expires_on ||= if content_for_scanner =~ /\[Record Expired\]\s+(.+?)\n/
|
68
|
+
Time.parse($1)
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
|
73
|
+
property_supported :nameservers do
|
74
|
+
@nameservers ||= content_for_scanner.scan(/\[(?:Primary|Secondary) Name Server\](?:.+?)\n(.+\n)/).flatten.map { |value| value.split(" ").first }
|
75
|
+
end
|
76
|
+
|
77
|
+
end
|
78
|
+
|
79
|
+
end
|
80
|
+
end
|
81
|
+
end
|
@@ -52,19 +52,19 @@ module Whois
|
|
52
52
|
|
53
53
|
|
54
54
|
property_supported :created_on do
|
55
|
-
@created_on ||= if content_for_scanner =~ /Domain record activated:\s+(
|
55
|
+
@created_on ||= if content_for_scanner =~ /Domain record activated:\s+(.+?)\n/
|
56
56
|
Time.parse($1)
|
57
57
|
end
|
58
58
|
end
|
59
59
|
|
60
60
|
property_supported :updated_on do
|
61
|
-
@updated_on ||= if content_for_scanner =~ /Domain record last updated:\s+(
|
61
|
+
@updated_on ||= if content_for_scanner =~ /Domain record last updated:\s+(.+?)\n/
|
62
62
|
Time.parse($1)
|
63
63
|
end
|
64
64
|
end
|
65
65
|
|
66
66
|
property_supported :expires_on do
|
67
|
-
@expires_on ||= if content_for_scanner =~ /Domain expires:\s+(
|
67
|
+
@expires_on ||= if content_for_scanner =~ /Domain expires:\s+(.+?)\n/
|
68
68
|
Time.parse($1)
|
69
69
|
end
|
70
70
|
end
|
@@ -0,0 +1,90 @@
|
|
1
|
+
#
|
2
|
+
# = Ruby Whois
|
3
|
+
#
|
4
|
+
# An intelligent pure Ruby WHOIS client and parser.
|
5
|
+
#
|
6
|
+
#
|
7
|
+
# Category:: Net
|
8
|
+
# Package:: Whois
|
9
|
+
# Author:: Simone Carletti <weppos@weppos.net>
|
10
|
+
# License:: MIT License
|
11
|
+
#
|
12
|
+
#--
|
13
|
+
#
|
14
|
+
#++
|
15
|
+
|
16
|
+
|
17
|
+
require 'whois/answer/parser/base'
|
18
|
+
|
19
|
+
|
20
|
+
module Whois
|
21
|
+
class Answer
|
22
|
+
class Parser
|
23
|
+
|
24
|
+
#
|
25
|
+
# = whois.na-nic.com.na parser
|
26
|
+
#
|
27
|
+
# Parser for the whois.na-nic.com.na server.
|
28
|
+
#
|
29
|
+
# NOTE: This parser is just a stub and provides only a few basic methods
|
30
|
+
# to check for domain availability and get domain status.
|
31
|
+
# Please consider to contribute implementing missing methods.
|
32
|
+
# See WhoisNicIt parser for an explanation of all available methods
|
33
|
+
# and examples.
|
34
|
+
#
|
35
|
+
class WhoisNaNicComNa < Base
|
36
|
+
|
37
|
+
property_supported :status do
|
38
|
+
@status ||= if content_for_scanner =~ /Status:\s+(.+?)\n/
|
39
|
+
case $1.downcase
|
40
|
+
when "active" then :registered
|
41
|
+
when "not registered" then :available
|
42
|
+
else
|
43
|
+
Whois.bug!(ParserError, "Unknown status `#{$1}'.")
|
44
|
+
end
|
45
|
+
else
|
46
|
+
Whois.bug!(ParserError, "Unable to parse status.")
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
property_supported :available? do
|
51
|
+
@available ||= (status == :available)
|
52
|
+
end
|
53
|
+
|
54
|
+
property_supported :registered? do
|
55
|
+
@registered ||= !available?
|
56
|
+
end
|
57
|
+
|
58
|
+
|
59
|
+
property_supported :created_on do
|
60
|
+
@created_on ||= if content_for_scanner =~ /Created:\s+(.+?)\n/
|
61
|
+
Time.parse($1)
|
62
|
+
end
|
63
|
+
end
|
64
|
+
|
65
|
+
property_supported :updated_on do
|
66
|
+
@updated_on ||= if content_for_scanner =~ /Modified:\s+(.+?)\n/
|
67
|
+
Time.parse($1)
|
68
|
+
end
|
69
|
+
end
|
70
|
+
|
71
|
+
property_supported :expires_on do
|
72
|
+
@expires_on ||= if content_for_scanner =~ /Expires:\s+(.+?)\n/
|
73
|
+
Time.parse($1)
|
74
|
+
end
|
75
|
+
end
|
76
|
+
|
77
|
+
|
78
|
+
property_supported :nameservers do
|
79
|
+
@nameservers ||= if content_for_scanner =~ /Name Servers:\n((.+\n)+)\n/
|
80
|
+
$1.split("\n").map { |value| value.strip.downcase }
|
81
|
+
else
|
82
|
+
[]
|
83
|
+
end
|
84
|
+
end
|
85
|
+
|
86
|
+
end
|
87
|
+
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
@@ -30,16 +30,21 @@ module Whois
|
|
30
30
|
|
31
31
|
property_not_supported :disclaimer
|
32
32
|
|
33
|
+
|
33
34
|
property_supported :domain do
|
34
|
-
@domain ||=
|
35
|
-
content_for_scanner =~ /Domain "(.*?)"/
|
35
|
+
@domain ||= if content_for_scanner =~ /Domain "(.+?)"/
|
36
36
|
$1.downcase
|
37
|
-
end
|
37
|
+
end
|
38
38
|
end
|
39
39
|
|
40
40
|
property_not_supported :domain_id
|
41
41
|
|
42
42
|
|
43
|
+
property_not_supported :referral_whois
|
44
|
+
|
45
|
+
property_not_supported :referral_url
|
46
|
+
|
47
|
+
|
43
48
|
property_supported :status do
|
44
49
|
@status ||= if available?
|
45
50
|
:available
|
@@ -49,7 +54,7 @@ module Whois
|
|
49
54
|
end
|
50
55
|
|
51
56
|
property_supported :available? do
|
52
|
-
@available ||=
|
57
|
+
@available ||= !!(content_for_scanner =~ /- Available/)
|
53
58
|
end
|
54
59
|
|
55
60
|
property_supported :registered? do
|
@@ -77,13 +82,13 @@ module Whois
|
|
77
82
|
|
78
83
|
|
79
84
|
# NEWPROPERTY
|
80
|
-
|
85
|
+
def changed?(other)
|
81
86
|
!unchanged?(other)
|
82
87
|
end
|
83
88
|
|
84
89
|
# NEWPROPERTY
|
85
|
-
|
86
|
-
self
|
90
|
+
def unchanged?(other)
|
91
|
+
self.equal?(other) ||
|
87
92
|
self.content_for_scanner == other.content_for_scanner
|
88
93
|
end
|
89
94
|
|
@@ -35,7 +35,7 @@ module Whois
|
|
35
35
|
class WhoisNicCd < Base
|
36
36
|
|
37
37
|
property_supported :status do
|
38
|
-
content_for_scanner.scan(/\s+Domain Status:\s+(.+?)\n/).flatten
|
38
|
+
@status ||= content_for_scanner.scan(/\s+Domain Status:\s+(.+?)\n/).flatten
|
39
39
|
end
|
40
40
|
|
41
41
|
property_supported :available? do
|
@@ -38,6 +38,8 @@ module Whois
|
|
38
38
|
@status ||= if content_for_scanner =~ /status:\s+(.+)\n/
|
39
39
|
case $1.downcase
|
40
40
|
when "active" then :registered
|
41
|
+
# NEWSTATUS
|
42
|
+
when "frozen" then :frozen
|
41
43
|
else
|
42
44
|
Whois.bug!(ParserError, "Unknown status `#{$1}'.")
|
43
45
|
end
|
@@ -69,6 +71,7 @@ module Whois
|
|
69
71
|
end
|
70
72
|
end
|
71
73
|
|
74
|
+
# TODO: Use anniversary
|
72
75
|
property_not_supported :expires_on
|
73
76
|
|
74
77
|
|
@@ -35,11 +35,15 @@ module Whois
|
|
35
35
|
class WhoisNicGl < Base
|
36
36
|
|
37
37
|
property_supported :status do
|
38
|
-
@status ||= if content_for_scanner =~ /Status:\s+(
|
39
|
-
case $1.downcase
|
40
|
-
when
|
41
|
-
when
|
38
|
+
@status ||= if content_for_scanner =~ /Status:\s+(.+?)\n/
|
39
|
+
case $1.downcase
|
40
|
+
when "active" then :registered
|
41
|
+
when "not registered" then :available
|
42
|
+
else
|
43
|
+
Whois.bug!(ParserError, "Unknown status `#{$1}'.")
|
42
44
|
end
|
45
|
+
else
|
46
|
+
Whois.bug!(ParserError, "Unable to parse status.")
|
43
47
|
end
|
44
48
|
end
|
45
49
|
|
@@ -53,19 +57,19 @@ module Whois
|
|
53
57
|
|
54
58
|
|
55
59
|
property_supported :created_on do
|
56
|
-
@created_on ||= if content_for_scanner =~ /Created:\s+(
|
60
|
+
@created_on ||= if content_for_scanner =~ /Created:\s+(.+?)\n/
|
57
61
|
Time.parse($1)
|
58
62
|
end
|
59
63
|
end
|
60
64
|
|
61
65
|
property_supported :updated_on do
|
62
|
-
@updated_on ||= if content_for_scanner =~ /Modified:\s+(
|
66
|
+
@updated_on ||= if content_for_scanner =~ /Modified:\s+(.+?)\n/
|
63
67
|
Time.parse($1)
|
64
68
|
end
|
65
69
|
end
|
66
70
|
|
67
71
|
property_supported :expires_on do
|
68
|
-
@expires_on ||= if content_for_scanner =~ /Expires:\s+(
|
72
|
+
@expires_on ||= if content_for_scanner =~ /Expires:\s+(.+?)\n/
|
69
73
|
Time.parse($1)
|
70
74
|
end
|
71
75
|
end
|
@@ -57,19 +57,19 @@ module Whois
|
|
57
57
|
|
58
58
|
|
59
59
|
property_supported :created_on do
|
60
|
-
@created_on ||= if content_for_scanner =~ /Created:\s+(
|
60
|
+
@created_on ||= if content_for_scanner =~ /Created:\s+(.+?)\n/
|
61
61
|
Time.parse($1)
|
62
62
|
end
|
63
63
|
end
|
64
64
|
|
65
65
|
property_supported :updated_on do
|
66
|
-
@updated_on ||= if content_for_scanner =~ /Modified:\s+(
|
66
|
+
@updated_on ||= if content_for_scanner =~ /Modified:\s+(.+?)\n/
|
67
67
|
Time.parse($1)
|
68
68
|
end
|
69
69
|
end
|
70
70
|
|
71
71
|
property_supported :expires_on do
|
72
|
-
@expires_on ||= if content_for_scanner =~ /Expires:\s+(
|
72
|
+
@expires_on ||= if content_for_scanner =~ /Expires:\s+(.+?)\n/
|
73
73
|
Time.parse($1)
|
74
74
|
end
|
75
75
|
end
|
@@ -26,14 +26,25 @@ module Whois
|
|
26
26
|
#
|
27
27
|
# Parser for the whois.nic.io server.
|
28
28
|
#
|
29
|
-
# NOTE: This parser is just a stub and provides only a few basic methods
|
30
|
-
# to check for domain availability and get domain status.
|
31
|
-
# Please consider to contribute implementing missing methods.
|
32
|
-
# See WhoisNicIt parser for an explanation of all available methods
|
33
|
-
# and examples.
|
34
|
-
#
|
35
29
|
class WhoisNicIo < Base
|
36
30
|
|
31
|
+
property_not_supported :disclaimer
|
32
|
+
|
33
|
+
|
34
|
+
property_supported :domain do
|
35
|
+
@domain ||= if content_for_scanner =~ /Domain "(.+?)"/
|
36
|
+
$1.downcase
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
property_not_supported :domain_id
|
41
|
+
|
42
|
+
|
43
|
+
property_not_supported :referral_whois
|
44
|
+
|
45
|
+
property_not_supported :referral_url
|
46
|
+
|
47
|
+
|
37
48
|
property_supported :status do
|
38
49
|
@status ||= if available?
|
39
50
|
:available
|
@@ -58,8 +69,29 @@ module Whois
|
|
58
69
|
property_not_supported :expires_on
|
59
70
|
|
60
71
|
|
72
|
+
property_not_supported :registrar
|
73
|
+
|
74
|
+
property_not_supported :registrant_contact
|
75
|
+
|
76
|
+
property_not_supported :admin_contact
|
77
|
+
|
78
|
+
property_not_supported :technical_contact
|
79
|
+
|
80
|
+
|
61
81
|
property_not_supported :nameservers
|
62
82
|
|
83
|
+
|
84
|
+
# NEWPROPERTY
|
85
|
+
def changed?(other)
|
86
|
+
!unchanged?(other)
|
87
|
+
end
|
88
|
+
|
89
|
+
# NEWPROPERTY
|
90
|
+
def unchanged?(other)
|
91
|
+
self.equal?(other) ||
|
92
|
+
self.content_for_scanner == other.content_for_scanner
|
93
|
+
end
|
94
|
+
|
63
95
|
end
|
64
96
|
|
65
97
|
end
|