Opened 14 months ago

Last modified 7 hours ago

#30123 assigned defect

MAPADDRESS result can mix status codes

Reported by: catalyst Owned by: neel
Priority: Medium Milestone: Tor: unspecified
Component: Core Tor/Tor Version: Tor: 0.4.0.1-alpha
Severity: Normal Keywords: tor-control, tor-spec
Cc: neel Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

When using MAPADDRESS at the control port, mixing valid and invalid address mappings can result in a mixture of status codes, contrary to Section 2.3, which says:

  Multiple lines in a single reply from Tor to the controller are guaranteed to
  share the same status code.

Example:

mapaddress xxx=@@@ 0.0.0.0=bogus1.google.com
512-syntax error: invalid address '@@@'
250 127.199.80.246=bogus1.google.com

It's not clear what the right thing to do here is. Checking the syntax first might help, but maybe it's possible to run into resource exhaustion for some requested mappings and not others?

Child Tickets

Change History (2)

comment:1 Changed 14 months ago by nickm

Hm. My first thought is that it is indeed possible for this to succeed in part but fail in part. Let's amend the specification so that it says "unless documented otherwise", and then document that MAPADDRESS does this.

comment:2 Changed 7 hours ago by neel

Cc: neel added
Owner: set to neel
Status: newassigned
Note: See TracTickets for help on using tickets.