Skip to content

Commit 25a9134

Browse files
Merge pull request #301 from KolevVelyan/fix-nl-parsing
Update `.nl` parsing
2 parents 18c79e2 + 5bddd95 commit 25a9134

8 files changed

Lines changed: 149 additions & 205 deletions

File tree

test/samples/expected/app.nl

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"domain_name": "app.nl",
3+
"expiration_date": null,
4+
"updated_date": "2025-09-12 00:00:00+00:00",
5+
"creation_date": "1998-02-20 00:00:00+00:00",
6+
"status": "active",
7+
"registrar": "Hosting Secure",
8+
"registrar_address": "Weesperstraat 61",
9+
"registrar_postal_code": "1018VN",
10+
"registrar_city": "Amsterdam",
11+
"registrar_country": "Netherlands",
12+
"reseller": "Hoasted",
13+
"reseller_address": "Weesperstraat 61",
14+
"reseller_postal_code": "3512AB",
15+
"reseller_city": "Amsterdam",
16+
"reseller_country": "Netherlands",
17+
"abuse_phone": "+31.0202018165",
18+
"abuse_email": "abuse@hostingsecure.com",
19+
"dnssec": "yes",
20+
"name_servers": [
21+
"ns1.hoasted.nl",
22+
"ns2.hoasted.eu",
23+
"ns3.hoasted.com"
24+
]
25+
}

test/samples/expected/eurid.eu

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,29 @@
1-
{"domain_name": "eurid.eu", "expiration_date": null, "updated_date": null, "registrar": "EURid vzw", "registrar_url": "https://www.eurid.eu", "creation_date": null, "status": null}
1+
{
2+
"domain_name": "eurid.eu",
3+
"script": "LATIN",
4+
"reseller_org": null,
5+
"reseller_lang": null,
6+
"reseller_email": null,
7+
"tech_org": "EURid vzw",
8+
"tech_lang": "en",
9+
"tech_email": "tech@eurid.eu",
10+
"registrar": "EURid vzw",
11+
"registrar_url": "https://www.eurid.eu",
12+
"name_servers": [
13+
"ns3.eurid.eu (185.36.4.253)",
14+
"ns3.eurid.eu (2001:67c:9c:3937::253)",
15+
"nsx.eurid.eu (185.151.141.1)",
16+
"nsx.eurid.eu (2a02:568:fe00::6575)",
17+
"ns1.eurid.eu (2001:67c:9c:3937::252)",
18+
"ns1.eurid.eu (185.36.4.252)",
19+
"ns2.eurid.eu (2001:67c:40:3937::252)",
20+
"ns2.eurid.eu (185.36.6.252)",
21+
"ns4.eurid.eu (2001:67c:40:3937::253)",
22+
"ns4.eurid.eu (185.36.6.253)",
23+
"nsp.netnod.se"
24+
],
25+
"dnssec_flags": "KSK",
26+
"dnssec_protocol": "3",
27+
"dnssec_algorithm": "RSA_SHA256",
28+
"dnssec_pubkey": "AwEAAcOQldGtC33GLx8s335UscKMPlWjDXCqbhR2QyAYcfS4CZS6YHg3A1Zz/K3VurTZF68aSaRkNupZuEgt4jozE3v4+t+2qOfiATvoOCrf74hWduBPwk9Go0z7FVlDkok1/qMQmqOtih8TFP85b+w6F/uyLMZS1JowMDUzRurmHJVoT4lW9+OCdrhuQFK9vU24Y8BmacoRy6mWBCFlysizlOIodwmquOf5A+3Nz0B3TLCK4fIYJYVxCUVlpRJ7uaBS+GLD7afuxkEesReYHgPWZFSDMbXk9Ugh+qUi8tEKKFls9TM3lK9BPBcciXUhI1bRJSHftqcNpMmLqg/79SwoWGc="
29+
}

test/samples/expected/marktplaats.nl

Lines changed: 0 additions & 1 deletion
This file was deleted.

