whois 3.2.1 → 3.3.0

Sign up to get free protection for your applications and to get access to all the features.
data/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # Changelog
2
2
 
3
+
4
+ ## Release 3.3.0
5
+
6
+ - SERVER: Added .CF TLD definition.
7
+
8
+ - NEW: Added whois.dot.cf parser.
9
+
10
+ - NEW: Added support for ASN queries (GH-243). [Thanks @linrock]
11
+
12
+ - FIXED: Added contact support for whois.nic.ch (GH-246). [Thanks @Pietr]
13
+
14
+ - CHANGED: Deprecated Whois.query. Replaced with Whois.lookup to match client. Fixed README to use Whois.whois instead of Whois.lookup
15
+
16
+ - FIXED: whois.nic.lk crashes when the update date is 'null'.
17
+
18
+ - FIXED: whois.cira.ca should support 'pending delete' status.
19
+
20
+ - FIXED: whois.fi should support 'Grace Period' status (GH-252). [Thanks @Pietr]
21
+
22
+ - FIXED: additional status for whois.ua (GH-244). [Thanks @Pietr]
23
+
24
+ - FIXED: whois.jprs.jp should support 'Registered' status (GH-253). [Thanks @Pietr]
25
+
26
+
3
27
  ## Release 3.2.1
4
28
 
5
29
  - NEW: Added full whois.nic.tr parser.
@@ -23,7 +47,7 @@
23
47
 
24
48
  ## Release 3.2.0
25
49
 
26
- - SERVER: Added .JP.NET (GH-240), XN--J1AMH TLD definition.
50
+ - SERVER: Added .JP.NET (GH-240), XN--J1AMH TLD definitions.
27
51
 
28
52
  - NEW: Added #domain_id to CoCCA parsers.
29
53
 
@@ -1892,4 +1916,4 @@ API might change at any time without previous notice.
1892
1916
 
1893
1917
  ## Release 0.1.0
1894
1918
 
1895
- * First release
1919
+ * First release
data/README.md CHANGED
@@ -91,7 +91,7 @@ The query method is stateless. For this reason, you can safely re-use the same c
91
91
 
92
92
  If you just need a WHOIS response and you don't care about a full control of the WHOIS client, the {Whois} module provides an all-in-one method called {Whois.whois}. This is the simplest way to send a WHOIS request.
93
93
 
94
- Whois.lookup("google.com")
94
+ Whois.whois("google.com")
95
95
  # => #<Whois::Record>
96
96
 
97
97
  Did I mention you can even use blocks?
data/data/asn16.json ADDED
@@ -0,0 +1,212 @@
1
+ {
2
+ "248 251": {
3
+ "host": "whois.ripe.net"
4
+ },
5
+ "306 371": {
6
+ "host": "whois.nic.mil"
7
+ },
8
+ "379 508": {
9
+ "host": "whois.nic.mil"
10
+ },
11
+ "1101 1200": {
12
+ "host": "whois.ripe.net"
13
+ },
14
+ "1267 1275": {
15
+ "host": "whois.ripe.net"
16
+ },
17
+ "1877 1901": {
18
+ "host": "whois.ripe.net"
19
+ },
20
+ "2043 2043": {
21
+ "host": "whois.ripe.net"
22
+ },
23
+ "2047 2047": {
24
+ "host": "whois.ripe.net"
25
+ },
26
+ "2057 2136": {
27
+ "host": "whois.ripe.net"
28
+ },
29
+ "2387 2488": {
30
+ "host": "whois.ripe.net"
31
+ },
32
+ "2497 2528": {
33
+ "host": "whois.nic.ad.jp"
34
+ },
35
+ "2585 2614": {
36
+ "host": "whois.ripe.net"
37
+ },
38
+ "2773 2822": {
39
+ "host": "whois.ripe.net"
40
+ },
41
+ "2830 2879": {
42
+ "host": "whois.ripe.net"
43
+ },
44
+ "3154 3353": {
45
+ "host": "whois.ripe.net"
46
+ },
47
+ "4608 4864": {
48
+ "host": "whois.apnic.net"
49
+ },
50
+ "5120 5376": {
51
+ "host": "whois.nic.mil"
52
+ },
53
+ "5377 5631": {
54
+ "host": "whois.ripe.net"
55
+ },
56
+ "5800 6055": {
57
+ "host": "whois.nic.mil"
58
+ },
59
+ "6656 6911": {
60
+ "host": "whois.ripe.net"
61
+ },
62
+ "7467 7722": {
63
+ "host": "whois.apnic.net"
64
+ },
65
+ "8192 9215": {
66
+ "host": "whois.ripe.net"
67
+ },
68
+ "9591 9622": {
69
+ "host": "whois.nic.ad.jp"
70
+ },
71
+ "9628 9647": {
72
+ "host": "whois.nic.or.kr"
73
+ },
74
+ "9683 9712": {
75
+ "host": "whois.nic.or.kr"
76
+ },
77
+ "9753 9784": {
78
+ "host": "whois.nic.or.kr"
79
+ },
80
+ "9840 9871": {
81
+ "host": "whois.nic.or.kr"
82
+ },
83
+ "9943 9982": {
84
+ "host": "whois.nic.or.kr"
85
+ },
86
+ "9990 10021": {
87
+ "host": "whois.nic.ad.jp"
88
+ },
89
+ "9216 10067": {
90
+ "host": "whois.apnic.net"
91
+ },
92
+ "10034 10073": {
93
+ "host": "whois.nic.or.kr"
94
+ },
95
+ "10154 10198": {
96
+ "host": "whois.nic.or.kr"
97
+ },
98
+ "10074 10239": {
99
+ "host": "whois.apnic.net"
100
+ },
101
+ "12288 13311": {
102
+ "host": "whois.ripe.net"
103
+ },
104
+ "15360 16383": {
105
+ "host": "whois.ripe.net"
106
+ },
107
+ "17503 17534": {
108
+ "host": "whois.nic.ad.jp"
109
+ },
110
+ "17567 17616": {
111
+ "host": "whois.nic.or.kr"
112
+ },
113
+ "17673 17704": {
114
+ "host": "whois.nic.ad.jp"
115
+ },
116
+ "17832 17880": {
117
+ "host": "whois.nic.or.kr"
118
+ },
119
+ "17408 18431": {
120
+ "host": "whois.apnic.net"
121
+ },
122
+ "17930 17961": {
123
+ "host": "whois.nic.ad.jp"
124
+ },
125
+ "18067 18098": {
126
+ "host": "whois.nic.ad.jp"
127
+ },
128
+ "18121 18152": {
129
+ "host": "whois.nic.ad.jp"
130
+ },
131
+ "18259 18290": {
132
+ "host": "whois.nic.ad.jp"
133
+ },
134
+ "18259 18290": {
135
+ "host": "whois.nic.ad.jp"
136
+ },
137
+ "20480 21503": {
138
+ "host": "whois.ripe.net"
139
+ },
140
+ "23552 24575": {
141
+ "host": "whois.apnic.net"
142
+ },
143
+ "23552 23601": {
144
+ "host": "whois.nic.or.kr"
145
+ },
146
+ "23612 23643": {
147
+ "host": "whois.nic.ad.jp"
148
+ },
149
+ "24576 25599": {
150
+ "host": "whois.ripe.net"
151
+ },
152
+ "26592 26623": {
153
+ "host": "whois.lacnic.net"
154
+ },
155
+ "27648 28671": {
156
+ "host": "whois.lacnic.net"
157
+ },
158
+ "28672 29695": {
159
+ "host": "whois.ripe.net"
160
+ },
161
+ "30980 30999": {
162
+ "host": "whois.afrinic.net"
163
+ },
164
+ "30720 31743": {
165
+ "host": "whois.ripe.net"
166
+ },
167
+ "34515 34519": {
168
+ "host": "whois.afrinic.net"
169
+ },
170
+ "33792 35839": {
171
+ "host": "whois.ripe.net"
172
+ },
173
+ "36864 37887": {
174
+ "host": "whois.afrinic.net"
175
+ },
176
+ "37888 38911": {
177
+ "host": "whois.apnic.net"
178
+ },
179
+ "38912 39935": {
180
+ "host": "whois.ripe.net"
181
+ },
182
+ "40960 45055": {
183
+ "host": "whois.ripe.net"
184
+ },
185
+ "45056 46079": {
186
+ "host": "whois.apnic.net"
187
+ },
188
+ "47104 52223": {
189
+ "host": "whois.ripe.net"
190
+ },
191
+ "52224 53247": {
192
+ "host": "whois.lacnic.net"
193
+ },
194
+ "55296 56319": {
195
+ "host": "whois.apnic.net"
196
+ },
197
+ "56320 58367": {
198
+ "host": "whois.ripe.net"
199
+ },
200
+ "58368 59391": {
201
+ "host": "whois.apnic.net"
202
+ },
203
+ "59392 61439": {
204
+ "host": "whois.ripe.net"
205
+ },
206
+ "61440 61951": {
207
+ "host": "whois.lacnic.net"
208
+ },
209
+ "1 63487": {
210
+ "host": "whois.arin.net"
211
+ }
212
+ }
data/data/asn32.json ADDED
@@ -0,0 +1,17 @@
1
+ {
2
+ "131072 133119": {
3
+ "host": "whois.apnic.net"
4
+ },
5
+ "196608 199679": {
6
+ "host": "whois.ripe.net"
7
+ },
8
+ "262144 263679": {
9
+ "host": "whois.lacnic.net"
10
+ },
11
+ "327680 328703": {
12
+ "host": "whois.afrinic.net"
13
+ },
14
+ "393216 394239": {
15
+ "host": "whois.arin.net"
16
+ }
17
+ }
data/data/tld.json CHANGED
@@ -319,8 +319,7 @@
319
319
  "host": "whois.nic.cd"
320
320
  },
321
321
  ".cf": {
322
- "host": null,
323
- "adapter": "none"
322
+ "host": "whois.dot.cf"
324
323
  },
325
324
  ".cg": {
326
325
  "host": null,
data/lib/whois/errors.rb CHANGED
@@ -47,7 +47,7 @@ module Whois
47
47
  class ServerNotSupported < ServerError
48
48
  end
49
49
 
50
- # Raised when unknown AS number of IP network. (\x06)
50
+ # Raised when unknown AS number or IP network. (\x06)
51
51
  #
52
52
  # Definition is recognized.
53
53
  class AllocationUnknown < ServerError
@@ -49,6 +49,8 @@ module Whois
49
49
  :registered
50
50
  when "to be released"
51
51
  :registered
52
+ when "pending delete"
53
+ :registered
52
54
  when "available"
53
55
  :available
54
56
  when "unavailable"
@@ -0,0 +1,73 @@
1
+ #--
2
+ # Ruby Whois
3
+ #
4
+ # An intelligent pure Ruby WHOIS client and parser.
5
+ #
6
+ # Copyright (c) 2009-2013 Simone Carletti <weppos@weppos.net>
7
+ #++
8
+
9
+
10
+ require 'whois/record/parser/base'
11
+
12
+
13
+ module Whois
14
+ class Record
15
+ class Parser
16
+
17
+ # Parser for the whois.dot.cf server.
18
+ #
19
+ # @note This parser is just a stub and provides only a few basic methods
20
+ # to check for domain availability and get domain status.
21
+ # Please consider to contribute implementing missing methods.
22
+ #
23
+ # @see Whois::Record::Parser::Example
24
+ # The Example parser for the list of all available methods.
25
+ #
26
+ class WhoisDotCf < Base
27
+
28
+ property_supported :status do
29
+ if available?
30
+ :available
31
+ else
32
+ :registered
33
+ end
34
+ end
35
+
36
+ property_supported :available? do
37
+ !!(content_for_scanner =~ /domain name not known/)
38
+ end
39
+
40
+ property_supported :registered? do
41
+ !available?
42
+ end
43
+
44
+
45
+ property_supported :created_on do
46
+ if content_for_scanner =~ /Domain registered:\s(.+)\n/
47
+ Time.strptime($1, "%m/%d/%Y")
48
+ end
49
+ end
50
+
51
+ property_not_supported :updated_on
52
+
53
+ property_supported :expires_on do
54
+ if content_for_scanner =~ /Record will expire on:\s(.+)\n/
55
+ value = $1.strip
56
+ Time.strptime(value, "%m/%d/%Y") if value.present?
57
+ end
58
+ end
59
+
60
+
61
+ property_supported :nameservers do
62
+ if content_for_scanner =~ /Domain Nameservers:\n((.+\n)+)\s+\n/
63
+ $1.split("\n").map do |name|
64
+ Record::Nameserver.new(name: name.strip.downcase)
65
+ end
66
+ end
67
+ end
68
+
69
+ end
70
+
71
+ end
72
+ end
73
+ end
@@ -14,16 +14,14 @@ module Whois
14
14
  class Record
15
15
  class Parser
16
16
 
17
- #
18
- # = whois.dot.tk parser
19
- #
20
17
  # Parser for the whois.dot.tk server.
21
18
  #
22
- # NOTE: This parser is just a stub and provides only a few basic methods
23
- # to check for domain availability and get domain status.
24
- # Please consider to contribute implementing missing methods.
25
- # See WhoisNicIt parser for an explanation of all available methods
26
- # and examples.
19
+ # @note This parser is just a stub and provides only a few basic methods
20
+ # to check for domain availability and get domain status.
21
+ # Please consider to contribute implementing missing methods.
22
+ #
23
+ # @see Whois::Record::Parser::Example
24
+ # The Example parser for the list of all available methods.
27
25
  #
28
26
  class WhoisDotTk < Base
29
27
 
@@ -45,16 +43,16 @@ module Whois
45
43
 
46
44
 
47
45
  property_supported :created_on do
48
- if content_for_scanner =~ /Domain registered:\s+(.*)\n/
49
- DateTime.strptime($1, "%m/%d/%Y").to_time
46
+ if content_for_scanner =~ /Domain registered:\s(.+)\n/
47
+ Time.strptime($1, "%m/%d/%Y")
50
48
  end
51
49
  end
52
50
 
53
51
  property_not_supported :updated_on
54
52
 
55
53
  property_supported :expires_on do
56
- if content_for_scanner =~ /Record will expire on:\s+(.*)\n/
57
- DateTime.strptime($1, "%m/%d/%Y").to_time
54
+ if content_for_scanner =~ /Record will expire on:\s(.+)\n/
55
+ Time.strptime($1, "%m/%d/%Y")
58
56
  end
59
57
  end
60
58
 
@@ -62,7 +60,7 @@ module Whois
62
60
  property_supported :nameservers do
63
61
  if content_for_scanner =~ /Domain Nameservers:\n((.+\n)+)\s+\n/
64
62
  $1.split("\n").map do |name|
65
- Record::Nameserver.new(:name => name.strip.downcase)
63
+ Record::Nameserver.new(name: name.strip.downcase)
66
64
  end
67
65
  end
68
66
  end
@@ -43,8 +43,10 @@ module Whois
43
43
  case node("status", &:downcase)
44
44
  when "granted"
45
45
  :registered
46
+ when "grace period"
47
+ :registered
46
48
  else
47
- Whois.bug!(ParserError, "Unknown status `#{$1}'.")
49
+ Whois.bug!(ParserError, "Unknown status `#{node("status")}'.")
48
50
  end
49
51
  else
50
52
  :available
@@ -57,76 +57,58 @@ module Whois
57
57
 
58
58
  property_supported :registrar do
59
59
  Record::Registrar.new(
60
- :name => content_for_scanner[/Registered through: (.+)\n/, 1],
60
+ :name => content_for_scanner[/Registrar: (.+)\n/, 1],
61
61
  :url => "http://www.godaddy.com/"
62
62
  )
63
63
  end
64
64
 
65
65
  property_supported :registrant_contacts do
66
- build_contact('Registrant:', Record::Contact::TYPE_REGISTRANT)
66
+ build_contact('Registrant', Record::Contact::TYPE_REGISTRANT)
67
67
  end
68
68
 
69
69
  property_supported :admin_contacts do
70
- build_contact('Administrative Contact:', Record::Contact::TYPE_ADMINISTRATIVE)
70
+ build_contact('Admin', Record::Contact::TYPE_ADMINISTRATIVE)
71
71
  end
72
72
 
73
73
  property_supported :technical_contacts do
74
- build_contact('Technical Contact:', Record::Contact::TYPE_TECHNICAL)
74
+ build_contact('Tech', Record::Contact::TYPE_TECHNICAL)
75
75
  end
76
76
 
77
-
78
77
  property_supported :nameservers do
79
- if content_for_scanner =~ /Domain servers in listed order:\n((.+\n)+)\n/
80
- $1.split("\n").map do |line|
81
- Record::Nameserver.new(:name => line.strip)
82
- end
78
+ content_for_scanner.scan(/Name Server: (.+)\n/).map do |line|
79
+ Record::Nameserver.new(:name => line[0].strip)
83
80
  end
84
81
  end
85
82
 
86
-
87
83
  private
88
84
 
89
85
  def build_contact(element, type)
90
- match = content_for_scanner.slice(/#{element}\n((.+\n)+)\n/, 1)
91
- return unless match
92
-
93
- # Lines 1 and 5 may be absent, depending on the record.
94
- # The parser attempts to correct for this, but may be a bit flaky
95
- # on non-standard data.
96
- #
97
- # 0 GoDaddy.com, Inc., GoDaddy.com, Inc. dns@jomax.net
98
- # 1 GoDaddy.com, Inc.
99
- # 2 14455 N Hayden Rd Suite 219
100
- # 3 Scottsdale, Arizona 85260
101
- # 4 United States
102
- # 5 +1.4805058800 Fax -- +1.4805058844
103
-
104
- lines = $1.split("\n").map(&:strip)
105
-
106
- phone = nil
107
- fax = nil
108
- if lines[-1].to_s =~ /Fax --/
109
- phone, fax = lines.delete_at(-1).to_s.scan(/^(.*) Fax --(.*)$/).first
110
- phone = phone.strip
111
- fax = fax.strip
112
- end
113
-
114
86
  Record::Contact.new(
115
87
  :type => type,
116
88
  :id => nil,
117
- :name => lines[0].to_s.gsub(/\s\S+@[^\.].*\.[a-z]{2,}\s?\)?$/, "").strip,
118
- :organization => lines.length >= 5 ? lines[-4] : "",
119
- :address => lines.length >= 4 ? lines[-3] : "",
120
- :city => lines.length >= 4 ? lines[-2].to_s.partition(",")[0] : "",
121
- :zip => lines.length >= 4 ? lines[-2].to_s.rpartition(" ")[2] : "",
122
- :state => lines.length >= 4 ? lines[-2].to_s.partition(",")[2].rpartition(" ")[0].to_s.strip : "",
123
- :country => lines.length >= 4 ? lines[-1] : "",
124
- :phone => phone,
125
- :fax => fax,
126
- :email => lines[0].to_s.scan(/[^\s]\S+@[^\.].*\.[a-z]{2,}[^\s\)\n]/).first
89
+ :name => value_for_property(element, 'Name'),
90
+ :organization => value_for_property(element, 'Organization'),
91
+ :address => value_for_property(element, 'Street'),
92
+ :city => value_for_property(element, 'City'),
93
+ :zip => value_for_property(element, 'Postal Code'),
94
+ :state => value_for_property(element, 'State/Province'),
95
+ :country => value_for_property(element, 'Country'),
96
+ :phone => value_for_property(element, 'Phone'),
97
+ :fax => value_for_property(element, 'Fax'),
98
+ :email => value_for_property(element, 'Email')
127
99
  )
