Repository: richardpenman/whois (language: python)

Issue:
Default parser does not have Registrar URL
I've noticed that the default parser does not include the Registrar URL by default. Some suffix domains, like .com, provide this Registrar URL, but this library doesn't return it.

For example, take `whois.whois("google.com")`:

```
{
  "domain_name": [
    "GOOGLE.COM",
    "google.com"
  ],
  "registrar": "MarkMonitor, Inc.",
  "whois_server": "whois.markmonitor.com",
  ...
}
```

While the whois command returns:

```
Domain Name: google.com
Registry Domain ID: 2138514_DOMAIN_COM-VRSN
Registrar WHOIS Server: whois.markmonitor.com
Registrar URL: http://www.markmonitor.com
...
```

As well, there's more info that isn't included by default.


Discussion / hints:
PR for this would be welcome!

Fix patch:
diff --git a/whois/parser.py b/whois/parser.py
index f5fa248..a3ee7a6 100644
--- a/whois/parser.py
+++ b/whois/parser.py
@@ -97,6 +97,7 @@ class WhoisEntry(dict):
     _regex = {
         "domain_name": r"Domain Name: *(.+)",
         "registrar": r"Registrar: *(.+)",
+        "registrar_url": r"Registrar URL: *(.+)",
         "whois_server": r"Whois Server: *(.+)",
         "referral_url": r"Referral URL: *(.+)",  # http url of whois_server
         "updated_date": r"Updated Date: *(.+)",


Test patch:
diff --git a/test/samples/expected/nyan.cat b/test/samples/expected/nyan.cat
index 367f412..cea9594 100644
--- a/test/samples/expected/nyan.cat
+++ b/test/samples/expected/nyan.cat
@@ -1,1 +1,1 @@
-{"domain_name": "nyan.cat", "expiration_date": "2018-04-13 19:52:17.635000", "updated_date": "2017-07-07 17:24:23.746000", "registrar": "GANDI SAS", "registrar_url": null, "creation_date": "2011-04-13 19:52:17.635000", "status": "ok https://icann.org/epp#ok"}
\ No newline at end of file
+{"domain_name": "nyan.cat", "expiration_date": "2018-04-13 19:52:17.635000", "updated_date": "2017-07-07 17:24:23.746000", "registrar": "GANDI SAS", "registrar_url": "https://www.gandi.net/", "creation_date": "2011-04-13 19:52:17.635000", "status": "ok https://icann.org/epp#ok"}
diff --git a/test/samples/expected/urlowl.com b/test/samples/expected/urlowl.com
index d827dc2..8240628 100644
--- a/test/samples/expected/urlowl.com
+++ b/test/samples/expected/urlowl.com
@@ -1,1 +1,1 @@
-{"domain_name": "URLOWL.COM", "expiration_date": "2018-02-21 19:24:57", "updated_date": "2017-03-31 07:36:34", "registrar": "DYNADOT, LLC", "registrar_url": null, "creation_date": "2013-02-21 19:24:57", "status": "clientTransferProhibited https://icann.org/epp#clientTransferProhibited"}
\ No newline at end of file
+{"domain_name": "URLOWL.COM", "expiration_date": "2018-02-21 19:24:57", "updated_date": "2017-03-31 07:36:34", "registrar": "DYNADOT, LLC", "registrar_url": "http://www.dynadot.com", "creation_date": "2013-02-21 19:24:57", "status": "clientTransferProhibited https://icann.org/epp#clientTransferProhibited"}