Port forwarding

Got a problem with Viscosity or need help? Ask here!

Revali

Posts: 3
Joined: Sat Jun 18, 2022 11:20 pm

Post by Revali » Sat Jun 18, 2022 11:24 pm
Hey,

I use Viscosity in combination with CyberGhost VPN and have set up a port forwarding for SSH on my router and Mac. It all works as long as I don't connect the Mac to the VPN, but unfortunately it stops working as soon as I connect my Mac to the VPN. How can I fix this?

Kind regards,
Revali

James

User avatar
Posts: 2182
Joined: Thu Sep 04, 2008 9:27 pm

Post by James » Mon Jun 20, 2022 5:29 am
Hi Revali,

If you have setup port forwarding on your router (port forwarding a port from your router to your Mac), then you can try adding a route to your VPN connection to instruct that traffic to your router's internal IP address should go through your normal network connection. Please see:
https://www.sparklabs.com/support/kb/ar ... al-network

Cheers,
James
James Bekkema
Viscosity Developer

Web: http://www.sparklabs.com
Support: http://www.sparklabs.com/support
Twitter: http://twitter.com/sparklabs

Revali

Posts: 3
Joined: Sat Jun 18, 2022 11:20 pm

Post by Revali » Mon Jun 20, 2022 7:54 am
Hey,

thanks, I already read the article, but unfortunately it doesn't really help me if the clients from which a connection to the SSH server is established have dynamic IP addresses from different subnets. As far as I found out this only works if the clients (not the SSH server on the Mac that is also running Viscosity) have a static IP.

Kind regards,
Revali

Revali

Posts: 3
Joined: Sat Jun 18, 2022 11:20 pm

Post by Revali » Wed Jun 29, 2022 7:38 pm
Hey,

I would love to get an answer or at least an idea or possible solution as to what to try or do instead. Otherwise I can really leave the support here.

Kind regards,
Revali

James

User avatar
Posts: 2182
Joined: Thu Sep 04, 2008 9:27 pm

Post by James » Thu Jun 30, 2022 9:12 pm
I'm afraid there isn't much you can do from a VPN perspective, as it's happening outside of the VPN. A couple of ideas:

1. SSH into your Mac via its VPN's IP address. If the IP address isn't publicly accessible, this will likely mean port forwarding on the OpenVPN server. If your VPN address isn't static you may need to consider setting up something like dynamic DNS.

2. Have your router perform NAT on the LAN interface for the port forwarded SSH connections only. This will make it look like they come from your router's IP address, and so it's easy to route outside of the VPN connection.

Cheers,
James
James Bekkema
Viscosity Developer

Web: http://www.sparklabs.com
Support: http://www.sparklabs.com/support
Twitter: http://twitter.com/sparklabs
5 posts Page 1 of 1