Angepinnt How To: OpenVPN
Diese Seite verwendet Cookies. Durch die Nutzung unserer Seite erklären Sie sich damit einverstanden, dass wir Cookies setzen. Weitere Informationen
-
-
Das kommt dabei raus:
Quellcode
- Thu Oct 29 16:02:59 2015 OpenVPN 2.1.3 mipsel-oe-linux [SSL] [LZO2] [EPOLL] built on Mar 12 2015
- Thu Oct 29 16:02:59 2015 WARNING: Make sure you understand the semantics of --tls-remote before using it (see the man page).
- Thu Oct 29 16:02:59 2015 NOTE: OpenVPN 2.1 requires '--script-security 2' or higher to call user-defined scripts or executables
- Thu Oct 29 16:02:59 2015 LZO compression initialized
- Thu Oct 29 16:02:59 2015 Control Channel MTU parms [ L:1570 D:138 EF:38 EB:0 ET:0 EL:0 ]
- Thu Oct 29 16:02:59 2015 Socket Buffers: R=[163840->131072] S=[163840->131072]
- Thu Oct 29 16:02:59 2015 Data Channel MTU parms [ L:1570 D:1450 EF:70 EB:135 ET:0 EL:0 AF:3/1 ]
- Thu Oct 29 16:02:59 2015 Local Options hash (VER=V4): 'fc8ba345'
- Thu Oct 29 16:02:59 2015 Expected Remote Options hash (VER=V4): '79a26cd9'
- Thu Oct 29 16:02:59 2015 UDPv4 link local: [undef]
- Thu Oct 29 16:02:59 2015 UDPv4 link remote: ***.***.***.***:443
- Thu Oct 29 16:02:59 2015 TLS: Initial packet from ***.***.***.***:443, sid=c3096d5d c92b9fd4
- Thu Oct 29 16:02:59 2015 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
- Thu Oct 29 16:02:59 2015 VERIFY OK: depth=1, /C=US/ST=FL/L=Winter_Park/O=IPVanish/OU=IPVanish_VPN/CN=IPVanish_CA/emailAddress=support@ipvanish.com
- Thu Oct 29 16:02:59 2015 VERIFY X509NAME OK: /C=US/ST=FL/L=Winter_Park/O=IPVanish/OU=IPVanish_VPN/CN=prg-c01.ipvanish.com/emailAddress=support@ipvanish.com
- Thu Oct 29 16:02:59 2015 VERIFY OK: depth=0, /C=US/ST=FL/L=Winter_Park/O=IPVanish/OU=IPVanish_VPN/CN=prg-c01.ipvanish.com/emailAddress=support@ipvanish.com
- Thu Oct 29 16:03:00 2015 Data Channel Encrypt: Cipher 'AES-256-CBC' initialized with 256 bit key
- Thu Oct 29 16:03:00 2015 Data Channel Encrypt: Using 256 bit message hash 'SHA256' for HMAC authentication
- Thu Oct 29 16:03:00 2015 Data Channel Decrypt: Cipher 'AES-256-CBC' initialized with 256 bit key
- Thu Oct 29 16:03:00 2015 Data Channel Decrypt: Using 256 bit message hash 'SHA256' for HMAC authentication
- Thu Oct 29 16:03:00 2015 Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-AES256-SHA, 2048 bit RSA
- Thu Oct 29 16:03:00 2015 [***.ipvanish.com] Peer Connection Initiated with ***.***.***.***:443
- Thu Oct 29 16:03:03 2015 SENT CONTROL [***.ipvanish.com]: 'PUSH_REQUEST' (status=1)
- Thu Oct 29 16:03:03 2015 PUSH: Received control message: 'PUSH_REPLY,redirect-gateway def1 bypass-dhcp,dhcp-option DNS ***.***.***.***,dhcp-option DNS ***.***.***.***,rcvbuf 262144,explicit-exit-notify 5,route-gateway ***.***.***.***,topology subnet,ping 20,ping-restart 40,ifconfig ***.***.***.*** 255.255.252.0'
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: timers and/or timeouts modified
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: explicit notify parm(s) modified
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: --sndbuf/--rcvbuf options modified
- Thu Oct 29 16:03:03 2015 Socket Buffers: R=[131072->327680] S=[131072->131072]
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: --ifconfig/up options modified
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: route options modified
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: route-related options modified
- Thu Oct 29 16:03:03 2015 OPTIONS IMPORT: --ip-win32 and/or --dhcp-option options modified
- Thu Oct 29 16:03:03 2015 ROUTE default_gateway=***.***.***.***
- Thu Oct 29 16:03:03 2015 TUN/TAP device tun1 opened
- Thu Oct 29 16:03:03 2015 TUN/TAP TX queue length set to 100
- Thu Oct 29 16:03:03 2015 /sbin/ifconfig tun1 ***.***.***.*** netmask 255.255.252.0 mtu 1500 broadcast ***.***.***.***
- Thu Oct 29 16:03:03 2015 /sbin/route add -net ***.***.***.*** netmask 255.255.255.255 gw ***.***.***.***
- Thu Oct 29 16:03:03 2015 ERROR: Linux route add command failed: external program exited with error status: 1
- Thu Oct 29 16:03:03 2015 /sbin/route add -net 0.0.0.0 netmask 128.0.0.0 gw ***.***.***.***
- Thu Oct 29 16:03:03 2015 ERROR: Linux route add command failed: external program exited with error status: 1
- Thu Oct 29 16:03:03 2015 /sbin/route add -net 128.0.0.0 netmask 128.0.0.0 gw ***.***.***.***
- Thu Oct 29 16:03:03 2015 ERROR: Linux route add command failed: external program exited with error status: 1
- Thu Oct 29 16:03:03 2015 Initialization Sequence Completed
- Thu Oct 29 16:03:49 2015 event_wait : Interrupted system call (code=4)
- Thu Oct 29 16:03:49 2015 TCP/UDP: Closing socket
- Thu Oct 29 16:03:49 2015 /sbin/route del -net ***.***.***.*** netmask 255.255.255.255
- Thu Oct 29 16:03:49 2015 ERROR: Linux route delete command failed: external program exited with error status: 1
- Thu Oct 29 16:03:49 2015 /sbin/route del -net 0.0.0.0 netmask 128.0.0.0
- Thu Oct 29 16:03:49 2015 ERROR: Linux route delete command failed: external program exited with error status: 1
- Thu Oct 29 16:03:49 2015 /sbin/route del -net 128.0.0.0 netmask 128.0.0.0
- Thu Oct 29 16:03:49 2015 ERROR: Linux route delete command failed: external program exited with error status: 1
- Thu Oct 29 16:03:49 2015 Closing TUN/TAP interface
- Thu Oct 29 16:03:49 2015 /sbin/ifconfig tun1 0.0.0.0
- Thu Oct 29 16:03:49 2015 SIGHUP[hard,] received, process restarting
- Thu Oct 29 16:03:49 2015 OpenVPN 2.1.3 mipsel-oe-linux [SSL] [LZO2] [EPOLL] built on Mar 12 2015
- Thu Oct 29 16:03:49 2015 Restart pause, 2 second(s)
- Thu Oct 29 16:03:51 2015 WARNING: Make sure you understand the semantics of --tls-remote before using it (see the man page).
- Thu Oct 29 16:03:51 2015 NOTE: OpenVPN 2.1 requires '--script-security 2' or higher to call user-defined scripts or executables
- Thu Oct 29 16:03:51 2015 LZO compression initialized
- Thu Oct 29 16:03:51 2015 Control Channel MTU parms [ L:1570 D:138 EF:38 EB:0 ET:0 EL:0 ]
- Thu Oct 29 16:03:51 2015 Socket Buffers: R=[163840->131072] S=[163840->131072]
- Thu Oct 29 16:03:51 2015 Data Channel MTU parms [ L:1570 D:1450 EF:70 EB:135 ET:0 EL:0 AF:3/1 ]
- Thu Oct 29 16:03:51 2015 Local Options hash (VER=V4): 'fc8ba345'
- Thu Oct 29 16:03:51 2015 Expected Remote Options hash (VER=V4): '79a26cd9'
- Thu Oct 29 16:03:51 2015 UDPv4 link local: [undef]
- Thu Oct 29 16:03:51 2015 UDPv4 link remote: ***.***.***.***:443
- Thu Oct 29 16:03:51 2015 TLS: Initial packet from ***.***.***.***:443, sid=7f49400f b5d4d7ea
- Thu Oct 29 16:03:51 2015 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
- Thu Oct 29 16:03:51 2015 VERIFY OK: depth=1, /C=US/ST=FL/L=Winter_Park/O=IPVanish/OU=IPVanish_VPN/CN=IPVanish_CA/emailAddress=support@ipvanish.com
- Thu Oct 29 16:03:51 2015 VERIFY X509NAME OK: /C=US/ST=FL/L=Winter_Park/O=IPVanish/OU=IPVanish_VPN/CN=prg-c01.ipvanish.com/emailAddress=support@ipvanish.com
- Thu Oct 29 16:03:51 2015 VERIFY OK: depth=0, /C=US/ST=FL/L=Winter_Park/O=IPVanish/OU=IPVanish_VPN/CN=prg-c01.ipvanish.com/emailAddress=support@ipvanish.com
- Thu Oct 29 16:03:53 2015 Data Channel Encrypt: Cipher 'AES-256-CBC' initialized with 256 bit key
- Thu Oct 29 16:03:53 2015 Data Channel Encrypt: Using 256 bit message hash 'SHA256' for HMAC authentication
- Thu Oct 29 16:03:53 2015 Data Channel Decrypt: Cipher 'AES-256-CBC' initialized with 256 bit key
- Thu Oct 29 16:03:53 2015 Data Channel Decrypt: Using 256 bit message hash 'SHA256' for HMAC authentication
- Thu Oct 29 16:03:53 2015 Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-AES256-SHA, 2048 bit RSA
- Thu Oct 29 16:03:53 2015 [***.ipvanish.com] Peer Connection Initiated with ***.***.***.***:443
- Thu Oct 29 16:03:55 2015 SENT CONTROL [***.ipvanish.com]: 'PUSH_REQUEST' (status=1)
- Thu Oct 29 16:03:55 2015 PUSH: Received control message: 'PUSH_REPLY,redirect-gateway def1 bypass-dhcp,dhcp-option DNS ***.***.***.***,dhcp-option DNS ***.***.***.***,rcvbuf 262144,explicit-exit-notify 5,route-gateway ***.***.***.***,topology subnet,ping 20,ping-restart 40,ifconfig ***.***.***.*** 255.255.252.0'
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: timers and/or timeouts modified
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: explicit notify parm(s) modified
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: --sndbuf/--rcvbuf options modified
- Thu Oct 29 16:03:55 2015 Socket Buffers: R=[131072->327680] S=[131072->131072]
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: --ifconfig/up options modified
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: route options modified
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: route-related options modified
- Thu Oct 29 16:03:55 2015 OPTIONS IMPORT: --ip-win32 and/or --dhcp-option options modified
- Thu Oct 29 16:03:55 2015 ROUTE default_gateway=***.***.***.***
- Thu Oct 29 16:03:55 2015 TUN/TAP device tun0 opened
- Thu Oct 29 16:03:55 2015 TUN/TAP TX queue length set to 100
- Thu Oct 29 16:03:55 2015 /sbin/ifconfig tun0 ***.***.***.*** netmask 255.255.252.0 mtu 1500 broadcast ***.***.***.***
- Thu Oct 29 16:03:55 2015 /sbin/route add -net ***.***.***.*** netmask 255.255.255.255 gw ***.***.***.***
- Thu Oct 29 16:03:55 2015 /sbin/route add -net 0.0.0.0 netmask 128.0.0.0 gw ***.***.***.***
- Thu Oct 29 16:03:55 2015 /sbin/route add -net 128.0.0.0 netmask 128.0.0.0 gw ***.***.***.***
- Thu Oct 29 16:03:55 2015 Initialization Sequence Completed
Meine openvpnvti.conf sieht so aus:
Quellcode
- client
- dev tun
- proto udp
- remote ***.ipvanish.com 443
- resolv-retry infinite
- nobind
- persist-key
- persist-tun
- persist-remote-ip
- ca /etc/openvpn/ca.ipvanish.com.crt
- tls-remote ***.ipvanish.com
- auth-user-pass /etc/openvpn/auth.txt
- comp-lzo
- verb 3
- auth SHA256
- cipher AES-256-CBC
- keysize 256
- tls-cipher DHE-RSA-AES256-SHA:DHE-DSS-AES256-SHA:AES256-SHA
-
Könnte es sein, dass du den Tunnel doppelt gestartet hast?
-
Banana Joe schrieb:
Könnte es sein, dass du den Tunnel doppelt gestartet hast?
Über welchen Eintrag denn? Bin kein Profi...
Muss da 'dev tun' raus? -
Per Hand, über den entsprechenen Menüentrag zum Beispiel. Meines Wissens wird openvpn automatisch beim booten gestartet.
Oder du hast zufällig zwei Konfigurationsdateien in /etc/openvpn liegen? Evtl. eine Sicherungskopie o.ä.? Dann werden beide gestartet. -
Nein, manuell habe ich da nichts gestartet. Da ich autostart für openvpn nicht aktiviert habe, wird beim booten auch kein Start ausgeführt.
In /etc/opemvpn liegt nur eine openvpnvti.config, die auth- und die ca-datei. -
Mal Box komplett neugestartet? Vielleicht hat sich ein ovpn Prozess aufgehängt.
Mehr fällt mir gerade auch nicht ein.
Config sieht eigentlich gut aus, Eintrag "dev tun" ist auch richtig. -
Ja, sicher - Box wurde mehrfach neu gestartet...
Über den Menu-Eintrag openvpn zu beenden, komme ich nicht weiter. Wenn ich aber, bei laufendem openvpn, den Menueintrag auswähle, Autostart zu beenden, wird auch openvpn beendet... -
Hallo,
Ich habe im Forum jetzt ein bisschen gestoebert, da ich auf der Suche bin nach einem Tutorial zur Einrichtung einer VPN Verbindung auf meine VU+ Solo2 Box.
Leider habe ich diesbezueglich nichts gutes gefunden, das ich mir zutrauen wuerde umzusetzen.
Mein Plan waere meine VU+, die hinter einem Huawei B593 Router steht, aus dem Internet ueber VPN erreichbar zu machen. Vorallem angriffssicher erreichbar.
Derzeit arbeite ich nur mit einer Port Freigabe und Forwarding am B593 Router.
gibt es dazu Erfahrungen bei Euch?
Vielen Dank!
Liebe Gruesse, Robert -
Gute Tutorials gibts haufenweise, z.B. hier: wiki.ubuntuusers.de/openvpn
Das Problem dabei: fast alle verwenden die easy-rsa Tools für die Schlüsselerzeugung, das sind ein paar Skripte, die leider nicht beim VTI Image dabei sind.
Entweder per Hand nachinstallieren (siehe hier: Klick
oder die Schlüssel auf einem Linux/Win-Rechner erzeugen und dann umkopieren.
Es gibt keine einfacheren Anleitung, dazu ist openvpn zu umfangreich. -
@bertl: ich kann dir mein script anbieten, dass die zertifkate auf der vu erstellt und den server installiert und startet. musst dann nur noch portforwarding machen und die client-zertifikate einspielen.
-
@pillepallus
Ja das waere nett.
Wie komm ich zu dem Skript von Dir? emailen?
Vielen Dank!
Liebe Gruesse, Robert -
zip in /home/root/ entpacken
/home/root/openvpn-scripts/certs.sh ausführbar machen
starten mit i.e.
/home/root/certs.sh noobnet vpn.noobnet.de 8888 1024
param1: name der certs
param2: deine adresse von aussen
param3: port
param4: die zusatzzahl würde ich auf 1024 lassen.
die zertifkate werden alle erzeugt und der server auf der vu automatisch gestartet. in deiner moviefreigabe hast du dann einen ordner mit dem namen openvpn. da liegen die client-certs drinne. die müssen auf den client. und am router einfach ne portfreigabe auf den vpn-port. -
Servus Pillepallus!
Vielen Dank fuer die Anleitung!
Ich hab noch ein paar kleine Fragen dazu, bevor ich damit anfange.
- Die Skripte mache ich mit chmod 777 ausfuehrbar - oder reichen weniger Rechte als alle auf 7 zu setzen?
- Was bedeutet "starten mit i.e." ?
Zu den Parametern:
param1: wird denke ich gleich bleiben, wie in deinem Beispiel, wenn ich das certs.sh nicht umbenenne und auf einen anderen Ordner lege, oder?
param2: Ich habe einen dynamischen DNS Dienst konfiguriert, mit dem ich derzeit auf meine Box zugreife. (afraid.org) Kann ich diese Adresse nehmen?
param3: Kann ich auf Port 8888 bleiben, oder wodurch bestimmt sich dieser?
param4: Wofuer stehen die 1024?
Vielen Dank!
Liebe Gruesse, Robert -
ausführbar machen mit chmod +x /home/root/openvpn-scripts/certs.sh.... 777 erfüllt den zweck aber auch. i.e. steht für z.b. (in example)
1024 ist die schlüssellänge
deine startparameter wären:
bertl %adresse%.afraid.org %port% 1024
%adresse% ist deine genaue adresse in dem laden
%port% den wählst du selbst und sagst uns nix
edith:
habs mal in ein ipk gepackt. das ist einfacher.
"menu --> vti --> vti panel --> vti systemwerkzeuge --> befehl ausführen" --> dort ein script names "/home/root/openvpn-scripts/certs.sh"
die parameter kannst du dort editieren und dann ausführen.Dieser Beitrag wurde bereits 2 mal editiert, zuletzt von pillepallus ()
-
pillepallus schrieb:
zip in /home/root/ entpacken
/home/root/openvpn-scripts/certs.sh ausführbar machen
starten mit i.e.
/home/root/certs.sh noobnet vpn.noobnet.de 8888 1024
param1: name der certs
param2: deine adresse von aussen
param3: port
param4: die zusatzzahl würde ich auf 1024 lassen.
die zertifkate werden alle erzeugt und der server auf der vu automatisch gestartet. in deiner moviefreigabe hast du dann einen ordner mit dem namen openvpn. da liegen die client-certs drinne. die müssen auf den client. und am router einfach ne portfreigabe auf den vpn-port.
eine frage noch zum server:
startet sich dieser automatisch, wenn die box neugestartet wird, oder muss man das noch irgendwo konfigurieren?
Liebe Gruesse, Bertl -
Hallo,
noch ein paar Fragen zu den Clients mit denen ich mich auf meinen VPN Server verbinden will.
Welche Software (freeware) ausser openvpn (https://openvpn.net/) koennt ihr mir fuer den PC (Win7) empfehlen?
Openvpn nutze ich bereits fuer die Firma und daher moechte ich das Programm nicht zusaetzlich privaten Schluesselfiles konfigurieren - da ist zoof mit unserer internen EDV vorprogrammiert.
Welche VPN clients koennnt Ihr mir fuer Android und Iphone handys empfehlen?
Vielen Dank!
Liebe Gruesse, BertlDieser Beitrag wurde bereits 1 mal editiert, zuletzt von vu+solo2_Bertl ()
-
ja sollte automatisch starten.
hmm probier halt mal openvpn portable, vlt klappts ja... brauchst halt noch ein tap device. für iphone nehme ich den normalen openvpn client ausm store. die zertifikate müssen über itunes eingespielt werden und da in den speicher der app. starten kann man es dann auch in den einstellungen. -
Hallo nochmals!
Danke fuer die SW Tipps - werd die dann mal testen.
Was ist denn ein tap device? Noch nie davon gehoert!
Noch eine Frage,
Wenn ich dann das openvpn eingerichtet habe, dann habe ich ja eine abhoersichere Leitung zwischen verbundenen Clients zur Box.
Aber was ist in die andere Richtung, wenn ich von der Box aus ins Internet gehe, aber nicht auf die verbundenen Clients, sondern andere Ziele.
Dann ist die Verbindung nicht sicher, oder?
Gibt es dafuer auch Loesungen?
Vielen Dank!
Liebe Gruesse, Robert -
In die andere Richtung geht natürlich auch, dazu benötigst du aber einen Anonymisierungsdienst. Eine Anleitung dazu findest du hier im Thread auf Seite 1.