View previous topic :: View next topic |
Author |
Message |
Karhot87 Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
![](images/avatars/1602313218463ba2219206c.jpg)
Joined: 26 Apr 2007 Posts: 137 Location: Poggio Murella (GR) ma studio a Roma
|
Posted: Fri Dec 27, 2013 2:58 pm Post subject: OpenVpn : TLS key negotiation failed [RISOLTO] |
|
|
Ciao a tutti, sto provando a configurare il mio server per uso domestico per potervi accedere via vpn quando sono fuori. Sul server è installato gentoo, con kernel: 2.6.31-gentoo-r10, openvpn 2.2.2.
Di seguito il file di configurazione del server:
Code: | dev tap0
#ifconfig 172.16.1.1 172.16.1.20
proto udp
port 5724
#local 192.168.0.8
#server 10.1.1.1
mode server
tls-server
float
dh /etc/openvpn/ssl/keys/dh1024.pem
ca /etc/openvpn/ssl/keys/ca.crt
cert /etc/openvpn/ssl/keys/server.crt
key /etc/openvpn/ssl/keys/server.key
tls-auth /etc/openvpn/ssl/keys/ta.key 1
user nobody
group nogroup
status /var/log/openvpn/vpn-status.log
log /var/log/openvpn/vpn.log
comp-lzo
verb 3
#client-to-client
keepalive 10 120
fragment 1300
mssfix
hand-window 60
tcp-nodelay
persist-key
|
Qui il file del client:
Code: |
client
auth-nocache
dev tun
# ifconfig 172.16.1.20 172.16.1.1
proto udp
comp-lzo
resolv-retry infinite
persist-key
persist-tun
remote 192.168.0.8
port 5724
#local 192.168.0.8 5724
ca ca.crt
cert francesco-pc.crt
key francesco-pc.key
tls-auth ta.key 1
# ns-cert-type server
verb 3
float
|
IL client è un pc con windows. Quando provo a connettermi dal client all'interno della stessa rete lan sul server ho questo log:
Code: |
Fri Dec 27 15:47:52 2013 192.168.0.110:5724 TLS: Initial packet from 192.168.0.110:5724, sid=90883736 87fe1f18
Fri Dec 27 15:48:52 2013 192.168.0.110:5724 TLS Error: TLS key negotiation failed to occur within 60 seconds (check your network connectivity)
Fri Dec 27 15:48:52 2013 192.168.0.110:5724 TLS Error: TLS handshake failed
Fri Dec 27 15:48:52 2013 192.168.0.110:5724 SIGUSR1[soft,tls-error] received, client-instance restarting
Fri Dec 27 15:48:54 2013 MULTI: multi_create_instance called
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 Re-using SSL/TLS context
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 LZO compression initialized
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 Control Channel MTU parms [ L:1578 D:166 EF:66 EB:0 ET:0 EL:0 ]
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 Data Channel MTU parms [ L:1578 D:1300 EF:46 EB:135 ET:32 EL:0 AF:3/1 ]
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 Fragmentation MTU parms [ L:1578 D:1300 EF:45 EB:135 ET:33 EL:0 AF:3/1 ]
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 Local Options hash (VER=V4): 'f2ec8ea7'
Fri Dec 27 15:48:54 2013 192.168.0.110:5724 Expected Remote Options hash (VER=V4): 'ae463221'
|
Ho fatto diverse prove, ma sempre lo stesso errore. Per la configurazione, generazione delle chiavi, certificati ecc... ho seguito questa guida: http://doc.gabosh.net/howto_VPN_Server.html
Sul client windows ho provato anche a disabilitare il firewall ma niente, stesso problema.
Pensando che fosse un problema dato dal fatto che provavo la connessione all'interno della stessa rete, ho rovato a connettermi tramite cellulare ma niente, stesso problema. Mi manca qualcosa nel file di configurazione? Che sbaglio?
Grazie a tutti
Last edited by Karhot87 on Sun Dec 29, 2013 11:07 am; edited 1 time in total |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
Karhot87 Tux's lil' helper
![Tux's lil' helper Tux's lil' helper](/images/ranks/rank_rect_1.gif)
![](images/avatars/1602313218463ba2219206c.jpg)
Joined: 26 Apr 2007 Posts: 137 Location: Poggio Murella (GR) ma studio a Roma
|
Posted: Sun Dec 29, 2013 11:06 am Post subject: |
|
|
Ciao a tutti, preso dalla disperazione mi sono deciso e ho riconfigurato tutto da zero, creato nuove chiavi, nuovi certificati ecc...
Poi sono partito dai file di configurazione di base trovati su openvpn.net e magicamente tutto funziona alla perfezione. Sicuramente avevo fatto confusione con i file la prima volta.
Spero possa essere utile a qualcuno. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|