rfc883.txt
来自「RFC 的详细文档!」· 文本 代码 · 共 1,582 行 · 第 1/5 页
TXT
1,582 行
rightmost label of QNAME. If one or more hits are found the name
server either returns all of the hits (CQUERYM) or uses the
closeness criteria described below to eliminate all but one of the
matches (CQUERYU).
Mockapetris [Page 20]
RFC 883 November 1983
Domain Names - Implementation and Specification
If a CQUERYU query encounters multiple hits, it uses the following
sequence of rules to discard multiple hits:
1. Discard candidates that have more labels than others. Since
all candidates start with the partial name and end with the
target name, this means that we select those entries that
require the fewest number of added labels. For example, a host
search with a target of "ISI.ARPA" and a partial name of "A"
will select A.ISI.ARPA in preference to A.IBM-PCS.ISI.ARPA.
2. If partial label matching was used, discard those labels which
required more characters to be added. For example, a mailbox
search for partial "X" and target "ISI.ARPA" would prefer
XX@ISI.ARPA to XYZZY@ISI.ARPA.
If multiple hits are still present, return all hits.
Completion query mappings are not guaranteed to be unique or
complete because the domain system does not have any internal
mechanism for determining authority from a partial domain name
that parallels the capability for determining authority as a
function of a complete domain name. In general, resolvers will be
configured to direct completion queries to a name server which is
known to have the desired information.
When a name server processes a completion query, it either
returns:
1. An answer giving zero, one, or more possible completions.
2. an error response with Not Implemented (NI) set.
Mockapetris [Page 21]
RFC 883 November 1983
Domain Names - Implementation and Specification
Completion query and response example
Suppose that the completion service was used by a TELNET program
to allow a user to specify a partial domain name for the desired
host. Thus a user might ask to be connected to "B". Assuming
that the query originated from an ISI machine, the query might
look like:
+-----------------------------------------+
Header | OPCODE=CQUERYU, ID=409 |
+-----------------------------------------+
Question | QTYPE=A, QCLASS=IN, QNAME=B |
+-----------------------------------------+
Answer | <empty> |
+-----------------------------------------+
Authority | <empty> |
+-----------------------------------------+
Additional | ISI.ARPA NULL IN |
+-----------------------------------------+
The partial name in the query is "B", the mappings of interest are
ARPA Internet address records, and the target domain is ISI.ARPA.
Note that NULL is a special type of NULL resource record that is
used as a placeholder and has no significance; NULL RRs obey the
standard format but have no other function.
The response to this completion query might be:
+-----------------------------------------+
Header | OPCODE=RESPONSE, ID=409 |
+-----------------------------------------+
Question | QTYPE=A, QCLASS=IN, QNAME=B |
+-----------------------------------------+
Answer | B.ISI.ARPA A IN 10.3.0.52 |
+-----------------------------------------+
Authority | <empty> |
+-----------------------------------------+
Additional | ISI.ARPA NULL IN |
+-----------------------------------------+
This response has completed B to mean B.ISI.ARPA.
Mockapetris [Page 22]
RFC 883 November 1983
Domain Names - Implementation and Specification
Another query might be:
+-----------------------------------------+
Header | OPCODE=CQUERYM, ID=410 |
+-----------------------------------------+
Question | QTYPE=A, QCLASS=IN, QNAME=B |
+-----------------------------------------+
Answer | <empty> |
+-----------------------------------------+
Authority | <empty> |
+-----------------------------------------+
Additional | ARPA NULL IN |
+-----------------------------------------+
This query is similar to the previous one, but specifies a target
of ARPA rather than ISI.ARPA. It also allows multiple matches.
In this case the same name server might return:
+-----------------------------------------+
Header | OPCODE=RESPONSE, ID=410 |
+-----------------------------------------+
Question | QTYPE=A, QCLASS=IN, QNAME=B |
+-----------------------------------------+
Answer | B.ISI.ARPA A IN 10.3.0.52 |
| - |
| B.BBN.ARPA A IN 10.0.0.49 |
| - |
| B.BBNCC.ARPA A IN 8.1.0.2 |
+-----------------------------------------+
Authority | <empty> |
+-----------------------------------------+
Additional | ARPA NULL IN |
+-----------------------------------------+
This response contains three answers, B.ISI.ARPA, B.BBN.ARPA, and
B.BBNCC.ARPA.
Mockapetris [Page 23]
RFC 883 November 1983
Domain Names - Implementation and Specification
Recursive Name Service
Recursive service is an optional feature of name servers.
When a name server receives a query regarding a part of the name
space which is not in one of the name server's zones, the standard
response is a message that refers the requestor to another name
server. By iterating on these referrals, the requestor eventually
is directed to a name server that has the required information.
Name servers may also implement recursive service. In this type
of service, a name server either answers immediately based on
local zone information, or pursues the query for the requestor and
returns the eventual result back to the original requestor.
A name server that supports recursive service sets the Recursion
Available (RA) bit in all responses it generates. A requestor
asks for recursive service by setting the Recursion Desired (RD)
bit in queries. In some situations where recursive service is the
only path to the desired information (see below), the name server
may go recursive even if RD is zero.
If a query requests recursion (RD set), but the name server does
not support recursion, and the query needs recursive service for
an answer, the name server returns a "Not Implemented" (NI) error
code. If the query can be answered without recursion since the
name server is authoritative for the query, it ignores the RD bit.
Because of the difficulty in selecting appropriate timeouts and
error handling, recursive service is best suited to virtual
circuits, although it is allowed for datagrams.
Recursive service is valuable in several special situations:
In a system of small personal computers clustered around one or
more large hosts supporting name servers, the recursive
approach minimizes the amount of code in the resolvers in the
personal computers. Such a design moves complexity out of the
resolver into the name server, and may be appropriate for such
systems.
Name servers on the boundaries of different networks may wish
to offer recursive service to create connectivity between
different networks. Such name servers may wish to provide
recursive service regardless of the setting of RD.
Name servers that translate between domain name service and
some other name service may wish to adopt the recursive style.
Implicit recursion may be valuable here as well.
Mockapetris [Page 24]
RFC 883 November 1983
Domain Names - Implementation and Specification
These concepts are still under development.
Mockapetris [Page 25]
RFC 883 November 1983
Domain Names - Implementation and Specification
Header section format
+-----------------------------------------------+
| |
| ***** WARNING ***** |
| |
| The following format is preliminary and is |
| included for purposes of explanation only. In |
| particular, the size and position of the |
| OPCODE, RCODE fields and the number and |
| me
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?