Page 1 of 1

Trouble connecting to home network (Mac)

Posted: Mon Aug 15, 2022 7:34 pm
by danboc
Hello,

I have gone ahead and setup OpenVPN cloud as best I could but can't seem to access home network devices. My setup:
- Unattended MacBook Air setup as the connector; connector enabled and status is <green> on portal
- I setup a network on the portal (not a host) with a 10.0.0.0/24 subnet route
- Installed client on my iPhone and enabled VPN; appears connected on portal

I then try to connect to a home device located at http://10.0.0.150 from my iPhone but it does not connect :(

Notes:
- when setting up the connector on the Mac, and enabling the NAT (using pfctl) I set the route to utun2, as utun0 failed. I am not sure if this is an issue.
- I have made no changes to the home router: no port-forwarding or anything; do I need to?
- I haven't touched the WPC subnet definition

What am I missing? Any help would be appreciated!

Re: Trouble connecting to home network (Mac)

Posted: Tue Aug 16, 2022 4:39 pm
by danboc
Just to add: I've read and searched everything I could... most of the help relates to OpenVPN server installed locally. I did not find answers to the below.I'm a VPN newb. It seemed straight forward to set this up, but alas its failing.

I'll also add: I've tried replacing the subnet rout with a DNS route (per the OpenVPN manual) and that didn't work either.

So any mentoring would be welcomed! Thanks!

Re: Trouble connecting to home network (Mac)

Posted: Tue Aug 16, 2022 6:52 pm
by danboc
So 2 hours later:
I believe the problem is with the NATing on the MacBook (the connector on the home network). Traceroute gets me to the connector but then it dies.

I'm following this OpenVPN guide: https://openvpn.net/cloud-docs/enabling ... -on-macos/ but when loading the rules from the file I get <rule expands to no valid combinations> (on utun0). I have multiple utun interfaces (0-7). How do I know which to route from? What should I look for?

Re: Trouble connecting to home network (Mac)

Posted: Thu Sep 01, 2022 3:16 pm
by openvpn_inc
Hi,

Your "pf-nat.conf" file should contain below:
nat on en0 from utun0:network to any -> (en0)

where;utun0 is the tunnel interface that obtains tunnel IP address

Regards,
.\kionci

Re: Trouble connecting to home network (Mac)

Posted: Fri Sep 02, 2022 1:44 pm
by danboc
Thank you for the reply!!

I am getting the following error: no IP address found for utun0:network

Do I need to replace utun0:network with the IP address from the connector?

Re: Trouble connecting to home network (Mac)

Posted: Sun Sep 04, 2022 4:42 pm
by danboc
Solved! The connector logs lost the interface being used. For me it was utun2.

Re: Trouble connecting to home network (Mac)

Posted: Tue Dec 20, 2022 10:12 am
by preetech
Hi @danboc
I am trying to do the same stuff and looks like after connecting the connector, my utun7 gets the ipaddress. But then when I try running the command to sudo pfctl -f pf-nat.conf -e, I am always getting this error
pf-nat.conf:1: syntax error
pfctl: Syntax error in config file: pf rules not loaded

Below is the content in the file :
nat on en0 from utun7:network to any -> (en0)

Any advice how you made it work

Re: Trouble connecting to home network (Mac)

Posted: Wed Dec 21, 2022 7:59 am
by danboc
Hi @preetech,

I couldn't get it to work on account of my router not having p2p NAT. So VPN Cloud hits the router and then gets lost...I don't have any plans to replace the router so I just gave up for now. Using AnyDesk for remote access...