One document matched: draft-ietf-weirds-using-http-05.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rfc SYSTEM "http://xml.resource.org/authoring/rfc2629.dtd"
[
<!ENTITY RFC2119 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml'>
<!ENTITY RFC2616 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.2616.xml'>
<!ENTITY RFC3912 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.3912.xml'>
<!ENTITY RFC3986 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.3986.xml'>
<!ENTITY RFC3987 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.3987.xml'>
<!ENTITY RFC4627 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.4627.xml'>
<!ENTITY RFC5234 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.5234.xml'>
<!ENTITY RFC5890 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.5890.xml'>
<!ENTITY RFC6585 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.6585.xml'>
<!ENTITY RFC6839 PUBLIC ''
'http://xml.resource.org/public/rfc/bibxml/reference.RFC.6839.xml'>
]>
<?rfc toc="yes"?>
<?rfc sortrefs="yes"?>
<rfc category="std" docName="draft-ietf-weirds-using-http-05" ipr="trust200902">
<front>
<title abbrev="RDAP over HTTP">
HTTP usage in the Registration Data Access Protocol (RDAP)
</title>
<author fullname="Andrew Lee Newton" initials="A.L." surname="Newton">
<organization abbrev="ARIN">American Registry for Internet Numbers</organization>
<address>
<postal>
<street>3635 Concorde Parkway</street>
<city>Chantilly</city>
<region>VA</region>
<country>US</country>
<code>20151</code>
</postal>
<email>andy@arin.net</email>
<uri>http://www.arin.net</uri>
</address>
</author>
<author fullname="Byron J. Ellacott" initials="B.J." surname="Ellacott">
<organization abbrev="APNIC">Asia Pacific Network Information Center</organization>
<address>
<postal>
<street>6 Cordelia Street</street>
<city>South Brisbane</city>
<country>Australia</country>
<code>QLD 4101</code>
</postal>
<email>bje@apnic.net</email>
<uri>http://www.apnic.net</uri>
</address>
</author>
<author initials="N." surname="Kong" fullname="Ning Kong">
<organization abbrev="CNNIC">
China Internet Network Information Center
</organization>
<address>
<postal>
<street>4 South 4th Street, Zhongguancun, Haidian District </street>
<country>China</country>
<code>100190</code> <city>Beijing</city>
</postal>
<phone>+86 10 5881 3147</phone>
<email>nkong@cnnic.cn</email>
</address>
</author>
<date/>
<abstract>
<t>
This document is one of a collection that together describe the
Registration Data Access Protocol (RDAP). It describes
how RDAP is transported using the Hypertext Transfer Protocol (HTTP).
</t>
</abstract>
</front>
<middle>
<section title="Introduction">
<t>
This document describes the usage of HTTP for Registration Data
Directory Services. The goal of this document is to tie
together usage patterns of HTTP into a common profile applicable to
the various types of Directory Services serving Registration Data
using RESTful practices. By giving the various Directory Services
common behavior, a single client is better able to retrieve data from
Directory Services adhering to this behavior.
</t>
<t>
The registration data expected to be presented by this service is
Internet resource registration data - registration of domain names
and Internet number resources. This data is typically provided by
<xref target="RFC3912">WHOIS</xref> services, but the WHOIS protocol is
insufficient to modern registration data service requirements. A
replacement protocol is expected to retain the simple transactional
nature of WHOIS, while providing a specification for queries and
responses, redirection to authoritative sources, support for
Internationalized Domain Names (IDNs, <xref target="RFC5890"/>), and
support for localized registration data such as addresses and
organisation or person names.
</t>
<t>
In designing these common usage patterns, this document introduces
considerations for a simple use of HTTP. Where complexity may reside,
it is the goal of this document to place it upon the server and to keep
the client as simple as possible. A client implementation should be
possible using common operating system scripting tools.
</t>
<t>
This is the basic usage pattern for this protocol:
<list style="numbers">
<t>A client issues an HTTP query using GET. As an example, a query for
the network registration 192.0.2.0 might be http://example.com/ip/192.0.2.0.</t>
<t>If the receiving server has the information for the query, it examines
the Accept header field of the query and returns a 200 response with a response
entity appropriate for the requested format.</t>
<t>If the receiving server does not have the information for the query but does
have knowledge of where the information can be found, it will return a
redirection response (3xx) with the Location: header field containing an HTTP(S) URL
(Uniform Resource Locator) pointing
to the information or another server known to have knowledge of the location of
the information. The client is expected to re-query using that HTTP URL.</t>
<t>If the receiving server does not have the information being requested and
does not have knowledge of where the information can be found, it returns
a 404 response.</t>
<t>If the receiving server will not answer a request for policy reasons, it will
return an error response (4xx) indicating the reason for giving no answer.</t>
</list>
</t>
<t>
It is important to note that it is not the intent of this document to redefine the
meaning and semantics of HTTP. The purpose of this document is to clarify the use
of standard HTTP mechanisms for this application.
</t>
</section>
<section title="Terminology">
<t>
The key words "MUST", "MUST NOT", "REQUIRED",
"SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT",
"RECOMMENDED", "MAY", and "OPTIONAL" in this document
are to be interpreted as described in RFC 2119 <xref target="RFC2119"/>.
</t>
<t>
As is noted in <xref target="SAC-051">SSAC Report on WHOIS Terminology and Structure</xref>,
the term "WHOIS" is overloaded, often referring to a protocol, a service and data.
In accordance with <xref target="SAC-051"></xref>, this document describes the base
behavior for a Registration Data Access Protocol (RDAP).
<xref target="SAC-051"></xref> describes a protocol profile of RDAP for Domain Name
Registries (DNRs), the Domain Name Registration Data Access Protocol (DNRD-AP).
</t>
<t>
In this document, an RDAP client is an HTTP User Agent performing an RDAP query, and
an RDAP server is an HTTP server providing an RDAP response. RDAP query and response
formats are described in other documents in the collection of RDAP specifications, while
this document describes how RDAP clients and servers use HTTP to exchange queries and
responses.
</t>
</section>
<section title="Design Intents">
<t>
There are a few design criteria this document attempts to meet.
</t>
<t>
First, each query is meant to return either zero or one result. With the maximum
upper bound being set to one, the issuance of redirects is simplified to the
known query/response model used by <xref target="RFC2616">HTTP</xref>.
Should an entity contain more than one result, some of which are better served by
other servers, the redirection model becomes much more complicated.
</t>
<t>
Second, multiple response formats are supported by this protocol. At present the
IETF Web Extensible Internet Data Service (WEIRDS) working group is defining
only a <xref target="RFC4627">JSON</xref>
response format, but server operators may use other data formats when those
formats are requested.
</t>
<t> Third, this protocol is intended to be able to make use of the range of mechanisms
available for use with HTTP. HTTP offers a number of mechanisms not described further
in this document. Operators are able to make use of these mechanisms according to
their local policy, including cache control, authorization, compression, and
redirection. HTTP also benefits from widespread investment in scalability,
reliability, and performance, and widespread programmer understanding of client
behaviours for RESTful web services, reducing the cost to deploy Registration Data
Directory Services and clients.
</t>
</section>
<section title="Queries">
<section title="Accept Header" anchor="accept_header">
<t>
RDAP clients MUST include an Accept: header field specifying
application/rdap+json, application/json, or both. Servers receiving an
RDAP request MUST return an entity with Content-Type application/rdap+json.
</t>
<t>
This specification does not define the responses a server returns to
a request with any other media types in the Accept: header field, or with no
Accept: header field. One possibility would be to return a response in
a media type suitable for rendering in a web browser.
</t>
</section>
<section title="Query Parameters" anchor="parameters">
<t>
Servers MUST ignore unknown query parameters. Use of unknown query
parameters for cache-busting is described in <xref target="cache-busting"></xref>.
</t>
</section>
</section>
<section title="Types of HTTP Response" anchor="http_responses">
<t>
This section describes the various types of responses a server may send to a client.
While no standard HTTP response code is forbidden in usage, at a minimum clients
SHOULD understand the response codes described in this section as they will be
in common use by servers. It is expected that
usage of response codes and types for this application not defined here will be
described in subsequent documents.
</t>
<section title="Positive Answers">
<t>
If a server has the information requested by the client and wishes to respond
to the client with the information according to its policies, it encodes
the answer in the format most appropriate according to the standard and defined
rules for processing the HTTP Accept header field, and return that answer in
the body of a 200 response.
</t>
</section>
<section title="Redirects">
<t>
If a server wishes to inform a client that the answer to a given query can be found
elsewhere, it MUST return a 301 response code to indicate a permanent move, or
a 307 response code to indicate a non-permanent redirection, and include an HTTP(s)
URL in the Location: header field. The client is expected to issue a subsequent request
to satisfy the original query using the given URL without any processing of the URL.
In other words, the server is to hand back a complete URL and the client should not
have to transform the URL to follow it.
</t>
<t>
For this application, such an example of a permanent move might be a Top Level Domain
(TLD) operator informing a client the information being sought can be found with
another TLD operator (i.e. a query for the domain bar in foo.example is found at
http://foo.example/domain/bar).
</t>
<t>
For example, if the client sends http://serv1.example.com/weirds/domain/example.com,
the server redirecting to https://serv2.example.net/weirds2/ would set the
Location: field to the value: https://serv2.example.net/weirds2/domain/example.com.
</t>
</section>
<section title="Negative Answers">
<t>
If a server wishes to respond that it has no information regarding the query,
it MUST return a 404 response code. Optionally, it MAY include additional
information regarding the negative answer in the HTTP entity body.
</t>
<t>
If a server wishes to inform the client that information about the query
is available, but cannot include the information in the response to the
client for policy reasons, the server MUST respond with an appropriate
response code out of HTTP's 4xx range. Clients MAY retry the query based
on the respective response code.
</t>
</section>
<section title="Malformed Queries">
<t>
If a server receives a query which it cannot interpret as an RDAP query, it MUST return
a 400 response code. Optionally, it MAY include additional information regarding
this negative answer in the HTTP entity body.
</t>
</section>
<section title="Rate Limits" anchor="rate-limits">
<t>
Some servers apply rate limits to deter address scraping and other
abuses. When a server declines to answer a query due to rate limits,
it SHOULD return a 429 response code as described in <xref target="RFC6585"></xref>.
A client that receives a 429 response SHOULD decrease its query rate,
and honor the Retry-After header field if one is present.
</t>
<t>
Note that this is not a defense against denial-of-service attacks,
since a malicious client could ignore the code and continue to send
queries at a high rate. A server might use another response code if
it did not wish to reveal to a client that rate limiting is the reason
for the denial of a reply.
</t>
</section>
<section title="Cross-Origin Resource Sharing" anchor="cors">
<t>
When responding to queries, it is RECOMMENDED that servers use the
Access-Control-Allow-Origin header field, as specified by <xref target="W3C.CR-cors-20130129"/>.
</t>
</section>
</section>
<section title="Extensibility" anchor="extensibility">
<t>
For extensibility purposes, this document defines an IANA registry for prefixes
used in <xref target="RFC4627">JSON</xref> data serialization and URI path
segments (see <xref target="iana_considerations"></xref>).
</t>
<t>
Prefixes and identifiers SHOULD only consist of the alphabetic ASCII characters A through Z in
both uppercase and lowercase, the numerical digits 0 through 9, underscore
characters, and SHOULD NOT begin with
an underscore character, numerical digit or the characters "xml". The following
describes the production of JSON names in <xref target="RFC5234">ABNF</xref>.</t>
<figure anchor="json_name_abnf">
<preamble>
ABNF for JSON names
</preamble>
<artwork>
name = ALPHA *( ALPHA / DIGIT / "_" )
</artwork>
</figure>
<t> This restriction
is a union
of the Ruby programming language identifier syntax and the XML element name
syntax and has two purposes. First, client implementers using modern programming
languages such as Ruby or Java can use libraries that automatically promote JSON
names to first order object attributes or members.
Second, a clean mapping between JSON and XML is easy to accomplish using these
rules.
</t>
</section>
<section title="Security Considerations" anchor="security_considerations">
<t>
This document does not pose strong security requirements to the RDAP
protocol. However, it does not restrict against the use of security
mechanisms offered by the HTTP protocol.
</t>
<t>
This document made recommendations for server implementations against
denial-of-service (<xref target="rate-limits"/>) and interoperability with existing
security mechanism in HTTP clients (<xref target="cors"/>).
</t>
<t>
Additional security considerations to the RDAP protocol will be covered
in future RFCs documenting specific security mechanisms and schemes.
</t>
</section>
<section title="IANA Considerations" anchor="iana_considerations">
<section title="RDAP Extensions Registry">
<t>
This specification proposes an IANA registry for RDAP extensions. The
purpose of this registry is to ensure uniqueness of extension identifiers.
The extension identifier is used as a prefix in JSON names and as a prefix
of path segments in RDAP URLs.
</t>
<t>
The production rule for these identifiers is specified in <xref target="extensibility"/>.
</t>
<t>
In accordance with RFC5226, the IANA policy for assigning new values shall
be Specification Required: values and their meanings must be documented in
an RFC or in some other permanent and readily available reference, in
sufficient detail that interoperability between independent implementations
is possible.
</t>
<t>
The following is a preliminary template for an RDAP extension registration:
<list style="empty">
<t>Extension identifier: the identifier of the extension</t>
<t>Registry operator: the name of the registry operator</t>
<t>Published specification: RFC number, bibliographical reference or URL
to a permanent and readily available specification</t>
<t>Person & email address to contact for further information:
The names and email addresses of individuals for contact regarding this registry entry
</t>
<t>Intended usage: brief reasons for this registry entry</t>
</list>
</t>
<t>
The following is an example of a registration in the RDAP extension registry:
<list style="empty">
<t>Extension identifier: lunarNic</t>
<t>Registry operator: The Registry of the Moon, LLC</t>
<t>Published specification: http://www.example/moon_apis/rdap</t>
<t>Person & email address to contact for further information:
Professor Bernardo de la Paz <berny@moon.example>
</t>
<t>Intended usage: COMMON</t>
</list>
</t>
</section>
<section title="RDAP Media Type Registration">
<t> This specification registers the "application/rdap+json" media type. <list>
<t>Type name: application</t>
<t>Subtype name: rdap+json</t>
<t>Required parameters: n/a</t>
<t>Encoding considerations: See section 3.1 of <xref target="RFC6839"></xref>.</t>
<t>Security considerations: The media represented by this identifier does not have security considerations beyond that found in section 6 of <xref target="RFC4627"></xref></t>
<t>Interoperability considerations: There are no known interoperability problems regarding this media format.</t>
<t>Published specification: [[ this document ]]</t>
<t>Applications that use this media type: Implementations of the Registration Data Access Protocol (RDAP)</t>
<t>Additional information: This media type is a product of the IETF
WEIRDS working group. The WEIRDS charter, information on the WEIRDS
mailing list, and other documents produced by the WEIRDS working group can
be found at <eref target="https://datatracker.ietf.org/wg/weirds/">https://datatracker.ietf.org/wg/weirds/</eref></t>
<t>Person & email address to contact for further information: Andy Newton
<andy@hxr.us></t>
<t>Intended usage: COMMON</t>
<t>Restrictions on usage: none</t>
<t>Author: Andy Newton</t>
<t>Change controller: IETF</t>
<t>Provisional Registration: No (upon publication of this RFC)</t>
</list>
</t>
</section>
</section>
<section title="Internationalization Considerations">
<section title="URIs and IRIs">
<t>
Clients MAY use <xref target="RFC3987">IRIs</xref> as they see fit, but MUST transform them to
<xref target="RFC3986">URIs</xref> for interaction with RDAP servers.
RDAP servers MUST use URIs in all responses, and clients MAY transform
these URIs to IRIs.
</t>
</section>
<section title="Language Identifiers in Queries and Responses"
anchor="language_identifiers_in_queries_and_responses">
<t>
Under most scenarios, clients requesting data will not signal
that the data be returned in a particular language or script.
On the other hand, when servers return data and have knowledge
that the data is in a language or script, the data SHOULD be
annotated with language identifiers whenever they are available,
thus allowing clients to process and display the data accordingly.
</t>
<t>
The mechanism for including a language identifier in a response
will be defined in subsequent documents describing specific
response formats.
</t>
</section>
<section title="Language Identifiers in HTTP Headers" anchor="language_identifiers_in_http_headers">
<t>
Given the description of the use of language identifiers in
<xref target="language_identifiers_in_queries_and_responses"></xref>,
unless otherwise specified servers SHOULD ignore the
<xref target="RFC2616">HTTP</xref> Accept-Language header field when
formulating HTTP entity responses, so that clients do not conflate
the Accept-Language header with the 'lang' values in the entity
body.
</t>
<t>
However, servers MAY return language identifiers in the
Content-Language header field so as to inform clients of the
intended language of HTTP layer messages.
</t>
</section>
</section>
<section title="Contributing Authors and Acknowledgements">
<t>
John Levine provided text to tighten up the Accept header field usage and the
text for the section on 429 responses.
</t>
<t>
Marc Blanchet provided some clarifying text regarding the use of URLs
with redirects, as well as very useful feedback during WGLC.
</t>
<t>
Normative language reviews were provided by Murray S. Kucherawy and Andrew Sullivan.
</t>
<t>
Jean-Phillipe Dionne provided text for the Security Considerations section.
</t>
</section>
</middle>
<back>
<references title="Normative References">
&RFC2119;
&RFC3986;
&RFC3987;
&RFC2616;
&RFC6585;
&RFC6839;
<reference anchor='W3C.CR-cors-20130129'
target='http://www.w3.org/TR/2013/CR-cors-20130129'>
<front>
<title>Cross-Origin Resource Sharing</title>
<author initials='A.' surname='Kesteren' fullname='Anne van Kesteren'>
<organization />
</author>
<date month='January' day='29' year='2013' />
</front>
<seriesInfo name='World Wide Web Consortium Candidate Recommendation' value='CR-cors-20130129' />
<format type='HTML' target='http://www.w3.org/TR/2012/CR-cors-20130129' />
</reference>
</references>
<references title="Informative References">
<reference anchor="SAC-051">
<front>
<title>SSAC Report on Domain Name WHOIS Terminology and Structure</title>
<author initials="D." surname="Piscitello" role="editor" />
<date day="19" month="September" year="2011"/>
</front>
</reference>
&RFC3912;
&RFC4627;
&RFC5234;
&RFC5890;
</references>
<section title="Protocol Example" anchor="protocol-example">
<t>
To demonstrate typical behaviour of an RDAP client and server, the following
is an example of an exchange, including a redirect. The data in the response
has been elided for brevity, as the data format is not described in this
document.
</t>
<figure>
<preamble>
An example of an RDAP client and server exchange:
</preamble>
<artwork>
Client:
<TCP connect to rdap.example.com port 80>
GET /ip/203.0.113.0/24 HTTP/1.1
Host: rdap.example.com
Accept: application/rdap+json
rdap.example.com:
HTTP 301 Moved Permanently
Location: http://rdap-ip.example.com/ip/203.0.113.0/24
Content-Length: 0
Content-Type: application/rdap+json; charset=UTF-8
<TCP disconnect>
Client:
<TCP connect to rdap-ip.example.com port 80>
GET /ip/203.0.113.0/24 HTTP/1.1
Host: rdap-ip.example.com
Accept: application/rdap+json
rdap-ip.example.com:
HTTP 200 OK
Content-Type: application/rdap+json; charset=UTF-8
Content-Length: 9001
{ ... }
<TCP disconnect>
</artwork>
</figure>
</section>
<section title="Cache Busting" anchor="cache-busting">
<t>
Some <xref target="RFC2616">HTTP</xref> cache infrastructure does not adhere to caching standards
adequately, and could cache responses longer than is intended by the server. To overcome these
issues, clients MAY use an adhoc and improbably used query parameter with a random value of their
choosing. As <xref target="parameters"></xref> instructs servers to ignore unknown parameters,
this is unlikely to have any known side effects.
</t>
<figure>
<preamble>
An example of using an unknown query parameter to bust caches:
</preamble>
<artwork>
http://example.com/ip/192.0.2.0?__fuhgetaboutit=xyz123
</artwork>
</figure>
<t>
Use of an unknown parameter to overcome misbehaving caches is not part of any specification
and is offered here for informational purposes.
</t>
</section>
<section title="Changelog">
<t>
<list style="hanging">
<t hangText="Initial WG -00:">Updated to working group document 2012-September-20</t>
<t hangText="-01">
<list style="symbols">
<t>Updated for the sections moved to the JSON responses draft.</t>
<t>Simplified media type, removed "level" parameter.</t>
<t>Updated 2119 language and added boilerplate.</t>
<t>In section 1, noted that redirects can go to redirect servers as well.</t>
<t>Added <xref target="language_identifiers_in_queries_and_responses"></xref>
and <xref target="language_identifiers_in_http_headers"></xref>.</t>
</list>
</t>
<t hangText="-02">
<list style="symbols">
<t>Added a section on 429 response codes.</t>
<t>Changed Accept header language in section 4.1</t>
<t>Removed reference to the now dead requirements draft.</t>
<t>Added contributing authors and acknowledgements section.</t>
<t>Added some clarifying text regarding complete URLs in the redirect section.</t>
<t>Changed media type to application/rdap+json</t>
<t>Added media type registration</t>
</list>
</t>
<t hangText="-03">
<list style="symbols">
<t>Removed forward reference to draft-ietf-weirds-json-response.</t>
<t>Added reference and recommended usage of CORS</t>
</list>
</t>
<t hangText="-04">
<list style="symbols">
<t>Revised introduction and abstract.</t>
<t>Added negative responses other than 404.</t>
<t>Added security considerations.</t>
<t>Added and corrected references: CORS, RFC3912, RFC3987, RFC5890.</t>
<t>Expanded on first use several acronyms.</t>
<t>Updated 2119 language.</t>
</list>
</t>
<t hangText="-05">
<list style="symbols">
<t>Update the media type registration.</t>
<t>Further explained the SHOULD in section 5.</t>
<t>Split the references into normative and informative.</t>
<t>Other minor fixes.</t>
</list>
</t>
</list>
</t>
</section>
</back>
</rfc>
| PAFTECH AB 2003-2026 | 2026-04-24 00:49:52 |