Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Add support for "RESERVED" status to whois.cctld.uz.rb parser #162

Merged
merged 1 commit into from

2 participants

@sherwind

No description provided.

@weppos weppos was assigned
lib/whois/record/parser/whois.cctld.uz.rb
@@ -31,6 +31,7 @@ class WhoisCctldUz < Base
if content_for_scanner =~ /^Status: (.+?)\n/
case $1.downcase
when "active" then :registered
+ when "reserved" then :registered
@weppos Owner
weppos added a note

Returned status should be :reserved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
@sherwind

Got it, already updated the patch.

@weppos weppos merged commit 805c376 into weppos:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
View
1  lib/whois/record/parser/whois.cctld.uz.rb
@@ -31,6 +31,7 @@ class WhoisCctldUz < Base
if content_for_scanner =~ /^Status: (.+?)\n/
case $1.downcase
when "active" then :registered
+ when "reserved" then :reserved
else
Whois.bug!(ParserError, "Unknown status `#{$1}'.")
end
View
8 spec/fixtures/responses/whois.cctld.uz/property_status_reserved.expected
@@ -0,0 +1,8 @@
+#status
+ should: %s == :reserved
+
+#available?
+ should: %s == false
+
+#registered?
+ should: %s == true
View
123 spec/fixtures/responses/whois.cctld.uz/property_status_reserved.txt
@@ -0,0 +1,123 @@
+
+% UzWhois Server Version 1.0
+
+% Domain names in the .uz domain can now be registered
+% with many different competing registrars. Go to http://www.cctld.uz/
+% for detailed information.
+
+ Domain Name: CCTLD.UZ
+ Registrar: UZINFOCOM
+ Whois Server: www.whois.uz
+ Referral URL: http://www.cctld.uz/
+ Name Server: ns.uz. 91.212.89.8
+ Name Server: ns2.uz. 81.95.224.158
+ Status: RESERVED
+ Updated Date: 01-may-2005
+ Creation Date: 01-May-2005
+ Expiration Date: -
+
+
+% >>> Last update of whois database: Fri, 11 May 2012 14:59:05 +0500 <<<
+
+% NOTICE: The expiration date displayed in this record is the date the
+% registrar's sponsorship of the domain name registration in the registry is
+% currently set to expire. This date does not necessarily reflect the expiration
+% date of the domain name registrant's agreement with the sponsoring
+% registrar. Users may consult the sponsoring registrar's Whois database to
+% view the registrar's reported date of expiration for this registration.
+
+% TERMS OF USE: You are not authorized to access or query our Whois
+% database through the use of electronic processes that are high-volume and
+% automated except as reasonably necessary to register domain names or
+% modify existing registrations; the Data in Center UZINFOCOM ccTLD.uz
+% Services ( Center UZINFOCOM ) Whois database is provided by Center UZINFOCOM for
+% information purposes only, and to assist persons in obtaining information
+% about or related to a domain name registration record. Center UZINFOCOM 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 Center UZINFOCOM (or its computer systems). The compilation,
+% repackaging, dissemination or other use of this Data is expressly
+% prohibited without the prior written consent of Center UZINFOCOM. You agree not to
+% use electronic processes that are automated and high-volume to access or
+% query the Whois database except as reasonably necessary to register
+% domain names or modify existing registrations. Center UZINFOCOM reserves the right
+% to restrict your access to the Whois database in its sole discretion to ensure
+% operational stability. Center UZINFOCOM may restrict or terminate your access to the
+% Whois database for failure to abide by these terms of use. Center UZINFOCOM
+% reserves the right to modify these terms at any time.
+
+% The Registry database contains ONLY .UZ domains and
+% Registrars.
+
+% Registration Service Provided By: UZINFOCOM
+
+Domain Name: CCTLD.UZ
+
+Registrant:
+ not.defined.
+ Rakhimov D. K. (info [at] uzinfocom.uz)
+ A.Navoi str., 28 B
+ Tashkent
+ Uzbekistan, 100011
+ UZ
+ Tel. +998 71 238-42-00
+ Fax. +998 71 238-42-48
+
+Creation Date: 01-May-2005
+Expiration Date: -
+
+Domain servers in listed order:
+ ns.uz.
+ ns2.uz.
+
+
+Administrative Contact:
+ Center UZINFOCOM
+ Djuraev I.D. (info [at] uzinfocom.uz)
+ A.Navoi str., 28 B
+ Tashkent
+ Uzbekistan, 100011
+ UZ
+ Tel. +998 71 238-41-48
+ Fax. +998 71 238-42-48
+
+Technical Contact:
+ Center UZINFOCOM
+ Deykhin V.V. (info [at] uzinfocom.uz)
+ A.Navoi str., 28 B
+ Tashkent
+ Uzbekistan, 100011
+ UZ
+ Tel. +998 71 238-42-45
+ Fax. +998 71 238-42-48
+
+Billing Contact:
+ Center UZINFOCOM
+ Karnaushevskaya A.K. (info [at] uzinfocom.uz)
+ A.Navoi str., 28 B
+ Tashkent
+ Uzbekistan, 100011
+ UZ
+ Tel. +998 71 238-42-00
+ Fax. +998 71 238-42-48
+
+Status: RESERVED
+
+% The data in this whois database is provided to you for informationpurposes only, that is, to assist you in obtaining
+% information about or related to a domain name registration record. We make this informationavailable "as is", and do
+% not guarantee its accuracy. By submitting awhois query, you agree that you will use this data only for lawfulpurposes
+% and that, under no circumstances will you use this data to:(1) enable high volume, automated, electronic processes
+% that stress orload this whois database system providing you this information; or(2) allow, enable, or otherwise
+% support the transmission of massunsolicited, commercial advertising or solicitations via direct mail,electronic mail,
+% or by telephone. The compilation, repackaging,dissemination or other use of this data is expressly prohibited withoutprior
+% written consent from us. The registrar of record is Critical Internet, Inc.. We reserve the right to modifythese terms at
+% any time. By submitting this query, you agree to abideby these terms.
+
+
+% The Whois Server (ver. 1.0) of ccTLD.UZ
+% (c) 2005, Center UZINFOCOM
+
View
39 spec/whois/record/parser/responses/whois.cctld.uz/property_status_reserved_spec.rb
@@ -0,0 +1,39 @@
+# 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.cctld.uz/property_status_reserved.expected
+#
+# and regenerate the tests with the following rake task
+#
+# $ rake spec:generate
+#
+
+require 'spec_helper'
+require 'whois/record/parser/whois.cctld.uz.rb'
+
+describe Whois::Record::Parser::WhoisCctldUz, "property_status_reserved.expected" do
+
+ before(:each) do
+ file = fixture("responses", "whois.cctld.uz/property_status_reserved.txt")
+ part = Whois::Record::Part.new(:body => File.read(file))
+ @parser = klass.new(part)
+ end
+
+ describe "#status" do
+ it do
+ @parser.status.should == :reserved
+ end
+ end
+ describe "#available?" do
+ it do
+ @parser.available?.should == false
+ end
+ end
+ describe "#registered?" do
+ it do
+ @parser.registered?.should == true
+ end
+ end
+end
Something went wrong with that request. Please try again.