Sha256: 0ede82add0543a38f96d16d0844485f1a9fcc710174101129887149e36107746
Contents?: true
Size: 881 Bytes
Versions: 1
Compression:
Stored size: 881 Bytes
Contents
# # = Ruby Whois # # An intelligent pure Ruby WHOIS client. # # # Category:: Net # Package:: Whois # Author:: Simone Carletti <weppos@weppos.net> # License:: MIT License # #-- # #++ module Whois class Server module Adapters class Afilias < Base def request(qstring) response = ask_the_socket(qstring, "whois.afilias-grs.info", DEFAULT_WHOIS_PORT) append_to_buffer response, "whois.afilias-grs.info" if endpoint = extract_referral(response) response = ask_the_socket(qstring, endpoint, DEFAULT_WHOIS_PORT) append_to_buffer response, endpoint end end private def extract_referral(response) if response =~ /Domain Name:/ && response =~ /Whois Server:(\S+)/ $1 end end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
whois-0.8.0 | lib/whois/server/adapters/afilias.rb |