You are visiting:Home arrow Articles for Geeks arrow Latest arrow OpenVPN server and client on DD-WRT -- Bridged Thursday, 20 November 2008
Google
Support Geek-Pages.com in making a small donation:
Main Menu
Home
Articles for Geeks
FAQs for Non-Geeks
Links
Kevan's Blog
Contact Us
Forum
Search
Login Form





Lost Password?
No account yet? Register
Submit article to:
OpenVPN server and client on DD-WRT -- Bridged PDF Print E-mail
Written by Kevan   
 

7a)  If you are working on the VPN client WRT skip to step 7b.  On the VPN server WRT copy the following script and paste on the command line. (Check the scipt for comments on the few items than need to be updated to match your environment.) 

 

------------------- Copy starting below this line. -------------------

 nvram set rc_firewall='

#!/bin/sh

##

##

##


#copy openvpn binary to myvpn.  Otherwise, something will kill the process
cp /usr/sbin/openvpn /tmp/myvpn

/tmp/myvpn --mktun --dev tap0

 brctl addif br0 tap0
ifconfig tap0 0.0.0.0 promisc up

/tmp/myvpn --dev tap0 --secret /jffs/static.key --comp-lzo --port 1194 --proto udp --verb 3 --daemon  --ping 30 --ping-restart 120

--------------- Stop here when selecting text to copy -------------------------- 

7b) On the VPN clien WRT ctopy the following script and paste on the command line. (Check the scipt for comments on the few items than need to be updated to match your environment.)

------------------- Copy starting below this line. -------------------

nvram set rc_firewall=' 

#!/bin/sh

##
##
##


#copy openvpn binary to myvpn.  Otherwise, something will kill the process
cp /usr/sbin/openvpn /tmp/myvpn

/tmp/myvpn --mktun --dev tap0

brctl addif br0 tap0
ifconfig tap0 0.0.0.0 promisc up

/tmp/myvpn --dev tap0 --secret /jffs/static.key --comp-lzo --port 1194 --proto udp --verb 3 --daemon --remote VPNSERVER.dnsalias.com --ping 30 --ping-restart 120

'

--------------- Stop here when selecting text to copy --------------------------

 8) Type nvram commit  and hit <enter>

 9) Now reboot you routers and attempt to ping hosts accross the VPN tunnel.  (You will not be able to ping the WRTs addresses.  You have to ping a host on the network other than the WRT.).

 10) Remember that both sites need the same internal IP subnets.

That should be it and good luck! 

 

 

 

 

 

Comments
Written by ABL on 2006-09-18 11:17:08
Thanks for this! I have a few questions, though. Answers or pointers in the right direction would be appreciated. 
 
1) For a bridged implementation, the two networks need to be on the same subnet. No problem. Can/should the two routers have the same IP? 
2) Can I (How can I?) set up my laptop to use the VPN when I'm in another location (when I don't have access to the router)? 
 
Thanks, again!
Written by Kevan on 2006-09-22 18:31:23
1) No the routers are on the same internal network and they should have different internal IP addresses. 
 
2) You would be setting up a client VPN connection. You could install a second instance of OpenVPN on one of the routers and configure your Windows client similar to the client router. 
 
Kevan
Written by This email address is being protected from spam bots, you need Javascript enabled to view it on 2007-02-12 12:36:26
In regards to the above comment: 
Quote:
"You would be setting up a client VPN connection. You could install a second instance of OpenVPN on one of the routers and configure your Windows client similar to the client router."

 
Couldn't you just use the DD-WRT Control Panel under Administration>Services, and enable the PTPP Server on either of the routers? Or, would this conflict with the OpenVPN Bridge setup? 

Only registered users can write comments.
Please login or register.

Powered by AkoComment!