Encrypted Tunnel Test Office$ sudo openvpn2 -remote -dev tun0 -ifconfig 10.0.0.1 10.0.0.2 -secret /etc/openvpn2/static.key -comp-lzo -keepalive 10 60 -float Home$ sudo openvpn2 -dev tun0 -ifconfig 10.0.0.2 10.0.0.1 -secret /etc/openvpn2/static.key -comp-lzo -keepalive 10 60 -floatĪs before, replace with Home's public address. Generate and Copy Static Keyįrom either computer, generate a static key: $ openvpn2 -genkey -secret static.key $ sudo mkdir /etc/openvpn2 $ sudo mv static.key /etc/openvpn2/Ĭopy /etc/openvpn2/static.key to the other computer via a secure channel (as anyone with this file can access your VPN) and put it in the same directory, i.e., /etc/openvpn2. When finished testing, CTRL C to stop the tunnel. Try pinging Office from Home and vice versa: Home$ ping 10.0.0.1 Office$ ping 10.0.0.2 Also, if you receive a "command not found" error, use the complete path to openvpn2 instead: sudo /opt/local/sbin/openvpn2. Replace with Home's public hostname or IP address. Now we'll make a quick, unencrypted connection to test our setup: Office$ sudo openvpn2 -remote -dev tun0 -ifconfig 10.0.0.1 10.0.0.2 Home$ sudo openvpn2 -dev tun0 -ifconfig 10.0.0.2 10.0.0.1
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |