Opened 6 years ago

Closed 6 years ago

#13314 closed enhancement (fixed)

Send back more SOCKS5 errors where appropriate.

Reported by: yawning Owned by: yawning
Priority: Medium Milestone: Tor: 0.2.6.x-final
Component: Core Tor/Tor Version: Tor: unspecified
Severity: Keywords: tor-client, easy, socks
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:


As a follow up to #12971, our SOCKS5 code can now send back specific errors in response to requests fairly easily. A quick glance through the code suggests that the following cases (at a minimum) should be changed to do the right thing:

  • Invalid/malformed address (SOCKS5_ADDRESS_TYPE_NOT_SUPPORTED, SOCKS5_GENERAL_ERROR, SOCKS5_NOT_ALLOWED depending on the case)
  • CONNECT command while SafeSocks is set to an IP address (SOCKS5_NOT_ALLOWED)

One could argue that #11138 would magically fix these things as well, but since returning errors is a one line addition (and the unit tests) per case, there's no reason not to make the changes now.

Child Tickets

Change History (3)

comment:1 Changed 6 years ago by yawning

Keywords: tor-client easy added
Status: newneeds_review

This covers most of the easy to hit ones.

comment:2 Changed 6 years ago by nickm

Milestone: Tor: 0.2.6.x-final

comment:3 Changed 6 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

lgtm. Merging. Thanks!

Note: See TracTickets for help on using tickets.