Net::RDAP::Service(3)
π Net::RDAP::Service π
okay so bestie, you've found the page for Net::RDAP::Service β it's part of the User Contributed Perl Documentation collection, and it is exactly what it says on the tin: a module that gives you an interface to one specific RDAP server. one server. your server. main character energy, but for RDAP. π
β¨ NAME β¨
Net::RDAP::Service β a module which provides an interface to an RDAP server. π
β¨ SYNOPSIS β¨
like, here's the whole vibe in code form:
use Net::RDAP::Service;
#
# create a new service object:
#
my $svc = Net::RDAP::Service->new('https://www.example.com/rdap');
#
# get a domain:
#
my $domain = $svc->domain(Net::DNS::Domain->new('example.com'));
#
# do a search:
#
my $result = $svc->domains('name' => 'ex*mple.com');
#
# get help:
#
my $help = $svc->help;
no cap, that's the entire tour. π¦
β¨ DESCRIPTION β¨
so Net::RDAP is the big-picture bestie β it gives you a unified interface to the whole universe of RIR, domain registry, and domain registrar RDAP services. π
but Net::RDAP::Service? it's the one specific RDAP service interface. locked in, focused, obsessed with a single server.
you can do direct lookups of objects using methods of the same name that Net::RDAP provides. and on top of that, this module lets you do searches. π
β¨ METHODS β¨
πΈ Constructor
my $svc = Net::RDAP::Service->new($url);
creates a new Net::RDAP::Service object. $url is a string or a URI object representing the base URL of the service. either one, she's flexible. πββοΈ
you can also hand her a second argument, which should be an existing Net::RDAP instance. that one gets used when fetching resources from the server. π«Ά
π TLD Service Constructor
my $svc = Net::RDAP::Service->new_for_tld($tld);
this method searches the IANA registry for an entry for the TLD in $tld and returns the corresponding Net::RDAP::Service object. it's giving "find my server for me bestie." β¨
πΈ Lookup Methods
you can do direct lookups of objects using these methods:
domain()ip()autnum()entity()nameserver()
they all work exactly the same way as the methods of the same name on Net::RDAP. no surprises, no plot twists. π
πΈ Search Methods
you can perform searches using the following methods. heads up though: different services will support different search functions. not everyone can do everything, and that's okay. π
$result = $svc->domains(%QUERY);
$result = $svc->entities(%QUERY);
$result = $svc->nameservers(%QUERY);
$result = $svc->ips(%QUERY);
$result = $svc->autnums(%QUERY);
in all cases, %QUERY is a set of search parameters. here are some examples:
$result = $svc->domains(name => 'ex*mple.com');
$result = $svc->entities(fn => 'Ex*ample, Inc');
$result = $svc->nameservers(ip => '192.0.2.1');
$result = $svc->ips(handle => 'FOOBAR-RIR');
$result = $svc->autnums(handle => 'FOOBAR-RIR');
π¦ References
- Domain search: Section 3.2.1 of RFC 9083
https://www.rfc-editor.org/rfc/rfc9082.html#section-3.2.1 - Nameserver search: Section 3.2.2 of RFC 9083
https://www.rfc-editor.org/rfc/rfc9082.html#section-3.2.2 - Entity search: Section 3.2.3 of RFC 9083
https://www.rfc-editor.org/rfc/rfc9082.html#section-3.2.3 - "Reverse" search: RFC 9536
https://www.rfc-editor.org/rfc/rfc9536.html - IP search (EXPERIMENTAL): Section 2.2 of
draft-ietf-regext-rdap-rir-search-11https://www.ietf.org/archive/id/draft-ietf-regext-rdap-rir-search-11.html#section-2.2 - AS number search (EXPERIMENTAL): Section 2.3 of
draft-ietf-regext-rdap-rir-search-11https://www.ietf.org/archive/id/draft-ietf-regext-rdap-rir-search-11.html#section-2.3
β οΈ note that not all RDAP servers support all search types or parameters. do a vibe check before you rely on it, fr fr.
the following parameters can be specified:
- domains:
"name"(domain name),"nsLdhName"(nameserver name),"nsIp"(nameserver IP address) - nameservers:
"name"(host name),"ip"(IP address) - entities:
"handle","fn"(Formatted Name) - ips:
"handle","name" - autnums:
"handle","name"
search parameters can contain the wildcard character "*" anywhere in the string. anywhere!! π
these methods all return Net::RDAP::SearchResult objects. π¦
πΈ "Reverse" Search
π¨ IMPORTANT NOTE: due to a lack of server implementations to test against, reverse search. functionality is experimental and should not be relied upon in production code. like, seriously. do not. π
some RDAP servers implement "reverse search" which is specified in RFC 9536 https://www.rfc-editor.org/rfc/rfc9536.html. this lets you search for objects based on their relationship to some other object: for example, to search for domains that have a relationship to a specific entity. it's giving "who's connected to who" gossip but for DNS. π«’
to perform a reverse search (on a server that supports this), pass a set of query parameters using the "entity" parameter:
$result = $svc->domains(entity => { handle => 9999 });
π¦ RIR Relation Searches
Section 3 of draft-ietf-regext-rdap-rir-search-11 https://www.ietf.org/archive/id/draft-ietf-regext-rdap-rir-search-11.html#section-3 describes searches and link relations for finding objects and sets of objects with respect to their position within a hierarchy. very "know your place in the family tree" of it all. π³
some examples:
$svc->ips(up => q{2001:DB8::42});
π since this specification is in draft, this functionality may change significantly in future versions of this module. don't get too attached bestie.
πΈ Help
each RDAP server has a "help" endpoint which provides "helpful information" β and yes that's in quotes in the original, we love a self-aware spec β which means: command syntax, terms of service, privacy policy, rate-limiting policy, supported authentication methods, supported extensions, technical support contact, etc. the whole info dump. πβ¨
you get all of that by performing a "help" query:
my $help = $svc->help;
the return value is a Net::RDAP::Help object. π
πΈ Extension Implementation
you can figure out if an RDAP server implements a particular RDAP extension using implements():
$svc->implements('lunarNic');
this will return a true value if the RDAP server advertises support for the "lunarNic" extension. π
how does it know? this methods works by checking the "help" response β and it will throw an exception if the help request fails. so like, be ready for that. π
β¨ COPYRIGHT β¨
Copyright 2018-2023 CentralNic Ltd, 2024-2026 Gavin Brown. for licensing information, please see the "LICENSE" file in the Net::RDAP distribution. π
and that's the whole page bestie!! π this one's from perl v5.42.2, dated 2026-06-17, and it's the Net::RDAP::Service(3) manual page β go forth and query responsibly, ily ππ¦β¨
π¦ where this page comes from
- fedora 44: perl-Net-RDAP 0.43-1.fc44 Β· BSD-2-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms