Mac OS X Internet Sharing

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

panosru

Posts: 2
Joined: Sat Jul 04, 2009 9:23 am

Post by panosru » Sat Jul 04, 2009 9:29 am
Hello, I'm trying Viscosity to connect to a VPN server because I couldn't connect to the VPN through the building Mac OS X VPN network interfaces.

Well I successfully connected to the VPN but my problem is that I have setup Internet Sharing into my Mac OS X that is share my connection from Ethernet to Airport so actually I share my Ethernet connection through my Airport (WiFi).

My girlfriend's laptop runs Windows Vista she can connect with me through WiFi and we can share files but she cannot connect to internet as long as I'm connected to VPN through Viscosity.

thanks in advance :)

James

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

Post by James » Sun Jul 05, 2009 11:45 am
Hi panosru,

It sounds like that once you are connected to your VPN, the VPN network interface becomes the default interface for network traffic (i.e. all Internet traffic flows through the VPN instead of directly through your Ethernet connection). However Internet Sharing is only able to share the Ethernet interface, not the VPN interface.

Unfortunately there is no simple solution for this. I'd recommend trying either of the following:

1. Manually setup NAT (the technology behind Internet Sharing) on the Mac so the VPN interface is shared. This requires some technical knowledge, however there are quite a few tools available that should help you do this:

http://www.hanynet.com/waterroof/
http://personalpages.tds.net/~brian_hil ... tress.html
http://www.sunprotectingfactory.com/ind ... 2&Itemid=9

2. Use the Windows laptop to share the Internet connection instead. That way you can connect to your VPN without needing to worry about it affecting the sharing.

Regards,
James
James Bekkema
Viscosity Developer

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

panosru

Posts: 2
Joined: Sat Jul 04, 2009 9:23 am

Post by panosru » Sun Jul 05, 2009 9:37 pm
Hello James,

Thank you for your reply,

I downloaded Waterroof but didn't figure out a lot of things..

About the #2 recomendation well yes I tryied it but I really need to share internet connection from Mac to Windows..

Why the systems recognizes Viscosity as default network interface?

James

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

Post by James » Mon Jul 06, 2009 6:04 pm
Why the systems recognizes Viscosity as default network interface?
Well it is only a hypothesis, so it may not be the case. However the VPN interface can become the default route for traffic if the "Send all traffic over VPN connection" is checked (under the Networking tab when editing your connection), or if your VPN server is automatically setting this option for you (almost all commercial VPN providers will enable this option).

Cheers,
James
James Bekkema
Viscosity Developer

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

themesser

Posts: 2
Joined: Tue Jun 21, 2011 2:01 pm

Post by themesser » Tue Jun 21, 2011 2:10 pm
hi james, can you tell how you accomplished that using waterroof ?
i can see my connection to the vpn server in the connection list, but don't know at all what to do in the "NAT setup" but when i click "start NAT" an error pops up. Is there something to configure ?
thanks

James

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

Post by James » Wed Jun 22, 2011 1:35 pm
Hi themesser,

You'll need to enter the VPN connection's interface (e.g. tun0, tap0, etc) into the "NAT Interface (WAN)" field before clicking the "Start NAT" button.

Cheers,
James
James Bekkema
Viscosity Developer

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

edgarchinchilla

Posts: 2
Joined: Sat Jan 07, 2012 7:20 pm

Post by edgarchinchilla » Sat Jan 07, 2012 7:24 pm
Hi James, im using this post as a guideline to resolve my own issue but i dont know where to take the "VPN connection's interface (e.g. tun0, tap0, etc) " to enter it, please help. Thank you.

edgarchinchilla

Posts: 2
Joined: Sat Jan 07, 2012 7:20 pm

Post by edgarchinchilla » Sat Jan 07, 2012 8:00 pm
I entered ovpn### in that field (WAN) and it gives me this error: Cant start NAT daemon, sorry. natd: cannot open config file / etc/nat.conf: No such file or directory. Please verify your settings.

James

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

Post by James » Sun Jan 08, 2012 5:26 am
Hi edgarchinchilla,

You'll need to view the list of network interfaces while your VPN connection is connected, and pick out the appropriate one. OpenVPN network interfaces start with either "tap" or "tun" depending on how it is configured. So you're looking for something like "tap0", or "tap1", or "tun0", or "tun1" etc.

Cheers,
James
James Bekkema
Viscosity Developer

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

Bullitt

Posts: 1
Joined: Thu Jan 19, 2012 9:27 am

Post by Bullitt » Thu Jan 19, 2012 9:52 am
Hi, I have viscosity set up on my mac mini (connected via ethernet), and would like to set up a separate wireless network that routes all traffic through the VPN. It seems that I am trying to do what the OP is trying to get rid of. I have set up internet sharing, but am not able to access the VPN connection (but I am able to connect to the mac mini).

So the setup I am looking for is something like:

DSL modem -(ethernet)> Time Capsule -(ethernet)> Mac Mini -(wifi)> multiple devices (PS3, android phone, etc).

I note that a suggested fix was to manually setup NAT on the Mac so the VPN interface is shared. I have poked around WaterRoof, and have not been able to figure out how to get this done (I'm a networking novice). Does anyone know of a step by step guide for setting something like this up?

B
13 posts Page 1 of 2