[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[RISOLTO] Re: OpenVPN: un server + client



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Il problema era che:

 - usavo tap al posto di tun
 - ifconfig al posto di route


Adesso tutto funziona alla perfezione.

Gianluca

Gianluca ha scritto:
> Salve,
> 	ho configurato OpenVPN su sarge e cosa strana, con un solo client mi
> funziona, appena se ne connette un altro cominciano problemi.
> 
> Nei log trovo questo:
> 
> TLS Error: local/remote TLS keys are out of sync: <INDIRIZZO_IP>:1194
> 
> Dove l'indirizzo è quello del client che era connesso e non appena è
> arrivato il nuovo ha perso la connessione alla VPN.
> Quindi in modo alterno nel log compare l'errore con gli indirizzi ip dei
> client.
> Cercando su Google ho trovato questo:
> 
> http://openvpn.net/archive/openvpn-users/2004-12/msg00022.html
> 
> Ho fatto ciò che è scritto, ping-restart, ma la cosa non cambia.
> 
> Il file di configurazione dei client è:
> 
> client
> dev tap
> remote <IP_SERVER> 1194
> ca ca.crt
> cert <client>.crt
> key <client>.key
> tls-client ta.key
> cipher BF-CBC
> keysize 448
> comp-lzo
> ping 10
> verb 3
> mute 10
> ifconfig 10.0.0.<X> 255.255.255.0
> 
> Il file di configurazione del server è:
> 
> local <IP_SERVER>
> port 1194
> dev tap
> 
> ca ca.crt
> cert server.crt
> key server.key
> dh dh1024.pem
> tls-server ta.key
> cipher BF-CBC
> keysize 448
> 
> ifconfig 10.0.0.1 255.255.255.0
> comp-lzo
> max-clients 100
> 
> ping 10
> ping-restart 60
> verb 4
> mute 10
> log-append /var/log/openvpn/openvpn.log
> status /var/log/openvpn/openvpn-status.log
> 
> Le varie chiavi le ho generate così:
> 
> - CA
> openssl genrsa -out ca.key 1024
> openssl req -new -key ca.key -out rich.ca
> openssl x509 -req -in rich.ca -signkey ca.key -out ca.crt
> 
> - TA
> openvpn --genkey --secret ta.key
> 
> - Diffie-Hellman
> openssl dhparam -out dh1024.pem 1024
> 
> - Chiave Server
> openssl genrsa -out server.key 1024
> openssl req -new -key server.key -out rich.ser
> openssl x509 -req -in rich.ser -CA ca.crt -CAkey ca.key -CAcreateserial
> -out server.crt
> 
> - Chiave Client
> openssl genrsa -out <client>.key 1024
> openssl req -new -key <client>.key -out <client>.rich
> openssl x509 -req -in <client>.rich -CA ca.crt -CAkey ca.key
> -CAcreateserial -out <client>.cert
> 
> C'è qualcosa di errato?
> 
> Grazie a chi prende in considerazione questo mio problema.
> 
> Gianluca
> 

- --
echo aculnaiG | awk 'BEGIN { FS = "" }
{ for (i = NF; i >= 1; i-- )
  printf $i }'; echo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFF5rGNK1z3HmyB2QIRArVRAJ9YrMrWGgf81EKGt9iUN4cdEG6nAgCfYvCt
r3bmCYbGCYNPJZJ1oXc/bmY=
=d4RT
-----END PGP SIGNATURE-----



Reply to: