Permalink
Browse files

Update whois.nic.net.ng parser to the new response

  • Loading branch information...
1 parent 4a6218c commit 03d26f2b0091621dfb22d9050f652f3fb4e2972f @weppos weppos committed Oct 25, 2012
View
@@ -35,6 +35,8 @@
- CHANGED: Updated whois.na-nic.com.na parser to the new response format.
+- CHANGED: Updated whois.nic.net.ng parser to the new response format.
+
- FIXED: whois.domainregistry.ie should support status `Active - LOCKED`.
- FIXED: whois.nic.uk fails to parse registrars without URL (GH-188).
@@ -7,19 +7,15 @@
#++
-require 'whois/record/parser/base_cocca'
+require 'whois/record/parser/base_cocca2'
module Whois
class Record
class Parser
# Parser for the whois.nic.net.ng server.
- #
- # @see Whois::Record::Parser::Example
- # The Example parser for the list of all available methods.
- #
- class WhoisNicNetNg < BaseCocca
+ class WhoisNicNetNg < BaseCocca2
end
end
@@ -1,8 +0,0 @@
-#status
- should: %s == :registered
-
-#available?
- should: %s == false
-
-#registered?
- should: %s == true
@@ -1,41 +0,0 @@
-<br/>
-<b>TERMS OF USE:</b> You are not authorized to access or query our Whois database through the use of electronic processes that are high-volume and automated. Whois database is provided by NIRA as a service to the internet community. <br/><br/>The data is for information purposes only. NIRA does not guarantee its accuracy. By submitting a Whois query, you agree to abide by the following terms of use: You agree that you may use this Data only for lawful purposes and that under no circumstances will you use this Data to: (1) allow, enable, or otherwise support the transmission of mass unsolicited, commercial advertising or solicitations via e-mail, telephone, or facsimile; or (2) enable high volume, automated, electronic processes that apply to NIRA or NIRA Accredited Registrars and their computer systems. The compilation, repackaging, dissemination or other use of this Data is expressly prohibited.
-
-Domain Information
-Query: nic.net.ng
-Status: Active
-Created: 13 May 2009 15:27 WAT
-Modified: 02 Jul 2010 20:06 WAT
-Expires: 31 Jul 2020 00:00 WAT
-Name Servers:
- rns1.nic.net.ng
- rns2.nic.net.ng
- rns3.nic.net.ng
- rns4.nic.net.ng
-
-Registrar Information
-Registrar Name: nira
-Country: NG
-
-
-
-
-Registrant:
-Organisation: Nigeria Internet Registration Association (NIRA)
-Address:
- 9 Kofo Abayomi Street
- Victoria Island
- Lagos, Lagos, Nigeria P O Box 1088 Yaba
- NG
-Email Address: ugo@nira.org.ng
-
-
-Admin Contact:
-Organisation: Nigeria Internet Registration Association (NIRA)
-Address:
- 9 Kofo Abayomi Street
- Victoria Island
- Lagos, Lagos, Nigeria P O Box 1088 Yaba
- NG
-Email Address: ugo@nira.org.ng
-
@@ -1,9 +1,8 @@
+Domain Name: u34jedzcq.ng
+Domain Status: Available
+
<br/>
<b>TERMS OF USE:</b> You are not authorized to access or query our Whois database through the use of electronic processes that are high-volume and automated. Whois database is provided by NIRA as a service to the internet community. <br/><br/>The data is for information purposes only. NIRA does not guarantee its accuracy. By submitting a Whois query, you agree to abide by the following terms of use: You agree that you may use this Data only for lawful purposes and that under no circumstances will you use this Data to: (1) allow, enable, or otherwise support the transmission of mass unsolicited, commercial advertising or solicitations via e-mail, telephone, or facsimile; or (2) enable high volume, automated, electronic processes that apply to NIRA or NIRA Accredited Registrars and their computer systems. The compilation, repackaging, dissemination or other use of this Data is expressly prohibited.
-Domain Information
-Query: u34jedzcq.ng
-Status: Not Registered
-
-
+>>> Last update of WHOIS database: 2012-10-25T09:23:38.462Z <<<
@@ -1,41 +0,0 @@
-<br/>
-<b>TERMS OF USE:</b> You are not authorized to access or query our Whois database through the use of electronic processes that are high-volume and automated. Whois database is provided by NIRA as a service to the internet community. <br/><br/>The data is for information purposes only. NIRA does not guarantee its accuracy. By submitting a Whois query, you agree to abide by the following terms of use: You agree that you may use this Data only for lawful purposes and that under no circumstances will you use this Data to: (1) allow, enable, or otherwise support the transmission of mass unsolicited, commercial advertising or solicitations via e-mail, telephone, or facsimile; or (2) enable high volume, automated, electronic processes that apply to NIRA or NIRA Accredited Registrars and their computer systems. The compilation, repackaging, dissemination or other use of this Data is expressly prohibited.
-
-Domain Information
-Query: ui.edu.ng
-Status: Delegated
-Created: 13 May 2009 15:21 WAT
-Modified: 19 Sep 2011 10:40 WAT
-Expires: 13 Jul 2012 15:21 WAT
-Name Servers:
- ns1.dnspark.net
- ns2.dnspark.net
- ns3.dnspark.net
- ns4.dnspark.net
- ns5.dnspark.net
-
-Registrar Information
-Registrar Name: skanhost
-Registration URL: www.skannet.com.ng
-Address: General Data Engineering Services Plc
-16, Oshin Road, off kongi street, Bodija, Ibadan, Oyo State.
-Country: NG
-Customer Service Contact: SKANNET Hostmaster
-Customer Service Email: webmaster@skannet.com
-Admin Contact: SKANNET Hostmaster
-
-
-
-
-Registrant:
-Organisation: General Data Engineering Services Plc
-Address:
- No 18b Oshin Road Kongi
- Ibadan NG
-Email Address: hostmaster@skannet.com.ng
-
-
-Admin Contact:
-Organisation: General Data Engineering Services Plc
-Email Address: hostmaster@skannet.com.ng
-
@@ -0,0 +1,51 @@
+Domain Name: nic.net.ng
+Domain ID: 6808-NIRA
+WHOIS Server: whois.nic.ng
+Referral URL:
+Updated Date: 2012-08-24T13:46:14.774Z
+Creation Date: 2009-05-13T14:27:27.009Z
+Registry Expiry Date: 2020-07-30T23:00:00.000Z
+Sponsoring Registrar: nira
+Sponsoring Registrar IANA ID:
+Domain Status: ok
+
+Registrant ID: 80023-NIRA
+Registrant Name: Domain Admin
+Registrant Organization: Nigeria Internet Registration Association
+Registrant Street: 9 Kofo Abayomi Street
+Registrant City: Victoria Island
+Registrant State/Province: Lagos
+Registrant Postal Code: 101241
+Registrant Country: NG
+Registrant Phone: +2348086031704
+Registrant Phone Ext:
+Registrant Email: admin@nira.org.ng
+
+Admin ID: 23141-NIRA
+Admin Organization: Nigeria Internet Registration Association (NIRA)
+Admin Email: ugo@nira.org.ng
+
+Name Server: rns1.nic.net.ng
+Name Server: rns2.nic.net.ng
+Name Server: rns3.nic.net.ng
+Name Server: rns4.nic.net.ng
+
+DNSSEC: unsigned
+
+
+Additional Section
+
+
+Sponsoring Registrar URL:
+Sponsoring Registrar Address:
+Sponsoring Registrar Country: NG
+Sponsoring Registrar Customer Service Contact:
+Sponsoring Registrar Customer Service Email:
+Sponsoring Registrar Admin Contact:
+
+
+<br/>
+<b>TERMS OF USE:</b> You are not authorized to access or query our Whois database through the use of electronic processes that are high-volume and automated. Whois database is provided by NIRA as a service to the internet community. <br/><br/>The data is for information purposes only. NIRA does not guarantee its accuracy. By submitting a Whois query, you agree to abide by the following terms of use: You agree that you may use this Data only for lawful purposes and that under no circumstances will you use this Data to: (1) allow, enable, or otherwise support the transmission of mass unsolicited, commercial advertising or solicitations via e-mail, telephone, or facsimile; or (2) enable high volume, automated, electronic processes that apply to NIRA or NIRA Accredited Registrars and their computer systems. The compilation, repackaging, dissemination or other use of this Data is expressly prohibited.
+
+
+>>> Last update of WHOIS database: 2012-10-25T09:23:38.462Z <<<
@@ -1,9 +1,8 @@
+Domain Name: u34jedzcq.ng
+Domain Status: Available
+
<br/>
<b>TERMS OF USE:</b> You are not authorized to access or query our Whois database through the use of electronic processes that are high-volume and automated. Whois database is provided by NIRA as a service to the internet community. <br/><br/>The data is for information purposes only. NIRA does not guarantee its accuracy. By submitting a Whois query, you agree to abide by the following terms of use: You agree that you may use this Data only for lawful purposes and that under no circumstances will you use this Data to: (1) allow, enable, or otherwise support the transmission of mass unsolicited, commercial advertising or solicitations via e-mail, telephone, or facsimile; or (2) enable high volume, automated, electronic processes that apply to NIRA or NIRA Accredited Registrars and their computer systems. The compilation, repackaging, dissemination or other use of this Data is expressly prohibited.
-Domain Information
-Query: u34jedzcq.ng
-Status: Not Registered
-
-
+>>> Last update of WHOIS database: 2012-10-25T09:23:38.462Z <<<
@@ -17,15 +17,15 @@
#created_on
should: %s CLASS(time)
- should: %s == Time.parse("2009-05-13")
+ should: %s == Time.parse("2009-05-13 14:27:27 UTC")
#updated_on
should: %s CLASS(time)
- should: %s == Time.parse("2012-08-24")
+ should: %s == Time.parse("2012-08-24 13:46:14 UTC")
#expires_on
should: %s CLASS(time)
- should: %s == Time.parse("2020-07-31")
+ should: %s == Time.parse("2020-07-30 23:00:00 UTC")
#registrar
@@ -1,42 +1,51 @@
+Domain Name: nic.net.ng
+Domain ID: 6808-NIRA
+WHOIS Server: whois.nic.ng
+Referral URL:
+Updated Date: 2012-08-24T13:46:14.774Z
+Creation Date: 2009-05-13T14:27:27.009Z
+Registry Expiry Date: 2020-07-30T23:00:00.000Z
+Sponsoring Registrar: nira
+Sponsoring Registrar IANA ID:
+Domain Status: ok
+
+Registrant ID: 80023-NIRA
+Registrant Name: Domain Admin
+Registrant Organization: Nigeria Internet Registration Association
+Registrant Street: 9 Kofo Abayomi Street
+Registrant City: Victoria Island
+Registrant State/Province: Lagos
+Registrant Postal Code: 101241
+Registrant Country: NG
+Registrant Phone: +2348086031704
+Registrant Phone Ext:
+Registrant Email: admin@nira.org.ng
+
+Admin ID: 23141-NIRA
+Admin Organization: Nigeria Internet Registration Association (NIRA)
+Admin Email: ugo@nira.org.ng
+
+Name Server: rns1.nic.net.ng
+Name Server: rns2.nic.net.ng
+Name Server: rns3.nic.net.ng
+Name Server: rns4.nic.net.ng
+
+DNSSEC: unsigned
+
+
+Additional Section
+
+
+Sponsoring Registrar URL:
+Sponsoring Registrar Address:
+Sponsoring Registrar Country: NG
+Sponsoring Registrar Customer Service Contact:
+Sponsoring Registrar Customer Service Email:
+Sponsoring Registrar Admin Contact:
+
+
<br/>
<b>TERMS OF USE:</b> You are not authorized to access or query our Whois database through the use of electronic processes that are high-volume and automated. Whois database is provided by NIRA as a service to the internet community. <br/><br/>The data is for information purposes only. NIRA does not guarantee its accuracy. By submitting a Whois query, you agree to abide by the following terms of use: You agree that you may use this Data only for lawful purposes and that under no circumstances will you use this Data to: (1) allow, enable, or otherwise support the transmission of mass unsolicited, commercial advertising or solicitations via e-mail, telephone, or facsimile; or (2) enable high volume, automated, electronic processes that apply to NIRA or NIRA Accredited Registrars and their computer systems. The compilation, repackaging, dissemination or other use of this Data is expressly prohibited.
-Domain Information
-Query: nic.net.ng
-Status: Delegated
-Created: 13 May 2009
-Modified: 24 Aug 2012
-Expires: 31 Jul 2020
-Name Servers:
- rns1.nic.net.ng
- rns2.nic.net.ng
- rns3.nic.net.ng
- rns4.nic.net.ng
-
-Registrar Information
-Registrar Name: nira
-Country: NG
-
-
-
-
-Registrant:
-Name: Domain Admin
-Organisation: Nigeria Internet Registration Association
-Address:
- 9 Kofo Abayomi Street
- Victoria Island, Lagos 101241
- NG
-Email Address: admin@nira.org.ng
-Phone Number: +2348086031704
-
-
-Admin Contact:
-Organisation: Nigeria Internet Registration Association (NIRA)
-Address:
- 9 Kofo Abayomi Street
- Victoria Island
- Lagos, Lagos, Nigeria P O Box 1088 Yaba
- NG
-Email Address: ugo@nira.org.ng
+>>> Last update of WHOIS database: 2012-10-25T09:23:38.462Z <<<
@@ -3,7 +3,7 @@
# This file is autogenerated. Do not edit it manually.
# If you want change the content of this file, edit
#
-# /spec/fixtures/responses/whois.nic.net.ng/property_status_not_registered.expected
+# /spec/fixtures/responses/whois.nic.net.ng/property_status_available.expected
#
# and regenerate the tests with the following rake task
#
@@ -13,10 +13,10 @@
require 'spec_helper'
require 'whois/record/parser/whois.nic.net.ng.rb'
-describe Whois::Record::Parser::WhoisNicNetNg, "property_status_not_registered.expected" do
+describe Whois::Record::Parser::WhoisNicNetNg, "property_status_available.expected" do
subject do
- file = fixture("responses", "whois.nic.net.ng/property_status_not_registered.txt")
+ file = fixture("responses", "whois.nic.net.ng/property_status_available.txt")
part = Whois::Record::Part.new(:body => File.read(file))
described_class.new(part)
end
@@ -1,39 +0,0 @@
-# encoding: utf-8
-
-# This file is autogenerated. Do not edit it manually.
-# If you want change the content of this file, edit
-#
-# /spec/fixtures/responses/whois.nic.net.ng/property_status_delegated.expected
-#
-# and regenerate the tests with the following rake task
-#
-# $ rake spec:generate
-#
-
-require 'spec_helper'
-require 'whois/record/parser/whois.nic.net.ng.rb'
-
-describe Whois::Record::Parser::WhoisNicNetNg, "property_status_delegated.expected" do
-
- subject do
- file = fixture("responses", "whois.nic.net.ng/property_status_delegated.txt")
- part = Whois::Record::Part.new(:body => File.read(file))
- described_class.new(part)
- end
-
- describe "#status" do
- it do
- subject.status.should == :registered
- end
- end
- describe "#available?" do
- it do
- subject.available?.should == false
- end
- end
- describe "#registered?" do
- it do
- subject.registered?.should == true
- end
- end
-end
@@ -3,7 +3,7 @@
# This file is autogenerated. Do not edit it manually.
# If you want change the content of this file, edit
#
-# /spec/fixtures/responses/whois.nic.net.ng/property_status_active.expected
+# /spec/fixtures/responses/whois.nic.net.ng/property_status_ok.expected
#
# and regenerate the tests with the following rake task
#
@@ -13,10 +13,10 @@
require 'spec_helper'
require 'whois/record/parser/whois.nic.net.ng.rb'
-describe Whois::Record::Parser::WhoisNicNetNg, "property_status_active.expected" do
+describe Whois::Record::Parser::WhoisNicNetNg, "property_status_ok.expected" do
subject do
- file = fixture("responses", "whois.nic.net.ng/property_status_active.txt")
+ file = fixture("responses", "whois.nic.net.ng/property_status_ok.txt")
part = Whois::Record::Part.new(:body => File.read(file))
described_class.new(part)
end
Oops, something went wrong.

0 comments on commit 03d26f2

Please sign in to comment.