test/samples/whois/app.nl

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
Domain name: app.nl
2+
Status: active
3+
4+
Reseller:
5+
Hoasted
6+
Weesperstraat 61
7+
3512AB Amsterdam
8+
Netherlands
9+
10+
Registrar:
11+
Hosting Secure
12+
Weesperstraat 61
13+
1018VN Amsterdam
14+
Netherlands
15+
16+
Abuse Contact:
17+
+31.0202018165
18+
abuse@hostingsecure.com
19+
20+
DNSSEC: yes
21+
22+
Domain nameservers:
23+
ns1.hoasted.nl
24+
ns2.hoasted.eu
25+
ns3.hoasted.com
26+
27+
Creation Date: 1998-02-20
28+
29+
Updated Date: 2025-09-12
30+
31+
Record maintained by: SIDN BV

test/samples/whois/eurid.eu

Lines changed: 52 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,52 @@
1+
% The WHOIS service offered by EURid and the access to the records
2+
% in the EURid WHOIS database are provided for information purposes
3+
% only. It allows persons to check whether a specific domain name
4+
% is still available or not and to obtain information related to
5+
% the registration records of existing domain names.
6+
%
7+
% EURid cannot, under any circumstances, be held liable in case the
8+
% stored information would prove to be wrong, incomplete or not
9+
% accurate in any sense.
10+
%
11+
% By submitting a query, you agree not to use the information made
12+
% available to:
13+
%
14+
% - allow, enable or otherwise support the transmission of unsolicited,
15+
% commercial advertising or other solicitations whether via email or
16+
% otherwise;
17+
% - target advertising in any possible way;
18+
% - cause nuisance in any possible way by sending messages to registrants,
19+
% whether by automated, electronic processes capable of enabling
20+
% high volumes or by other possible means.
21+
%
22+
% Without prejudice to the above, it is explicitly forbidden to extract,
23+
% copy and/or use or re-utilise in any form and by any means
24+
% (electronically or not) the whole or a quantitatively or qualitatively
25+
% substantial part of the contents of the WHOIS database without prior
26+
% and explicit permission by EURid, nor in any attempt hereof, to apply
27+
% automated, electronic processes to EURid (or its systems).
28+
%
29+
% You agree that any reproduction and/or transmission of data for
30+
% commercial purposes will always be considered as the extraction of a
31+
% substantial part of the content of the WHOIS database.
32+
%
33+
% By submitting the query, you agree to abide by this policy and accept
34+
% that EURid can take measures to limit the use of its WHOIS services
35+
% to protect the privacy of its registrants or the integrity
36+
% of the database.
37+
%
38+
% The EURid WHOIS service on port 43 (textual WHOIS) never discloses
39+
% any information concerning the registrant.
40+
% Registrant and on-site contact information can be obtained through use of the
41+
% web-based WHOIS service available from the EURid website www.eurid.eu
42+
%
143
% WHOIS eurid.eu
244
Domain: eurid.eu
345
Script: LATIN
446

547
Registrant:
648
NOT DISCLOSED!
7-
Visit www.eurid.eu for webbased WHOIS.
49+
Visit www.eurid.eu for the web-based WHOIS.
850

951
Technical:
1052
Organisation: EURid vzw
@@ -16,8 +58,16 @@ Registrar:
1658
Website: https://www.eurid.eu
1759

1860
Name servers:
19-
ns1.eurid.eu (185.36.4.252)
61+
ns3.eurid.eu (185.36.4.253)
62+
ns3.eurid.eu (2001:67c:9c:3937::253)
63+
nsx.eurid.eu (185.151.141.1)
64+
nsx.eurid.eu (2a02:568:fe00::6575)
2065
ns1.eurid.eu (2001:67c:9c:3937::252)
66+
ns1.eurid.eu (185.36.4.252)
67+
ns2.eurid.eu (2001:67c:40:3937::252)
68+
ns2.eurid.eu (185.36.6.252)
69+
ns4.eurid.eu (2001:67c:40:3937::253)
70+
ns4.eurid.eu (185.36.6.253)
2171
nsp.netnod.se
2272

2373
Keys:

test/samples/whois/marktplaats.nl

Lines changed: 0 additions & 48 deletions
This file was deleted.

test/test_parser.py

Lines changed: 0 additions & 150 deletions
Original file line numberDiff line numberDiff line change
@@ -501,45 +501,6 @@ def test_ie_parse(self):
501501
}
502502
self._parse_and_compare("rte.ie", data, expected_results)
503503

