tholian-network / stealth

:rocket: Stealth - Secure, Peer-to-Peer, Private and Automateable Web Browser/Scraper/Proxy
GNU General Public License v3.0
1.04k stars 301 forks source link

Stealth: SOCKS Connection Refactor #74

Closed cookiengineer closed 3 years ago

cookiengineer commented 3 years ago

The SOCKS Connection needs to be refactored and implemented with an external Packet Parser like all the wireformats and protocols.

cookiengineer commented 3 years ago

The API of the SOCKS wireformat has been changed.

These things have to be changed accordingly in the new Proxy implementation.

cookiengineer commented 3 years ago

The SOCKS Connection API has changed. Now the SOCKS Connection does not fire a @tunnel event and also no @connect event anymore, in order to make the usage of external network protocols easier.

DNSH based Connections have to use the dnsh:// protocol scheme in the URL from now on, otherwise there'll be a conflict with https://. But, this allows now to generically route almost all network protocols through TOR with ICMP and DNS being the exceptions as they're not TCP based protocols.

TOR's SOCKS proxy doesn't support UDP in a failsafe manner (and therefore technically is a SOCKS4 proxy featureset, not SOCKS5, but who cares!?). Needs further debugging what's missing and why TOR's proxy fails with that use case.