Boas gente. Eu peguei num pc antigo que tinha em casa do meus pais e instalei-lhe o Ubuntu Server 12.04. Queria, agora, criar uma VPN em casa, usando para isso o OpenVPN. Ora acontece que correu tudo bem do lado do servidor (acho), que está em modo bridge, mas quando tento correr no cliente, ele dá-me erro:
O meu server.conf:
client.conf:
Só para dizer ainda que estou a tentar ligar através de wireless, não sei se isso influencia alguma coisa ou não...
Obrigado pela ajuda, é que não encontro nada na net sobre isto (excepto para por a path toda até aos ficheiro, o que já experimentei).
Código:
Mon May 28 17:32:20 2012 OpenVPN 2.1.3 x86_64-pc-linux-gnu [SSL] [LZO2] [EPOLL] [PKCS11] [MH] [PF_INET6] [eurephia] built on Mar 11 2011
Mon May 28 17:32:20 2012 NOTE: OpenVPN 2.1 requires '--script-security 2' or higher to call user-defined scripts or executables
Mon May 28 17:32:20 2012 Cannot load certificate file HomeServer.crt: error:0906D06C:PEM routines:PEM_read_bio:no start line: error:140AD009:SSL routines:SSL_CTX_use_certificate_file:PEM lib
Mon May 28 17:32:20 2012 Exiting
O meu server.conf:
Código:
# Which local IP address should OpenVPN
# listen on? (optional)
local 192.168.1.92
# Which TCP/UDP port should OpenVPN listen on?
# If you want to run multiple OpenVPN instances
# on the same machine, use a different port
# number for each one. You will need to
# open up this port on your firewall.
port 1194
# TCP or UDP server?
;proto tcp
proto udp
dev tap0
;dev tun
up "/etc/openvpn/up.sh br0"
down "/etc/openvpn/down.sh br0"
ca ca.crt
cert server.crt
key server.key
dh dh1024.pem
server-bridge 192.168.1.92 255.255.255.0 192.168.1.92.100 192.168.1.92.105 //tenho aqui algumas dúvidas se é assim
client.conf:
Código:
# Specify that we are a client and that we
# will be pulling certain config file directives
# from the server.
client
# Use the same setting as you are using on
# the server.
# On most systems, the VPN will not function
# unless you partially or fully disable
# the firewall for the TUN/TAP interface.
dev tap0
;dev tun
# Windows needs the TAP-Win32 adapter name
# from the Network Connections panel
# if you have more than one. On XP SP2,
# you may need to disable the firewall
# for the TAP adapter.
;dev-node MyTap
# Are we connecting to a TCP or
# UDP server? Use the same setting as
# on the server.
proto tcp
;proto udp
# The hostname/IP and port of the server.
# You can have multiple remote entries
# to load balance between the servers.
remote sidnerhomeserver.no-ip.org 1194
;remote my-server-2 1194
# Choose a random host from the remote
# list for load-balancing. Otherwise
# try hosts in the order specified.
;remote-random
# Keep trying indefinitely to resolve the
# host name of the OpenVPN server. Very useful
# on machines which are not permanently connected
# to the internet such as laptops.
resolv-retry infinite
# Most clients don't need to bind to
# a specific local port number.
nobind
# Downgrade privileges after initialization (non-Windows only)
user nobody
group nogroup
# Try to preserve some state across restarts.
persist-key
persist-tun
# If you are connecting through an
# HTTP proxy to reach the actual OpenVPN
# server, put the proxy server/IP and
# port number here. See the man page
# if your proxy server requires
# authentication.
;http-proxy-retry # retry on connection failures
;http-proxy [proxy server] [proxy port #]
# Wireless networks often produce a lot
# of duplicate packets. Set this flag
# to silence duplicate packet warnings.
mute-replay-warnings
# SSL/TLS parms.
# See the server config file for more
# description. It's best to use
# a separate .crt/.key file pair
# for each client. A single ca
# file can be used for all clients.
ca ca.crt
cert HomeServer.crt
key HomeServer.key
Só para dizer ainda que estou a tentar ligar através de wireless, não sei se isso influencia alguma coisa ou não...
Obrigado pela ajuda, é que não encontro nada na net sobre isto (excepto para por a path toda até aos ficheiro, o que já experimentei).