Skip to content

Unify hopping and regular API

Max B requested to merge maxb/unify-startup into main

We want the client to have a unified API rather than being a socks server for "regular" mode and a transparent UDP proxy for "hopping" mode.

We chose to move to the transparent UDP proxy because socks+UDP support is missing/not particularly reliable.

On the client side it's simplest for the "regular" mode to be conceptually a "hopping" client that only has a single IP+port endpoint and doesn't bother to ever "hop" to any other endpoint. In that way we can go ahead and remove the other code path.

On the server side we do a similar thing, renaming the "HopServer" to "UDPServer" and depending on whether hopping is enabled we listen on a single port or many.

We leave the TCP server for now because our introducer code uses the obfsvpn.NewDialerFromCert method to create a dialer which depends on an obfsvpn server endpoint running on TCP mode.

Note that the client API (and FFI API) have changed so any upstream libraries need to reflect those changes.

ALSO: the openvpn client config has changed, including the protocol, the remote, and the removal of the socks parameters.

Edited by Max B

Merge request reports