504-
def test_nl_parse(self):
505-
data = """
506-
Domain name: utwente.nl
507-
Status: active
508-
509-
Registrar:
510-
Universiteit Twente
511-
Drienerlolaan 5
512-
7522NB ENSCHEDE
513-
Netherlands
514-
515-
Abuse Contact:
516-
517-
DNSSEC: yes
518-
519-
Domain nameservers:
520-
ns3.utwente.nl 131.155.0.37
521-
ns1.utwente.nl 130.89.1.2
522-
ns1.utwente.nl 2001:67c:2564:a102::3:1
523-
ns2.utwente.nl 130.89.1.3
524-
ns2.utwente.nl 2001:67c:2564:a102::3:2
525-
526-
Record maintained by: NL Domain Registry
527-
"""
528-
expected_results = {
529-
"creation_date": None,
530-
"dnssec": "yes",
531-
"domain_name": "utwente.nl",
532-
"expiration_date": None,
533-
"name_servers": ["ns1.utwente.nl", "ns2.utwente.nl", "ns3.utwente.nl"],
534-
"registrar": "Universiteit Twente",
535-
"registrar_address": "Drienerlolaan 5",
536-
"registrar_city": "ENSCHEDE",
537-
"registrar_country": "Netherlands",
538-
"registrar_postal_code": "7522NB",
539-
"status": "active",
540-
"updated_date": None,
541-
}
542-
self._parse_and_compare("utwente.nl", data, expected_results)
543504

