Opened 5 years ago

Closed 5 years ago

#13796 closed enhancement (fixed)

Tor should use getsockname instead of getsockopt on TPROXY based transparent redirects

Reported by: klondike Owned by:
Priority: Medium Milestone: Tor: 0.2.6.x-final
Component: Core Tor/Tor Version:
Severity: Keywords: tor-client 025-backport
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

TPROXY sockets already contain the original information of the socket on getsockname and getsockopt SOL_IP, 0x50 is known to cause problems in some situations when using TPROXY.

Child Tickets

Change History (8)

comment:1 Changed 5 years ago by nickm

Component: - Select a componentTor
Keywords: tor-client 025-backport added
Milestone: Tor: 0.2.6.x-final

comment:2 Changed 5 years ago by nickm

Going to need more information on this one; can you (or anybody) do a patch?

comment:3 Changed 5 years ago by nickm

Status: newneeds_information

comment:4 Changed 5 years ago by nickm

Status: needs_informationneeds_review

See branch "bug13796" on my public repository. Needs somebody to test it.

comment:5 Changed 5 years ago by nickm

klondike says the patch looks good. Hoping somebody can test.

comment:7 Changed 5 years ago by klondike

I have tested these patches against both REDIRECT based forwards and TPROXY based forwards on the GHS router with both ipv6 and ipv4 with this patch on top of tor-0.2.6.2_alpha-r1 (Gentoo ebuild) and they both worked like a charm :)

I reviewed the code and I couldn't find anything strange either. So for me you have a go ahead :) Thanks a lot for the patch!

comment:8 Changed 5 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

Merged; thanks!

Note: See TracTickets for help on using tickets.