Live data from Hacker News

A userspace WireGuard client that exposes itself as a proxy

github.com

41–50 of 91 posts

Re: A userspace WireGuard client that exposes itself as a proxy

#42

Plug for my own similar project: https://github.com/aramperes/onetun Though admittedly, mine doesn't have SOCKS support, and the code is not as lean as yours!

See also https://github.com/russdill/tunsocks

Basically a kitchen sink for this sort of thing using lwIP for it's IP stack

Re: A userspace WireGuard client that exposes itself as a proxy

#45

Earlier quoted context omitted.

Mullvad's SOCKS proxies are only accessible if you've got the VPN active; they're an additional layer, not an alternative.

That is not true. You can route only traffic to the SOCKS proxies if you choose and nothing else.

What do you mean by that? Mullvad doesn't have a generally accessible socks proxy like PIA does, that works with or without having the VPN on. The proxy is a localhost one for the most part so you can prevent an app from going online without having your vpn client on first.

Re: A userspace WireGuard client that exposes itself as a proxy

#46

Earlier quoted context omitted.

Mullvad's SOCKS proxies are only accessible if you've got the VPN active; they're an additional layer, not an alternative.

That is not true. You can route only traffic to the SOCKS proxies if you choose and nothing else.

Do you have a source for this? Every page on Mullvad I've seen says you need to have the VPN active: https://mullvad.net/en/help/socks5-proxy/

> If you configure your browser, for example, to use the SOCKS5 proxy, it will direct all of your internet access via the proxy which is only accessible through Mullvad. So if you haven't turned on the app, your browser will prevent all internet access and therefore won't leak any information.

Re: A userspace WireGuard client that exposes itself as a proxy

#48

Earlier quoted context omitted.

That is not true. You can route only traffic to the SOCKS proxies if you choose and nothing else.

Do you have a source for this? Every page on Mullvad I've seen says you need to have the VPN active: https://mullvad.net/en/help/socks5-proxy/ > If you configure your browser, for example, to use the SOCKS5 proxy, it will direct all of your internet access via the proxy which is only accessible through Mullvad. So if you haven't turned on the app, your browser will prevent all internet access and therefore won't leak…

You just route 10.64.0.1/24 with wireguard, or 10.124.0.1/24 to access socks proxies on other locations. Then you have socks only mullvad.

Re: A userspace WireGuard client that exposes itself as a proxy

#49
post #38

Earlier quoted context omitted.

SOCKS5 supports UDP, but yeah it does not look like go-socks5 does.

Does Rust support it?

The Rust user-mode WireGuard proxy mentioned upthread does UDP. Netstack does UDP as well; it's just that this particular tool doesn't, yet.

Re: A userspace WireGuard client that exposes itself as a proxy

#50

I love wireguard but my one gripe with it is that its not a true data link layer. You have to give it routing information through an out of band mechanism “AllowedIPs.” One downside is that you can’t have two peers that act as general routers on the same wireguard network. With Ethernet, you can have multiple nodes in the same subnet acting as generic routers, it’s just a matter of sending IP packets to that host. I…

Wireguard is not a link layer (layer 2) tunnel; it is a network (layer 3) tunnel. It operates at the IP layer. You cannot use Wireguard with any non-IP layer3.

AllowedIPs can be disabled if you want; just set it to 0.0.0.0/0. AllowedIPs is needed because netfilter can't "see" which public key an inbound packet is coming from, so by the time a packet gets to netfilter it's too late to accept/reject based on which peer sent it to us.

Post reply on HN