544505
def test_nl_expiration(self):
545506
data = """
@@ -897,117 +858,6 @@ def test_cm_parse(self):
897858
'ns1.huaweicloud-dns.org']
898859
}
899860
self._parse_and_compare("icp.cm", data, expected_results)
900-
901-
def test_eu_parse(self):
902-
data = """
903-
% The WHOIS service offered by EURid and the access to the records
904-
% in the EURid WHOIS database are provided for information purposes
905-
% only. It allows persons to check whether a specific domain name
906-
% is still available or not and to obtain information related to
907-
% the registration records of existing domain names.
908-
%
909-
% EURid cannot, under any circumstances, be held liable in case the
910-
% stored information would prove to be wrong, incomplete or not
911-
% accurate in any sense.
912-
%
913-
% By submitting a query, you agree not to use the information made
914-
% available to:
915-
%
916-
% - allow, enable or otherwise support the transmission of unsolicited,
917-
% commercial advertising or other solicitations whether via email or
918-
% otherwise;
919-
% - target advertising in any possible way;
920-
% - cause nuisance in any possible way by sending messages to registrants,
921-
% whether by automated, electronic processes capable of enabling
922-
% high volumes or by other possible means.
923-
%
924-
% Without prejudice to the above, it is explicitly forbidden to extract,
925-
% copy and/or use or re-utilise in any form and by any means
926-
% (electronically or not) the whole or a quantitatively or qualitatively
927-
% substantial part of the contents of the WHOIS database without prior
928-
% and explicit permission by EURid, nor in any attempt hereof, to apply
929-
% automated, electronic processes to EURid (or its systems).
930-
%
931-
% You agree that any reproduction and/or transmission of data for
932-
% commercial purposes will always be considered as the extraction of a
933-
% substantial part of the content of the WHOIS database.
934-
%
935-
% By submitting the query, you agree to abide by this policy and accept
936-
% that EURid can take measures to limit the use of its WHOIS services
937-
% to protect the privacy of its registrants or the integrity
938-
% of the database.
939-
%
940-
% The EURid WHOIS service on port 43 (textual WHOIS) never discloses
941-
% any information concerning the registrant.
942-
% Registrant and on-site contact information can be obtained through use of the
943-
% web-based WHOIS service available from the EURid website www.eurid.eu
944-
%
945-
% WHOIS eurid.eu
946-
Domain: eurid.eu
947-
Script: LATIN
948-
949-
Registrant:
950-
NOT DISCLOSED!
951-
Visit www.eurid.eu for the web-based WHOIS.
952-
953-
Technical:
954-
Organisation: EURid vzw
955-
Language: en
956-
Email: tech@eurid.eu
957-
958-
Registrar:
959-
Name: EURid vzw
960-
Website: https://www.eurid.eu
961-
962-
Name servers:
963-
ns3.eurid.eu (185.36.4.253)
964-
ns3.eurid.eu (2001:67c:9c:3937::253)
965-
nsx.eurid.eu (185.151.141.1)
966-
nsx.eurid.eu (2a02:568:fe00::6575)
967-
ns1.eurid.eu (2001:67c:9c:3937::252)
968-
ns1.eurid.eu (185.36.4.252)
969-
ns2.eurid.eu (2001:67c:40:3937::252)
970-
ns2.eurid.eu (185.36.6.252)
971-
ns4.eurid.eu (2001:67c:40:3937::253)
972-
ns4.eurid.eu (185.36.6.253)
973-
nsp.netnod.se
974-
975-
Keys:
976-
flags:KSK protocol:3 algorithm:RSA_SHA256 pubKey:AwEAAcOQldGtC33GLx8s335UscKMPlWjDXCqbhR2QyAYcfS4CZS6YHg3A1Zz/K3VurTZF68aSaRkNupZuEgt4jozE3v4+t+2qOfiATvoOCrf74hWduBPwk9Go0z7FVlDkok1/qMQmqOtih8TFP85b+w6F/uyLMZS1JowMDUzRurmHJVoT4lW9+OCdrhuQFK9vU24Y8BmacoRy6mWBCFlysizlOIodwmquOf5A+3Nz0B3TLCK4fIYJYVxCUVlpRJ7uaBS+GLD7afuxkEesReYHgPWZFSDMbXk9Ugh+qUi8tEKKFls9TM3lK9BPBcciXUhI1bRJSHftqcNpMmLqg/79SwoWGc=
977-
978-
Please visit www.eurid.eu for more info.
979-
"""
980-
981-
expected_results = {
982-
"domain_name": "eurid.eu",
983-
"script": "LATIN",
984-
"reseller_org": None,
985-
"reseller_lang": None,
986-
"reseller_email": None,
987-
"tech_org": "EURid vzw",
988-
"tech_lang": "en",
989-
"tech_email": "tech@eurid.eu",
990-
"registrar": "EURid vzw",
991-
"registrar_url": "https://www.eurid.eu",
992-
"name_servers": [
993-
"ns3.eurid.eu (185.36.4.253)",
994-
"ns3.eurid.eu (2001:67c:9c:3937::253)",
995-
"nsx.eurid.eu (185.151.141.1)",
996-
"nsx.eurid.eu (2a02:568:fe00::6575)",
997-
"ns1.eurid.eu (2001:67c:9c:3937::252)",
998-
"ns1.eurid.eu (185.36.4.252)",
999-
"ns2.eurid.eu (2001:67c:40:3937::252)",
1000-
"ns2.eurid.eu (185.36.6.252)",
1001-
"ns4.eurid.eu (2001:67c:40:3937::253)",
1002-
"ns4.eurid.eu (185.36.6.253)",
1003-
"nsp.netnod.se",
1004-
],
1005-
"dnssec_flags": "KSK",
1006-
"dnssec_protocol": "3",
1007-
"dnssec_algorithm": "RSA_SHA256",
1008-
"dnssec_pubkey": "AwEAAcOQldGtC33GLx8s335UscKMPlWjDXCqbhR2QyAYcfS4CZS6YHg3A1Zz/K3VurTZF68aSaRkNupZuEgt4jozE3v4+t+2qOfiATvoOCrf74hWduBPwk9Go0z7FVlDkok1/qMQmqOtih8TFP85b+w6F/uyLMZS1JowMDUzRurmHJVoT4lW9+OCdrhuQFK9vU24Y8BmacoRy6mWBCFlysizlOIodwmquOf5A+3Nz0B3TLCK4fIYJYVxCUVlpRJ7uaBS+GLD7afuxkEesReYHgPWZFSDMbXk9Ugh+qUi8tEKKFls9TM3lK9BPBcciXUhI1bRJSHftqcNpMmLqg/79SwoWGc=",
1009-
}
1010-
self._parse_and_compare("eurid.eu", data, expected_results)
1011861

1012862

1013863
if __name__ == "__main__":

0 commit comments

Comments
 (0)