Jump to content
Not connected, Your IP: 3.145.163.58
Sign in to follow this  
johntodd1973

connect to vpn client remote server

Recommended Posts

Hello,

 

I'm trying to connect to my sickrage server remotely, outside my local network. And I think I do not understand exactly how to configure it. I'm not an expert about network but understand the basics.

 

Here is my setup :

 

Router DD-WRT

I use openVPN with the policy based routing to 2 of my devices 192.168.1.110 and 192.168.0.111.

So only those clients are acceding internet thru airvpn.

 

Client 192.168.1.110

This client have some servers like Sickrage.

Sickrage is using port 8081

So within my local network all my clients can reach this server by typing 192.168.1.110:8081

 

From outside my lan, obviously client 192.168.1.110:8081 can not be reached.

 

Usually with non vpn client I use port forwarding from my router setup to reach some server ports, ie to connect to 192.168.1.115:9090. So with my router option I give permission from any address trying to contact port 90 of my ISP ip to route it to 192.168.1.115:9090.

 

I tried doing something similar with airvpn port forwarding setting but I do not understand where I route my client internal IP, 192.168.0.110.

 

I would like to route myairvpnIP:airvpnopenport to 192.168.1.110:8081

 

After I understand how it works, I'll use airvpn ddns service and use my internet domain names to forward it to the airvpn ddns url.

 

If you have any hints to educate me on this kind of setup, let me know.

 

Thank you and cheers!

 

 

John

 

Share this post


Link to post

I made some progress

 

I added a port forwarding in airvpn website :
Port : 33333 (fictive port for ie purpose)
Protocole : TCP&UDP
Local Port : 8081
DDNS : testsick (fictive name for ie purpose)

 

I added these lines in DD-WRT router ;
#Sickrage local port 8081. Airvpn port 33333. ddns = testsick.airdns.org:33333
iptables -t nat -I PREROUTING -i tun1 -p udp --dport 8081 -j DNAT --to-destination 192.168.1.110
iptables -t nat -I PREROUTING -i tun1 -p tcp --dport 8081 -j DNAT --to-destination 192.168.1.110
iptables -I FORWARD -i tun1 -p udp -d 192.168.1.110 --dport 8081 -j ACCEPT
iptables -I FORWARD -i tun1 -p tcp -d 192.168.1.110 --dport 8081 -j ACCEPT

 

And finally the results!

 

Within my ISP internet connection (from my dd-wrt router) and typing these address into a browser
http://192.168.0.110:8081 ; it works as expected
http://testsick.airdns.org:33333 ; it does not work
http://testsick.airdns.org ; it does not work

 

Within my mobile phone data connection (not connected to my dd-wrt router) and typing these address into a browser
http://192.168.0.110:8081 ; it does not work as expected obviously
http://testsick.airdns.org:33333 ; it works !!!! I can connect to my sickrage server
http://testsick.airdns.org ; it does not work

 

I now have 2 questions

 

1-Is there a iptables line I could add to make http://testsick.airdns.org:33333 works from within my dd-wrt internet connection? It's not a major issue but either I have to change my phone sickbeard app setting to 192.168.1.110:8081 instead of testsick.airdns.org:33333 OR turn off wifi so it connects thru mobile phone data connection.

 

2-Why should we add the port after the airdns address? I guess it could be a feature airvpn could add if doable? We already specify port and ddns name while adding a port forwarding. However I could forward mysickrage.domainname.sk to http://testsick.airdns.org:33333 so it's not a big deal. I'm just curious.

 

Cheers all!

 

John

Share this post


Link to post

Hello!

 

Our DDNS service is reserved to VPN usage, so *.airdns.org names will resolve exclusively to some VPN server exit-IP address.

 

When you don't specify a port in a browser, by default it tries port 80 for http and port 443 for https. That's why you need to specify the destination port.

 

Kind regards

Share this post


Link to post

thanks for explanation. It would have been nice to include port but like you said default port is 80 with a browser and using another service would use another standard port...

 

Any hints to make connection within my network using airvpn ddns url?

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Security Check
    Play CAPTCHA Audio
    Refresh Image
Sign in to follow this  

×
×
  • Create New...