New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not successfully check 1and1 domains #78

Closed
scaryclam opened this Issue Oct 14, 2017 · 4 comments

Comments

Projects
None yet
3 participants
@scaryclam

scaryclam commented Oct 14, 2017

Attempting to run check_domain.sh -d example.com (where example.com is a 1and1 domain) results in:

UNKNOWN - WHOIS exited with error 1.

The output for the whois is:

Domain Name: EXAMPLE.COM
Registry Domain ID: 1234567890_DOMAIN_COM-VRSN
Registrar WHOIS Server: whois.1and1.com
Registrar URL: http://registrar.1and1.info
Updated Date: 2017-10-01T13:08:01Z
Creation Date: 2017-05-01T13:08:37Z
Registry Expiry Date: 2018-05-01T13:00:00Z
Registrar: 1&1 Internet SE
Registrar IANA ID: 83
Registrar Abuse Contact Email: abuse@1and1.com
Registrar Abuse Contact Phone: +1.6105601459
Domain Status: clientTransferProhibited https://icann.org/epp#clientTransferProhibited
Name Server: NS-1234.AWSDNS-00.ORG
Name Server: NS-123.AWSDNS-00.COM
Name Server: NS-1234.AWSDNS-00.CO.UK
Name Server: NS-123.AWSDNS-00.NET
DNSSEC: unsigned
URL of the ICANN Whois Inaccuracy Complaint Form: https://www.icann.org/wicf/

Last update of whois database: 2017-10-01T14:00:00Z <<<

For more information on Whois status codes, please visit https://icann.org/epp

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 VeriSign Global Registry
Services' ("VeriSign") Whois database is provided by VeriSign for
information purposes only, and to assist persons in obtaining information
about or related to a domain name registration record. VeriSign 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 VeriSign (or its computer systems). The compilation,
repackaging, dissemination or other use of this Data is expressly
prohibited without the prior written consent of VeriSign. 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. VeriSign reserves the right
to restrict your access to the Whois database in its sole discretion to ensure
operational stability. VeriSign may restrict or terminate your access to the
Whois database for failure to abide by these terms of use. VeriSign
reserves the right to modify these terms at any time.

The Registry database contains ONLY .COM, .NET, .EDU domains and
Registrars.

I hope that's helpful. It'd be great to get the script working for this as well.

@scaryclam

This comment has been minimized.

Show comment
Hide comment
@scaryclam

scaryclam Oct 14, 2017

Update: it's not just 1and1 domain and it appears as though line 217:

$whois ${server:+-h $server} "$domain" > "$outfile" 2>&1 && error=$? || error=$?

is where things are going a bit weird. error is being set to 1. Running:
foo=0 && whois google.com && foo=$? || foo=$?
on the command line, foo is set to 1, even though no errors appear to be given by whois

scaryclam commented Oct 14, 2017

Update: it's not just 1and1 domain and it appears as though line 217:

$whois ${server:+-h $server} "$domain" > "$outfile" 2>&1 && error=$? || error=$?

is where things are going a bit weird. error is being set to 1. Running:
foo=0 && whois google.com && foo=$? || foo=$?
on the command line, foo is set to 1, even though no errors appear to be given by whois

@glensc

This comment has been minimized.

Show comment
Hide comment
@glensc

glensc Oct 15, 2017

Owner

what's your whois version? whois 5.2.17 is required for com domains: #75 (comment)

also test what whois exit code is, run:

whois google.com; echo $?
Owner

glensc commented Oct 15, 2017

what's your whois version? whois 5.2.17 is required for com domains: #75 (comment)

also test what whois exit code is, run:

whois google.com; echo $?
@scaryclam

This comment has been minimized.

Show comment
Hide comment
@scaryclam

scaryclam Oct 16, 2017

Thanks for the prompt response. I apologise as I didn't find that issue when I originally had a look to see if this had been reported before, it appears to be the same problem.

Whois version is 5.1.1.

Using the -s switch works perfectly!

Thanks again, I look forward to adding your script to our monitoring.

scaryclam commented Oct 16, 2017

Thanks for the prompt response. I apologise as I didn't find that issue when I originally had a look to see if this had been reported before, it appears to be the same problem.

Whois version is 5.1.1.

Using the -s switch works perfectly!

Thanks again, I look forward to adding your script to our monitoring.

@scaryclam scaryclam closed this Oct 16, 2017

@ramyacharan

This comment has been minimized.

Show comment
Hide comment
@ramyacharan

ramyacharan Mar 1, 2018

Hi I want to know the expiry date of .au and .eu domains unable(UNKNOWN - Unable to figure out expiration date for *****.eu domain) to get them from this script need to add different servers for those requests i think , as i have 0 knowledge in scripting so could you please provide me the updated script , so that it will be very helpful to me.
Thanks in advance

ramyacharan commented Mar 1, 2018

Hi I want to know the expiry date of .au and .eu domains unable(UNKNOWN - Unable to figure out expiration date for *****.eu domain) to get them from this script need to add different servers for those requests i think , as i have 0 knowledge in scripting so could you please provide me the updated script , so that it will be very helpful to me.
Thanks in advance

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