Currently I am using a reverse proxy with a doman name and my server is internet facing. I have been thinking of getting rid of this. Now, the go-to method seems to be a VPN (or zerotier etc). However, at work, we have a restriction that outside VPN is only allowed to use when the connection to our local network is blocked (no split-tunneling). This is annoying, as realistically I would need to use both at the same time.

So, I started thinking well how about just a proxy and point my browser through it and that should solve it? Then I started looking into proxies and man, I feel like I am more confused now than I was when I started.

Most of the stuff I find on the internet are not about self-hosted proxies but instead some proxy-services in order to circumvent IP blocking etc. Which means that everywhere it is said that proxies are not encrypted and are less secure (or have essentially no security at all) than VPN. But as far as I understood, if I do ssh tunneling then everything will be encrypted just fine?

So what is the actual security difference between the two? I understand that proxies might not be available for all applications and that VPN is generally used for routing all connection and not just a single application. But I am more interested in the security aspect of all this.

TLDR; difference in security between encrypted ssh tunnel (proxy) and a VPN?

  • zoredache@alien.topB
    link
    fedilink
    English
    arrow-up
    2
    ·
    1 year ago

    From the perspective of the stuff you are transporting over the VPN tunnel or ssh proxy. There is not much difference. The payload is encrypted and can’t be seen in transit assuming the underlying VPN, or SSH tunnel is secure.

    There are functionality difference. For an SSH proxy, you have to be able to use a different IP port, or you have to use a browser and configure a SOCKS proxy.

    There are potential performance differences. Last time I tried using them for large transfers, I found the performance over a SOCKS via ssh tended to kinda suck. At least compare with a transfer over a VPN. It is possible this had nothing to do with SSH, and was problems with the browser I was using at the time. But this might not matter much for your usage.

    How things could potentially leak might be different with a proxy. Depending on how you configure SSH and the implementation, your DNS might be resolved on your original DNS servers, or via the tunnel.

  • Flannels9658@lemmy.ml
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Attack surface comparison really. If the only thing exposed is ssh, or your vpn, which do you trust to have fewer vulnerabilities in the exposed authentication system?

    Probably a toss up.

    Now if you’re talking about exposing multiple ssh endpoints vs a single vpn endpoint, that equation changes.

    But a single relatively secure endpoint……difference is pretty negligible.

  • emprahsFury@alien.topB
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    If you tunnel ssh over a tun device then there is no really difference except you obviously have to handle the routing yourself (as you noted). There are differences in the traffic signatures, but we’re not trying to traverse the Great Firewall are we? SSH also adds overhead. SSH channels are resilient and exceptionally managed within SSH but they are still there and adding encapsulation over whatever it is you’re trying to do.