Opened 3 years ago

Closed 3 years ago

#22937 closed defect (fixed)

Clarify how resolved values are encoded in cells

Reported by: teor Owned by:
Priority: Medium Milestone: Tor: 0.3.2.x-final
Component: Core Tor/Tor Version:
Severity: Normal Keywords: tor-spec, easy, doc, spec
Cc: Actual Points:
Parent ID: #18856 Points:
Reviewer: Sponsor:


T1. Is length 0 for error types?
T2. IPv4 and IPv6 addresses are in network byte order
T3. Hostnames are in standard DNS order (we might not need to say this)
T4. TTLs are left out in NETINFO cells

   To find the address associated with a hostname, the OP sends a
   RELAY_RESOLVE cell containing the hostname to be resolved with a NUL
   terminating byte. (For a reverse lookup, the OP sends a RELAY_RESOLVE
   cell containing an address.) The OR replies with a
   RELAY_RESOLVED cell containing any number of answers. Each answer is
   of the form:

       Type   (1 octet)
       Length (1 octet)
       Value  (variable-width)
       TTL    (4 octets)
   "Length" is the length of the Value field.
   "Type" is one of:
      0x00 -- Hostname
      0x04 -- IPv4 address
      0x06 -- IPv6 address
      0xF0 -- Error, transient
      0xF1 -- Error, nontransient

    If any answer has a type of 'Error', then no other answer may be given.

    For backward compatibility, if there are any IPv4 answers, one of those
    must be given as the first answer.

    The RELAY_RESOLVE cell must use a nonzero, distinct streamID; the
    corresponding RELAY_RESOLVED cell must use the same streamID.  No stream
    is actually created by the OR when resolving the name.

Child Tickets

Change History (2)

comment:1 Changed 3 years ago by nickm

Keywords: spec added

Add 'spec' keyword to items that are just spec fixes. These can land after the feature-freeze.

comment:2 Changed 3 years ago by nickm

Resolution: fixed
Status: newclosed

9f390c36febd23 should fix this.

Note: See TracTickets for help on using tickets.