128
100
  end
129
101
 
102
+ def value_for_property(element, property)
103
+ matches = content_for_scanner.scan(/#{element} #{property}:\s(.+)\n/)
104
+ value = matches.collect(&:first).join(', ')
105
+ if value == ""
106
+ nil
107
+ else
108
+ value
109
+ end
110
+ end
111
+
130
112
  end
131
113
 
132
114
  end
@@ -41,7 +41,7 @@ module Whois
41
41
  end
42
42
  elsif content_for_scanner =~ /\[State\]\s+(.+)\n/
43
43
  case $1.split(" ").first.downcase
44
- when "connected"
44
+ when "connected", "registered"
45
45
  :registered
46
46
  when "deleted"
47
47
  :suspended
@@ -8,44 +8,39 @@
8
8
 
9
9
 
10
10
  require 'whois/record/parser/base'
11
-
11
+ require 'whois/record/scanners/whois.nic-se.se.rb'
12
12
 
13
13
  module Whois
14
14
  class Record
15
15
  class Parser
16
16
 
17
- #
18
- # = whois.nic-se.se
19
- #
20
17
  # Parser for the whois.nic-se.se server.
21
18
  #
22
- # NOTE: This parser is just a stub and provides only a few basic methods
23
- # to check for domain availability and get domain status.
24
- # Please consider to contribute implementing missing methods.
25
- # See WhoisNicIt parser for an explanation of all available methods
26
- # and examples.
27
- #
28
19
  # @author Simone Carletti <weppos@weppos.net>
29
20
  # @author Mikkel Kristensen <mikkel@tdx.dk>
21
+ # @author Pieter Agten <pieter.agten@gmail.com>
30
22
  #
31
23
  class WhoisNicSeSe < Base
24
+ include Scanners::Scannable
25
+
26
+ self.scanner = Scanners::WhoisNicSeSe
27
+
28
+
29
+ property_supported :disclaimer do
30
+ node("field:disclaimer")
31
+ end
32
+
32
33
 
33
34
  property_supported :status do
34
- # Two keys available: state and status.
35
- if content_for_scanner =~ /status:\s+(.+?)\n/
36
- case $1.downcase
37
- when "ok" then :registered
38
- when "inactive" then :inactive
39
- else
40
- Whois.bug!(ParserError, "Unknown status `#{$1}'.")
41
- end
42
- else
35
+ if available?
43
36
  :available
37
+ else
38
+ :registered
44
39
  end
45
40
  end
46
41
 
47
42
  property_supported :available? do
48
- !!(content_for_scanner =~ /" not found./)
43
+ !!node("status:available")
49
44
  end
50
45
 
51
46
  property_supported :registered? do
@@ -54,21 +49,33 @@ module Whois
54
49
 
55
50
 
56
51
  property_supported :created_on do
57
- if content_for_scanner =~ /created:\s+(.+)\n/
58
- Time.parse($1)
59
- end
52
+ node("created") { |value| Time.parse(value) }
60
53
  end
61
54
 
62
55
  property_supported :expires_on do
63
- if content_for_scanner =~ /expires:\s+(.+)\n/
64
- Time.parse($1)
65
- end
56
+ node("expires") { |value| Time.parse(value) }
66
57
  end
67
58
 
68
59
  property_supported :updated_on do
69
- if content_for_scanner =~ /modified:\s+(.+)\n/
70
- Time.parse($1) unless $1 == '-'
71
- end
60
+ node("modified") { |value| Time.parse(value) unless value == '-' }
61
+ end
62
+
63
+
64
+ property_supported :registrar do
65
+ node("registrar") { |name| Record::Registrar.new(:name => name) unless name == '-' }
66
+ end
67
+
68
+
69
+ property_supported :registrant_contacts do
70
+ build_contact(Whois::Record::Contact::TYPE_REGISTRANT, node("holder"))
71
+ end
72
+
73
+ property_supported :admin_contacts do
74
+ build_contact(Whois::Record::Contact::TYPE_ADMINISTRATIVE, node("admin-c"))
75
+ end
76
+
77
+ property_supported :technical_contacts do
78
+ build_contact(Whois::Record::Contact::TYPE_TECHNICAL, node("tech-c"))
72
79
  end
73
80
 
74
81
 
@@ -78,12 +85,26 @@ module Whois
78
85
  # nserver: ns2.loopia.se 93.188.0.21
79
86
  #
80
87
  property_supported :nameservers do
81
- content_for_scanner.scan(/nserver:\s+(.+)\n/).flatten.map do |line|
82
- name, ipv4 = line.split(/\s+/)
83
- Record::Nameserver.new(:name => name, :ipv4 => ipv4)
88
+ node("nserver") do |values|
89
+ values.map do |line|
90
+ name, ipv4 = line.split(/\s+/)
91
+ Record::Nameserver.new(:name => name, :ipv4 => ipv4)
92
+ end
84
93
  end
85
94
  end
86
95
 
96
+
97
+ private
98
+
99
+ def build_contact(type, id)
100
+ return if id.nil? || id == "-"
101
+
102
+ Record::Contact.new(
103
+ type: type,
104
+ id: id
105
+ )
106
+ end
107
+
87
108
  end
88
109
 
89
110
  end
@@ -9,7 +9,6 @@
9
9
 
10
10
  require 'whois/record/parser/base'
11
11
 
12
-
13
12
  module Whois
14
13
  class Record
15
14
  class Parser
@@ -50,6 +49,36 @@ module Whois
50
49
 
51
50
  property_not_supported :expires_on
52
51
 
52
+ # Registrant is given in the following format:
53
+ #
54
+ # Holder of domain name:
55
+ # Name
56
+ # Address line 1
57
+ # Address line 2
58
+ # Address line n
59
+ # Contractual Language: language
60
+ #
61
+ property_supported :registrant_contacts do
62
+ if content_for_scanner =~ /Holder of domain name:\n(.+?)\n(.+?)\nContractual Language:.*\n\n/m
63
+ Record::Contact.new({ :name => $1, :address => $2, :type => Whois::Record::Contact::TYPE_REGISTRANT })
64
+ end
65
+ end
66
+
67
+ # Technical contact is given in the following format:
68
+ #
69
+ # Technical contact:
70
+ # Name
71
+ # Address line 1
72
+ # Address line 2
73
+ # Address line n
74
+ #
75
+ property_supported :technical_contacts do
76
+ if content_for_scanner =~ /Technical contact:\n(.+?)\n(.+?)\n\n/m
77
+ Record::Contact.new({ :name => $1, :address => $2, :type => Whois::Record::Contact::TYPE_TECHNICAL })
78
+ end
79
+ end
80
+
81
+ property_not_supported :admin_contacts
53
82
 
54
83
  # Nameservers are listed in the following formats:
55
84
  #
@@ -77,7 +106,6 @@ module Whois
77
106
  end
78
107
 
79
108
  end
80
-
81
109
  end
82
110
  end
83
111
  end
@@ -59,7 +59,7 @@ module Whois
59
59
 
60
60
  property_supported :updated_on do
61
61
  if content_for_scanner =~ /Record last updated on\.+:(.+)\n/
62
- Time.parse($1)
62
+ Time.parse($1) unless $1 == "null"
63
63
  end
64
64
  end
65
65
 
@@ -28,8 +28,10 @@ module Whois
28
28
  def status
29
29
  if content =~ /status:\s+(.+?)\n/
30
30
  case (s = $1.downcase)
31
- when "ok"
31
+ when "ok", "clienthold", "autorenewgraceperiod"
32
32
  :registered
33
+ when "redemptionperiod", "pendingdelete"
34
+ :redemption
33
35
  else
34
36
  Whois.bug!(ParserError, "Unknown status `#{s}'.")
35
37
  end
@@ -54,7 +54,7 @@ module Whois
54
54
  # Scan a key/value pair and stores the result in the current target.
55
55
  # target is the global @ast if no '_section' is set, else '_section' is used.
56
56
  tokenizer :scan_keyvalue do
57
- if @input.scan(/(.+?):(.*?)\n/)
57
+ if @input.scan(/(.+?):(.*?)(\n|\z)/)
58
58
  key, value = @input[1].strip, @input[2].strip
59
59
  target = @tmp['_section'] ? (@ast[@tmp['_section']] ||= {}) : @ast
60
60
 
@@ -0,0 +1,46 @@
1
+ #--
2
+ # Ruby Whois
3
+ #
4
+ # An intelligent pure Ruby WHOIS client and parser.
5
+ #
6
+ # Copyright (c) 2009-2013 Simone Carletti <weppos@weppos.net>
7
+ #++
8
+
9
+
10
+ require 'whois/record/scanners/base'
11
+
12
+
13
+ module Whois
14
+ class Record
15
+ module Scanners
16
+
17
+ class WhoisNicSeSe < Base
18
+
19
+ self.tokenizers += [
20
+ :skip_empty_line,
21
+ :scan_available,
22
+ :scan_disclaimer,
23
+ :scan_keyvalue,
24
+ ]
25
+
26
+
27
+ tokenizer :scan_available do
28
+ @ast["status:available"] = true if @input.skip(/".*" not found\.\n/)
29
+ end
30
+
31
+ tokenizer :scan_disclaimer do
32
+ if @input.match?(/# Copyright \(c\) [\d-]* \.SE \(The Internet Infrastructure Foundation\)\.\n# All rights reserved\.\n\n/)
33
+ lines = []
34
+ while !@input.match?(/# Result of search for registered domain names under\n/) && @input.scan(/#?(.*)\n/)
35
+ lines << @input[1].strip unless @input[1].strip == ""
36
+ end
37
+ @input.skip_until(/# printed with .+ bits\.\n/m)
38
+ @ast["field:disclaimer"] = lines.join(" ")
39
+ end
40
+ end
41
+
42
+ end
43
+
44
+ end
45
+ end
46
+ end
data/lib/whois/server.rb CHANGED
@@ -235,7 +235,12 @@ module Whois
235
235
  return server
236
236
  end
237
237
 
238
- # Gave Over
238
+ # ASN match
239
+ if matches_asn?(string)
240
+ return find_for_asn(string)
241
+ end
242
+
243
+ # Game Over
239
244
  raise ServerNotFound, "Unable to find a WHOIS server for `#{string}'"
240
245
  end
241
246
 
@@ -259,6 +264,9 @@ module Whois
259
264
  string =~ /@/
260
265
  end
261
266
 
267
+ def self.matches_asn?(string)
268
+ string =~ /^as\d+$/i
269
+ end
262
270
 
263
271
  def self.find_for_ip(string)
264
272
  begin
@@ -286,6 +294,17 @@ module Whois
286
294
  nil
287
295
  end
288
296
 
297
+ def self.find_for_asn(string)
298
+ asn = string[/\d+/].to_i
299
+ asn_type = asn <= 65535 ? :asn16 : :asn32
300
+ definitions(asn_type).each do |definition|
301
+ if (range = definition.first.split.map(&:to_i)) && asn >= range.first && asn <= range.last
302
+ return factory(asn_type, *definition)
303
+ end
304
+ end
305
+ raise AllocationUnknown, "Unknown AS number - `#{asn}'."
306
+ end
307
+
289
308
 
290
309
  def self.valid_ipv4?(addr)
291
310
  if /\A(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})\Z/ =~ addr
data/lib/whois/version.rb CHANGED
@@ -12,8 +12,8 @@ module Whois
12
12
  # Holds information about library version.
13
13
  module Version
14
14
  MAJOR = 3
15
- MINOR = 2
16
- PATCH = 1
15
+ MINOR = 3
16
+ PATCH = 0
17
17
  BUILD = nil
18
18
 
19
19
  STRING = [MAJOR, MINOR, PATCH, BUILD].compact.join(".")
data/lib/whois.rb CHANGED
@@ -31,18 +31,22 @@ module Whois
31
31
  # @return [Whois::Record] The record containing the response from the WHOIS server.
32
32
  #
33
33
  # @example
34
- # Whois.query("google.com")
34
+ # Whois.lookup("google.com")
35
35
  # # => #<Whois::Record>
36
36
  #
37
37
  # # Equivalent to
38
38
  # Whois::Client.new.lookup("google.com")
39
39
  #
40
- def query(object)
40
+ def lookup(object)
41
41
  Client.new.lookup(object)
42
42
  end
43
43
 
44
- alias_method :whois, :query
44
+ alias_method :whois, :lookup
45
45
 
46
+ def query(object)
47
+ deprecate("Whois.query is now Whois.lookup")
48
+ lookup(object)
49
+ end
46
50
 
47
51
  # Checks whether the object represented by <tt>object</tt> is available.
48
52
  #
@@ -67,10 +71,10 @@ module Whois
67
71
  # # => true
68
72
  #
69
73
  def available?(object)
70
- result = query(object).available?
74
+ result = lookup(object).available?
71
75
  if result.nil?
72
76
  warn "This method is not supported for this kind of object.\n" +
73
- "Use Whois.query('#{object}') instead."
77
+ "Use Whois.lookup('#{object}') instead."
74
78
  end
75
79
  result
76
80
  end
@@ -98,10 +102,10 @@ module Whois
98
102
  # # => false
99
103
  #
100
104
  def registered?(object)
101
- result = query(object).registered?
105
+ result = lookup(object).registered?
102
106
  if result.nil?
103
107
  warn "This method is not supported for this kind of object.\n" +
104
- "Use Whois.query('#{object}') instead."
108
+ "Use Whois.lookup('#{object}') instead."
105
109
  end
106
110
  result
107
111
  end
data/whois.gemspec CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |s|
10
10
  s.description = "Whois is an intelligent WHOIS client and parser written in pure Ruby. It can query registry data for IPv4, IPv6 and top level domains, parse and convert responses into easy-to-use Ruby objects."
11
11
  s.email = ["weppos@weppos.net"]
12
12
  s.executables = ["ruby-whois"]
13
- s.files = ["LICENSE.txt", ".yardopts", "CHANGELOG.md", "README.md", "whois.gemspec", "bin/ruby-whois", "data/ipv4.json", "data/ipv6.json", "data/tld.json", "lib/whois", "lib/whois/client.rb", "lib/whois/core_ext", "lib/whois/core_ext/array", "lib/whois/core_ext/array/extract_options.rb", "lib/whois/core_ext/array/wrap.rb", "lib/whois/core_ext/class", "lib/whois/core_ext/class/attribute.rb", "lib/whois/core_ext/kernel", "lib/whois/core_ext/kernel/singleton_class.rb", "lib/whois/core_ext/module", "lib/whois/core_ext/module/remove_method.rb", "lib/whois/core_ext/object", "lib/whois/core_ext/object/blank.rb", "lib/whois/core_ext.rb", "lib/whois/errors.rb", "lib/whois/record", "lib/whois/record/contact.rb", "lib/whois/record/nameserver.rb", "lib/whois/record/parser", "lib/whois/record/parser/base.rb", "lib/whois/record/parser/base_afilias.rb", "lib/whois/record/parser/base_cocca.rb", "lib/whois/record/parser/base_cocca2.rb", "lib/whois/record/parser/base_icb.rb", "lib/whois/record/parser/base_shared1.rb", "lib/whois/record/parser/base_shared2.rb", "lib/whois/record/parser/base_shared3.rb", "lib/whois/record/parser/base_whoisd.rb", "lib/whois/record/parser/blank.rb", "lib/whois/record/parser/example.rb", "lib/whois/record/parser/jobswhois.verisign-grs.com.rb", "lib/whois/record/parser/kero.yachay.pe.rb", "lib/whois/record/parser/NOTES.txt", "lib/whois/record/parser/whois.adamsnames.tc.rb", "lib/whois/record/parser/whois.aeda.net.ae.rb", "lib/whois/record/parser/whois.aero.rb", "lib/whois/record/parser/whois.afilias-grs.info.rb", "lib/whois/record/parser/whois.afilias.info.rb", "lib/whois/record/parser/whois.ai.rb", "lib/whois/record/parser/whois.arnes.si.rb", "lib/whois/record/parser/whois.ati.tn.rb", "lib/whois/record/parser/whois.audns.net.au.rb", "lib/whois/record/parser/whois.ax.rb", "lib/whois/record/parser/whois.biz.rb", "lib/whois/record/parser/whois.bn.rb", "lib/whois/record/parser/whois.cat.rb", "lib/whois/record/parser/whois.cctld.by.rb", "lib/whois/record/parser/whois.cctld.uz.rb", "lib/whois/record/parser/whois.centralnic.com.rb", "lib/whois/record/parser/whois.cira.ca.rb", "lib/whois/record/parser/whois.cmc.iq.rb", "lib/whois/record/parser/whois.cnnic.cn.rb", "lib/whois/record/parser/whois.co.ca.rb", "lib/whois/record/parser/whois.co.pl.rb", "lib/whois/record/parser/whois.co.ug.rb", "lib/whois/record/parser/whois.comlaude.com.rb", "lib/whois/record/parser/whois.crsnic.net.rb", "lib/whois/record/parser/whois.denic.de.rb", "lib/whois/record/parser/whois.dk-hostmaster.dk.rb", "lib/whois/record/parser/whois.dns.be.rb", "lib/whois/record/parser/whois.dns.hr.rb", "lib/whois/record/parser/whois.dns.lu.rb", "lib/whois/record/parser/whois.dns.pl.rb", "lib/whois/record/parser/whois.dns.pt.rb", "lib/whois/record/parser/whois.domain-registry.nl.rb", "lib/whois/record/parser/whois.domain.kg.rb", "lib/whois/record/parser/whois.domainregistry.ie.rb", "lib/whois/record/parser/whois.domainregistry.my.rb", "lib/whois/record/parser/whois.domreg.lt.rb", "lib/whois/record/parser/whois.dot.tk.rb", "lib/whois/record/parser/whois.dotmobiregistry.net.rb", "lib/whois/record/parser/whois.dotpostregistry.net.rb", "lib/whois/record/parser/whois.dreamhost.com.rb", "lib/whois/record/parser/whois.educause.edu.rb", "lib/whois/record/parser/whois.eenet.ee.rb", "lib/whois/record/parser/whois.enom.com.rb", "lib/whois/record/parser/whois.eu.org.rb", "lib/whois/record/parser/whois.eu.rb", "lib/whois/record/parser/whois.fi.rb", "lib/whois/record/parser/whois.gg.rb", "lib/whois/record/parser/whois.godaddy.com.rb", "lib/whois/record/parser/whois.gov.za.rb", "lib/whois/record/parser/whois.hkirc.hk.rb", "lib/whois/record/parser/whois.iam.net.ma.rb", "lib/whois/record/parser/whois.iana.org.rb", "lib/whois/record/parser/whois.in.ua.rb", "lib/whois/record/parser/whois.isnic.is.rb", "lib/whois/record/parser/whois.isoc.org.il.rb", "lib/whois/record/parser/whois.ja.net.rb", "lib/whois/record/parser/whois.je.rb", "lib/whois/record/parser/whois.jprs.jp.rb", "lib/whois/record/parser/whois.kenic.or.ke.rb", "lib/whois/record/parser/whois.kr.rb", "lib/whois/record/parser/whois.markmonitor.com.rb", "lib/whois/record/parser/whois.meregistry.net.rb", "lib/whois/record/parser/whois.meridiantld.net.rb", "lib/whois/record/parser/whois.monic.mo.rb", "lib/whois/record/parser/whois.museum.rb", "lib/whois/record/parser/whois.na-nic.com.na.rb", "lib/whois/record/parser/whois.nc.rb", "lib/whois/record/parser/whois.netcom.cm.rb", "lib/whois/record/parser/whois.networksolutions.com.rb", "lib/whois/record/parser/whois.nic-se.se.rb", "lib/whois/record/parser/whois.nic.ac.rb", "lib/whois/record/parser/whois.nic.af.rb", "lib/whois/record/parser/whois.nic.ag.rb", "lib/whois/record/parser/whois.nic.am.rb", "lib/whois/record/parser/whois.nic.as.rb", "lib/whois/record/parser/whois.nic.asia.rb", "lib/whois/record/parser/whois.nic.at.rb", "lib/whois/record/parser/whois.nic.bo.rb", "lib/whois/record/parser/whois.nic.cc.rb", "lib/whois/record/parser/whois.nic.cd.rb", "lib/whois/record/parser/whois.nic.ch.rb", "lib/whois/record/parser/whois.nic.ci.rb", "lib/whois/record/parser/whois.nic.ck.rb", "lib/whois/record/parser/whois.nic.cl.rb", "lib/whois/record/parser/whois.nic.co.rb", "lib/whois/record/parser/whois.nic.coop.rb", "lib/whois/record/parser/whois.nic.cx.rb", "lib/whois/record/parser/whois.nic.cz.rb", "lib/whois/record/parser/whois.nic.dm.rb", "lib/whois/record/parser/whois.nic.dz.rb", "lib/whois/record/parser/whois.nic.ec.rb", "lib/whois/record/parser/whois.nic.fo.rb", "lib/whois/record/parser/whois.nic.fr.rb", "lib/whois/record/parser/whois.nic.gd.rb", "lib/whois/record/parser/whois.nic.gl.rb", "lib/whois/record/parser/whois.nic.gov.rb", "lib/whois/record/parser/whois.nic.gs.rb", "lib/whois/record/parser/whois.nic.hn.rb", "lib/whois/record/parser/whois.nic.ht.rb", "lib/whois/record/parser/whois.nic.hu.rb", "lib/whois/record/parser/whois.nic.im.rb", "lib/whois/record/parser/whois.nic.io.rb", "lib/whois/record/parser/whois.nic.ir.rb", "lib/whois/record/parser/whois.nic.it.rb", "lib/whois/record/parser/whois.nic.ki.rb", "lib/whois/record/parser/whois.nic.kz.rb", "lib/whois/record/parser/whois.nic.la.rb", "lib/whois/record/parser/whois.nic.li.rb", "lib/whois/record/parser/whois.nic.lk.rb", "lib/whois/record/parser/whois.nic.lv.rb", "lib/whois/record/parser/whois.nic.ly.rb", "lib/whois/record/parser/whois.nic.md.rb", "lib/whois/record/parser/whois.nic.mg.rb", "lib/whois/record/parser/whois.nic.ms.rb", "lib/whois/record/parser/whois.nic.mu.rb", "lib/whois/record/parser/whois.nic.mx.rb", "lib/whois/record/parser/whois.nic.name.rb", "lib/whois/record/parser/whois.nic.net.nf.rb", "lib/whois/record/parser/whois.nic.net.ng.rb", "lib/whois/record/parser/whois.nic.net.sa.rb", "lib/whois/record/parser/whois.nic.net.sb.rb", "lib/whois/record/parser/whois.nic.nu.rb", "lib/whois/record/parser/whois.nic.org.uy.rb", "lib/whois/record/parser/whois.nic.pr.rb", "lib/whois/record/parser/whois.nic.priv.at.rb", "lib/whois/record/parser/whois.nic.pw.rb", "lib/whois/record/parser/whois.nic.sh.rb", "lib/whois/record/parser/whois.nic.sl.rb", "lib/whois/record/parser/whois.nic.sm.rb", "lib/whois/record/parser/whois.nic.sn.rb", "lib/whois/record/parser/whois.nic.so.rb", "lib/whois/record/parser/whois.nic.st.rb", "lib/whois/record/parser/whois.nic.tel.rb", "lib/whois/record/parser/whois.nic.tl.rb", "lib/whois/record/parser/whois.nic.tm.rb", "lib/whois/record/parser/whois.nic.tr.rb", "lib/whois/record/parser/whois.nic.travel.rb", "lib/whois/record/parser/whois.nic.tv.rb", "lib/whois/record/parser/whois.nic.uk.rb", "lib/whois/record/parser/whois.nic.us.rb", "lib/whois/record/parser/whois.nic.ve.rb", "lib/whois/record/parser/whois.nic.xxx.rb", "lib/whois/record/parser/whois.norid.no.rb", "lib/whois/record/parser/whois.org.za.rb", "lib/whois/record/parser/whois.pandi.or.id.rb", "lib/whois/record/parser/whois.pir.org.rb", "lib/whois/record/parser/whois.pnina.ps.rb", "lib/whois/record/parser/whois.register.bg.rb", "lib/whois/record/parser/whois.register.com.rb", "lib/whois/record/parser/whois.registro.br.rb", "lib/whois/record/parser/whois.registry.gy.rb", "lib/whois/record/parser/whois.registry.hm.rb", "lib/whois/record/parser/whois.registry.in.rb", "lib/whois/record/parser/whois.registry.net.za.rb", "lib/whois/record/parser/whois.registry.om.rb", "lib/whois/record/parser/whois.registry.qa.rb", "lib/whois/record/parser/whois.registrypro.pro.rb", "lib/whois/record/parser/whois.ripe.net.rb", "lib/whois/record/parser/whois.rnids.rs.rb", "lib/whois/record/parser/whois.rotld.ro.rb", "lib/whois/record/parser/whois.samoanic.ws.rb", "lib/whois/record/parser/whois.sgnic.sg.rb", "lib/whois/record/parser/whois.sk-nic.sk.rb", "lib/whois/record/parser/whois.smallregistry.net.rb", "lib/whois/record/parser/whois.srs.net.nz.rb", "lib/whois/record/parser/whois.sx.rb", "lib/whois/record/parser/whois.tcinet.ru.rb", "lib/whois/record/parser/whois.thnic.co.th.rb", "lib/whois/record/parser/whois.tld.ee.rb", "lib/whois/record/parser/whois.tld.sy.rb", "lib/whois/record/parser/whois.tonic.to.rb", "lib/whois/record/parser/whois.twnic.net.tw.rb", "lib/whois/record/parser/whois.tznic.or.tz.rb", "lib/whois/record/parser/whois.ua.rb", "lib/whois/record/parser/whois.usp.ac.fj.rb", "lib/whois/record/parser/whois.za.net.rb", "lib/whois/record/parser/whois.za.org.rb", "lib/whois/record/parser/whois1.nic.bi.rb", "lib/whois/record/parser.rb", "lib/whois/record/part.rb", "lib/whois/record/registrar.rb", "lib/whois/record/scanners", "lib/whois/record/scanners/base.rb", "lib/whois/record/scanners/base_afilias.rb", "lib/whois/record/scanners/base_cocca2.rb", "lib/whois/record/scanners/base_shared1.rb", "lib/whois/record/scanners/base_shared2.rb", "lib/whois/record/scanners/base_shared3.rb", "lib/whois/record/scanners/base_whoisd.rb", "lib/whois/record/scanners/iana.rb", "lib/whois/record/scanners/scannable.rb", "lib/whois/record/scanners/verisign.rb", "lib/whois/record/scanners/whois.ati.tn.rb", "lib/whois/record/scanners/whois.audns.net.au.rb", "lib/whois/record/scanners/whois.cctld.by.rb", "lib/whois/record/scanners/whois.centralnic.com.rb", "lib/whois/record/scanners/whois.cira.ca.rb", "lib/whois/record/scanners/whois.cnnic.cn.rb", "lib/whois/record/scanners/whois.denic.de.rb", "lib/whois/record/scanners/whois.dns.hr.rb", "lib/whois/record/scanners/whois.domainregistry.ie.rb", "lib/whois/record/scanners/whois.fi.rb", "lib/whois/record/scanners/whois.nc.rb", "lib/whois/record/scanners/whois.nic.hu.rb", "lib/whois/record/scanners/whois.nic.it.rb", "lib/whois/record/scanners/whois.registry.net.za.rb", "lib/whois/record/scanners/whois.rnids.rs.rb", "lib/whois/record/scanners/whois.smallregistry.net.rb", "lib/whois/record/scanners/whois.srs.net.nz.rb", "lib/whois/record/scanners/whois.sx.rb", "lib/whois/record/super_struct.rb", "lib/whois/record.rb", "lib/whois/server", "lib/whois/server/adapters", "lib/whois/server/adapters/afilias.rb", "lib/whois/server/adapters/arin.rb", "lib/whois/server/adapters/arpa.rb", "lib/whois/server/adapters/base.rb", "lib/whois/server/adapters/formatted.rb", "lib/whois/server/adapters/none.rb", "lib/whois/server/adapters/not_implemented.rb", "lib/whois/server/adapters/standard.rb", "lib/whois/server/adapters/verisign.rb", "lib/whois/server/adapters/web.rb", "lib/whois/server/socket_handler.rb", "lib/whois/server.rb", "lib/whois/version.rb", "lib/whois.rb"]
13
+ s.files = ["LICENSE.txt", ".yardopts", "CHANGELOG.md", "README.md", "whois.gemspec", "bin/ruby-whois", "data/ipv4.json", "data/ipv6.json", "data/tld.json", "lib/whois/client.rb", "lib/whois/core_ext/array/extract_options.rb", "lib/whois/core_ext/array/wrap.rb", "lib/whois/core_ext/class/attribute.rb", "lib/whois/core_ext/kernel/singleton_class.rb", "lib/whois/core_ext/module/remove_method.rb", "lib/whois/core_ext/object/blank.rb", "lib/whois/core_ext.rb", "lib/whois/errors.rb", "lib/whois/record/contact.rb", "lib/whois/record/nameserver.rb", "lib/whois/record/parser/base.rb", "lib/whois/record/parser/base_afilias.rb", "lib/whois/record/parser/base_cocca.rb", "lib/whois/record/parser/base_cocca2.rb", "lib/whois/record/parser/base_icb.rb", "lib/whois/record/parser/base_shared1.rb", "lib/whois/record/parser/base_shared2.rb", "lib/whois/record/parser/base_shared3.rb", "lib/whois/record/parser/base_whoisd.rb", "lib/whois/record/parser/blank.rb", "lib/whois/record/parser/example.rb", "lib/whois/record/parser/jobswhois.verisign-grs.com.rb", "lib/whois/record/parser/kero.yachay.pe.rb", "lib/whois/record/parser/NOTES.txt", "lib/whois/record/parser/whois.adamsnames.tc.rb", "lib/whois/record/parser/whois.aeda.net.ae.rb", "lib/whois/record/parser/whois.aero.rb", "lib/whois/record/parser/whois.afilias-grs.info.rb", "lib/whois/record/parser/whois.afilias.info.rb", "lib/whois/record/parser/whois.ai.rb", "lib/whois/record/parser/whois.arnes.si.rb", "lib/whois/record/parser/whois.ati.tn.rb", "lib/whois/record/parser/whois.audns.net.au.rb", "lib/whois/record/parser/whois.ax.rb", "lib/whois/record/parser/whois.biz.rb", "lib/whois/record/parser/whois.bn.rb", "lib/whois/record/parser/whois.cat.rb", "lib/whois/record/parser/whois.cctld.by.rb", "lib/whois/record/parser/whois.cctld.uz.rb", "lib/whois/record/parser/whois.centralnic.com.rb", "lib/whois/record/parser/whois.cira.ca.rb", "lib/whois/record/parser/whois.cmc.iq.rb", "lib/whois/record/parser/whois.cnnic.cn.rb", "lib/whois/record/parser/whois.co.ca.rb", "lib/whois/record/parser/whois.co.pl.rb", "lib/whois/record/parser/whois.co.ug.rb", "lib/whois/record/parser/whois.comlaude.com.rb", "lib/whois/record/parser/whois.crsnic.net.rb", "lib/whois/record/parser/whois.denic.de.rb", "lib/whois/record/parser/whois.dk-hostmaster.dk.rb", "lib/whois/record/parser/whois.dns.be.rb", "lib/whois/record/parser/whois.dns.hr.rb", "lib/whois/record/parser/whois.dns.lu.rb", "lib/whois/record/parser/whois.dns.pl.rb", "lib/whois/record/parser/whois.dns.pt.rb", "lib/whois/record/parser/whois.domain-registry.nl.rb", "lib/whois/record/parser/whois.domain.kg.rb", "lib/whois/record/parser/whois.domainregistry.ie.rb", "lib/whois/record/parser/whois.domainregistry.my.rb", "lib/whois/record/parser/whois.domreg.lt.rb", "lib/whois/record/parser/whois.dot.tk.rb", "lib/whois/record/parser/whois.dotmobiregistry.net.rb", "lib/whois/record/parser/whois.dotpostregistry.net.rb", "lib/whois/record/parser/whois.dreamhost.com.rb", "lib/whois/record/parser/whois.educause.edu.rb", "lib/whois/record/parser/whois.eenet.ee.rb", "lib/whois/record/parser/whois.enom.com.rb", "lib/whois/record/parser/whois.eu.org.rb", "lib/whois/record/parser/whois.eu.rb", "lib/whois/record/parser/whois.fi.rb", "lib/whois/record/parser/whois.gg.rb", "lib/whois/record/parser/whois.godaddy.com.rb", "lib/whois/record/parser/whois.gov.za.rb", "lib/whois/record/parser/whois.hkirc.hk.rb", "lib/whois/record/parser/whois.iam.net.ma.rb", "lib/whois/record/parser/whois.iana.org.rb", "lib/whois/record/parser/whois.in.ua.rb", "lib/whois/record/parser/whois.isnic.is.rb", "lib/whois/record/parser/whois.isoc.org.il.rb", "lib/whois/record/parser/whois.ja.net.rb", "lib/whois/record/parser/whois.je.rb", "lib/whois/record/parser/whois.jprs.jp.rb", "lib/whois/record/parser/whois.kenic.or.ke.rb", "lib/whois/record/parser/whois.kr.rb", "lib/whois/record/parser/whois.markmonitor.com.rb", "lib/whois/record/parser/whois.meregistry.net.rb", "lib/whois/record/parser/whois.meridiantld.net.rb", "lib/whois/record/parser/whois.monic.mo.rb", "lib/whois/record/parser/whois.museum.rb", "lib/whois/record/parser/whois.na-nic.com.na.rb", "lib/whois/record/parser/whois.nc.rb", "lib/whois/record/parser/whois.netcom.cm.rb", "lib/whois/record/parser/whois.networksolutions.com.rb", "lib/whois/record/parser/whois.nic-se.se.rb", "lib/whois/record/parser/whois.nic.ac.rb", "lib/whois/record/parser/whois.nic.af.rb", "lib/whois/record/parser/whois.nic.ag.rb", "lib/whois/record/parser/whois.nic.am.rb", "lib/whois/record/parser/whois.nic.as.rb", "lib/whois/record/parser/whois.nic.asia.rb", "lib/whois/record/parser/whois.nic.at.rb", "lib/whois/record/parser/whois.nic.bo.rb", "lib/whois/record/parser/whois.nic.cc.rb", "lib/whois/record/parser/whois.nic.cd.rb", "lib/whois/record/parser/whois.nic.ch.rb", "lib/whois/record/parser/whois.nic.ci.rb", "lib/whois/record/parser/whois.nic.ck.rb", "lib/whois/record/parser/whois.nic.cl.rb", "lib/whois/record/parser/whois.nic.co.rb", "lib/whois/record/parser/whois.nic.coop.rb", "lib/whois/record/parser/whois.nic.cx.rb", "lib/whois/record/parser/whois.nic.cz.rb", "lib/whois/record/parser/whois.nic.dm.rb", "lib/whois/record/parser/whois.nic.dz.rb", "lib/whois/record/parser/whois.nic.ec.rb", "lib/whois/record/parser/whois.nic.fo.rb", "lib/whois/record/parser/whois.nic.fr.rb", "lib/whois/record/parser/whois.nic.gd.rb", "lib/whois/record/parser/whois.nic.gl.rb", "lib/whois/record/parser/whois.nic.gov.rb", "lib/whois/record/parser/whois.nic.gs.rb", "lib/whois/record/parser/whois.nic.hn.rb", "lib/whois/record/parser/whois.nic.ht.rb", "lib/whois/record/parser/whois.nic.hu.rb", "lib/whois/record/parser/whois.nic.im.rb", "lib/whois/record/parser/whois.nic.io.rb", "lib/whois/record/parser/whois.nic.ir.rb", "lib/whois/record/parser/whois.nic.it.rb", "lib/whois/record/parser/whois.nic.ki.rb", "lib/whois/record/parser/whois.nic.kz.rb", "lib/whois/record/parser/whois.nic.la.rb", "lib/whois/record/parser/whois.nic.li.rb", "lib/whois/record/parser/whois.nic.lk.rb", "lib/whois/record/parser/whois.nic.lv.rb", "lib/whois/record/parser/whois.nic.ly.rb", "lib/whois/record/parser/whois.nic.md.rb", "lib/whois/record/parser/whois.nic.mg.rb", "lib/whois/record/parser/whois.nic.ms.rb", "lib/whois/record/parser/whois.nic.mu.rb", "lib/whois/record/parser/whois.nic.mx.rb", "lib/whois/record/parser/whois.nic.name.rb", "lib/whois/record/parser/whois.nic.net.nf.rb", "lib/whois/record/parser/whois.nic.net.ng.rb", "lib/whois/record/parser/whois.nic.net.sa.rb", "lib/whois/record/parser/whois.nic.net.sb.rb", "lib/whois/record/parser/whois.nic.nu.rb", "lib/whois/record/parser/whois.nic.org.uy.rb", "lib/whois/record/parser/whois.nic.pr.rb", "lib/whois/record/parser/whois.nic.priv.at.rb", "lib/whois/record/parser/whois.nic.pw.rb", "lib/whois/record/parser/whois.nic.sh.rb", "lib/whois/record/parser/whois.nic.sl.rb", "lib/whois/record/parser/whois.nic.sm.rb", "lib/whois/record/parser/whois.nic.sn.rb", "lib/whois/record/parser/whois.nic.so.rb", "lib/whois/record/parser/whois.nic.st.rb", "lib/whois/record/parser/whois.nic.tel.rb", "lib/whois/record/parser/whois.nic.tl.rb", "lib/whois/record/parser/whois.nic.tm.rb", "lib/whois/record/parser/whois.nic.tr.rb", "lib/whois/record/parser/whois.nic.travel.rb", "lib/whois/record/parser/whois.nic.tv.rb", "lib/whois/record/parser/whois.nic.uk.rb", "lib/whois/record/parser/whois.nic.us.rb", "lib/whois/record/parser/whois.nic.ve.rb", "lib/whois/record/parser/whois.nic.xxx.rb", "lib/whois/record/parser/whois.norid.no.rb", "lib/whois/record/parser/whois.org.za.rb", "lib/whois/record/parser/whois.pandi.or.id.rb", "lib/whois/record/parser/whois.pir.org.rb", "lib/whois/record/parser/whois.pnina.ps.rb", "lib/whois/record/parser/whois.register.bg.rb", "lib/whois/record/parser/whois.register.com.rb", "lib/whois/record/parser/whois.registro.br.rb", "lib/whois/record/parser/whois.registry.gy.rb", "lib/whois/record/parser/whois.registry.hm.rb", "lib/whois/record/parser/whois.registry.in.rb", "lib/whois/record/parser/whois.registry.net.za.rb", "lib/whois/record/parser/whois.registry.om.rb", "lib/whois/record/parser/whois.registry.qa.rb", "lib/whois/record/parser/whois.registrypro.pro.rb", "lib/whois/record/parser/whois.ripe.net.rb", "lib/whois/record/parser/whois.rnids.rs.rb", "lib/whois/record/parser/whois.rotld.ro.rb", "lib/whois/record/parser/whois.samoanic.ws.rb", "lib/whois/record/parser/whois.sgnic.sg.rb", "lib/whois/record/parser/whois.sk-nic.sk.rb", "lib/whois/record/parser/whois.smallregistry.net.rb", "lib/whois/record/parser/whois.srs.net.nz.rb", "lib/whois/record/parser/whois.sx.rb", "lib/whois/record/parser/whois.tcinet.ru.rb", "lib/whois/record/parser/whois.thnic.co.th.rb", "lib/whois/record/parser/whois.tld.ee.rb", "lib/whois/record/parser/whois.tld.sy.rb", "lib/whois/record/parser/whois.tonic.to.rb", "lib/whois/record/parser/whois.twnic.net.tw.rb", "lib/whois/record/parser/whois.tznic.or.tz.rb", "lib/whois/record/parser/whois.ua.rb", "lib/whois/record/parser/whois.usp.ac.fj.rb", "lib/whois/record/parser/whois.za.net.rb", "lib/whois/record/parser/whois.za.org.rb", "lib/whois/record/parser/whois1.nic.bi.rb", "lib/whois/record/parser.rb", "lib/whois/record/part.rb", "lib/whois/record/registrar.rb", "lib/whois/record/scanners/base.rb", "lib/whois/record/scanners/base_afilias.rb", "lib/whois/record/scanners/base_cocca2.rb", "lib/whois/record/scanners/base_shared1.rb", "lib/whois/record/scanners/base_shared2.rb", "lib/whois/record/scanners/base_shared3.rb", "lib/whois/record/scanners/base_whoisd.rb", "lib/whois/record/scanners/iana.rb", "lib/whois/record/scanners/scannable.rb", "lib/whois/record/scanners/verisign.rb", "lib/whois/record/scanners/whois.ati.tn.rb", "lib/whois/record/scanners/whois.audns.net.au.rb", "lib/whois/record/scanners/whois.cctld.by.rb", "lib/whois/record/scanners/whois.centralnic.com.rb", "lib/whois/record/scanners/whois.cira.ca.rb", "lib/whois/record/scanners/whois.cnnic.cn.rb", "lib/whois/record/scanners/whois.denic.de.rb", "lib/whois/record/scanners/whois.dns.hr.rb", "lib/whois/record/scanners/whois.domainregistry.ie.rb", "lib/whois/record/scanners/whois.fi.rb", "lib/whois/record/scanners/whois.nc.rb", "lib/whois/record/scanners/whois.nic.hu.rb", "lib/whois/record/scanners/whois.nic.it.rb", "lib/whois/record/scanners/whois.registry.net.za.rb", "lib/whois/record/scanners/whois.rnids.rs.rb", "lib/whois/record/scanners/whois.smallregistry.net.rb", "lib/whois/record/scanners/whois.srs.net.nz.rb", "lib/whois/record/scanners/whois.sx.rb", "lib/whois/record/super_struct.rb", "lib/whois/record.rb", "lib/whois/server/adapters/afilias.rb", "lib/whois/server/adapters/arin.rb", "lib/whois/server/adapters/arpa.rb", "lib/whois/server/adapters/base.rb", "lib/whois/server/adapters/formatted.rb", "lib/whois/server/adapters/none.rb", "lib/whois/server/adapters/not_implemented.rb", "lib/whois/server/adapters/standard.rb", "lib/whois/server/adapters/verisign.rb", "lib/whois/server/adapters/web.rb", "lib/whois/server/socket_handler.rb", "lib/whois/server.rb", "lib/whois/version.rb", "lib/whois.rb"]
14
14
  s.homepage = "http://www.ruby-whois.org/"
15
15
  s.post_install_message = "********************************************************************************\n\n Thank you for installing the whois gem!\n\n If you like this gem, please support the project.\n http://pledgie.com/campaigns/11383\n\n Does your project or organization use this gem? Add it to the apps wiki.\n https://github.com/weppos/whois/wiki/apps\n\n Are you looking for a quick and convenient way to perform WHOIS queries?\n Check out RoboWhois WHOIS API.\n https://www.robowhois.com/\n\n********************************************************************************\n"
16
16
  s.require_paths = ["lib"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: whois
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.1
4
+ version: 3.3.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-07-16 00:00:00.000000000 Z
12
+ date: 2013-10-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake
@@ -91,6 +91,8 @@ files:
91
91
  - README.md
92
92
  - whois.gemspec
93
93
  - bin/ruby-whois
94
+ - data/asn16.json
95
+ - data/asn32.json
94
96
  - data/ipv4.json
95
97
  - data/ipv6.json
96
98
  - data/tld.json
@@ -155,6 +157,7 @@ files:
155
157
  - lib/whois/record/parser/whois.domainregistry.ie.rb
156
158
  - lib/whois/record/parser/whois.domainregistry.my.rb
157
159
  - lib/whois/record/parser/whois.domreg.lt.rb
160
+ - lib/whois/record/parser/whois.dot.cf.rb
158
161
  - lib/whois/record/parser/whois.dot.tk.rb
159
162
  - lib/whois/record/parser/whois.dotmobiregistry.net.rb
160
163
  - lib/whois/record/parser/whois.dotpostregistry.net.rb
@@ -321,6 +324,7 @@ files:
321
324
  - lib/whois/record/scanners/whois.domainregistry.ie.rb
322
325
  - lib/whois/record/scanners/whois.fi.rb
323
326
  - lib/whois/record/scanners/whois.nc.rb
327
+ - lib/whois/record/scanners/whois.nic-se.se.rb
324
328
  - lib/whois/record/scanners/whois.nic.hu.rb
325
329
  - lib/whois/record/scanners/whois.nic.it.rb
326
330
  - lib/whois/record/scanners/whois.registry.net.za.rb
@@ -345,7 +349,8 @@ files:
345
349
  - lib/whois/version.rb
346
350
  - lib/whois.rb
347
351
  homepage: http://www.ruby-whois.org/
348
- licenses: []
352
+ licenses:
353
+ - MIT
349
354
  post_install_message: ! "********************************************************************************\n\n
350
355
  \ Thank you for installing the whois gem!\n\n If you like this gem, please support
351
356
  the project.\n http://pledgie.com/campaigns/11383\n\n Does your project or organization