The reg-dom libs are available in C, Perl and PHP so far.
They include recent representations of the effective TLD list available at
and help to convert an arbitrary domain name to the registered domain name.
registeredDomain = getRegisteredDomain(ingoingDomain);
1) NULL if ingoingDomain is a TLD
2) the registered domain name if TLD is known
3) just <domain>.<tld> if <tld> is unknown
This case was added to support new TLDs in outdated reg-dom libs
by a certain likelihood. This fallback method is implemented in the
last conversion step and can be simply commented out.
<Apache 2.0 Licence>
Nightly updated if necessary,
download at: http://www.dkim-reputation.org/regdom-lib-downloads/
Source Code at GitHub: https://github.com/usrflo/registered-domain-libs