[Solved] User access : ccd-exclusive not "working"
Posted: Wed Sep 25, 2013 12:48 pm
Hello,
I want to be able to grand access to my server for the user, but aswell beeing able to remove this access (for a certain duration) and maybe reactive it later.
My configuration :
Debian wheezy 7
latest openvpn
server.conf:
ls -la from clientaccess directory :
And here is the log from /var/log/openvpn.log with verb 5 in my server.conf
So my client-config-dir is configurated with /etc/openvpn/clientaccess (you can see it in the first code), I have a outpox file in clientaccess (the file is empty, I created it with : "touch outpox" ). According to the log openvpn is looking in the good folder for the filen but I don't know why it doesn't "read" it. Because I can't connect the vpn.
Any idea ? If you need anything else just ask !
Thanks in advance
I want to be able to grand access to my server for the user, but aswell beeing able to remove this access (for a certain duration) and maybe reactive it later.
My configuration :
Debian wheezy 7
latest openvpn
server.conf:
Code: Select all
# Terveur TCP/443
mode server
proto tcp
port 443
dev tun
# Cles et certificats
ca ca.crt
cert server.crt
key server.key
dh dh1024.pem
tls-auth ta.key 0
cipher AES-256-CBC
# Doit etre commente pour autoriser une seule connexion a la fois par cle
; duplicate-cn
# Reseau
server 10.8.0.0 255.255.255.0
push "redirect-gateway def1 bypass-dhcp"
push "dhcp-option DNS 208.67.222.222"
push "dhcp-option DNS 208.67.220.220"
keepalive 10 120
# Securite
user nobody
group nogroup
chroot /etc/openvpn/jail
persist-key
persist-tun
comp-lzo
#crl-verify /etc/openvpn/crl.pem
# Log
verb 3
mute 20
status openvpn-status.log
log-append /var/log/openvpn.log
script-security 3 system
client-config-dir clientaccess
ccd-exclusive
Code: Select all
drwxr-xr-x 3 root root 4,0K sept. 25 14:19 .
drwxr-xr-x 10 root root 4,0K sept. 25 14:32 ..
-rw-r--r-- 1 root root 0 sept. 25 11:03 foo1
-rw-r--r-- 1 root root 0 sept. 25 11:04 foo2
-rw-r--r-- 1 root root 0 sept. 25 11:04 foo3
-rw-r--r-- 1 root root 0 sept. 25 11:04 outpox
Code: Select all
RWed Sep 25 11:30:38 2013 us=308646 myIP TLS: Initial packet from [AF_INET]myIP, sid=df5b15a6 f3710805
WRRWRWRWWWWRWRWWWRWRWRWRWRWRWRWRWRWRWRWRWRWRWRWRRRRWRWRWRWRWRWRWRWRWRWRWRWRWRWRWRWRWed Sep 25 11:30:39 2013 us=174288 myIP VERIFY OK: depth=1, /C=FR/ST=06/L=Nancy/OU=changeme/CN=changeme/name=changeme
Wed Sep 25 11:30:39 2013 us=174397 myIP VERIFY OK: depth=0, /C=FR/ST=06/L=Nancy/CN=outpox
WRWRWRWWWWRWRWWWRWRWRWRRRRWRWRWRWed Sep 25 11:30:39 2013 us=639248 myIP TLS Auth Error: --client-config-dir authentication failed for common name 'outpox' file='/etc/openvpn/clientaccess/outpox'
WWWRRWed Sep 25 11:30:39 2013 us=754258 myIP Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-AES256-SHA, 1024 bit RSA
Wed Sep 25 11:30:39 2013 us=754289 myIP [outpox] Peer Connection Initiated with [AF_INET]myIP
RWed Sep 25 11:30:41 2013 us=839663 myIP PUSH: Received control message: 'PUSH_REQUEST'
Wed Sep 25 11:30:41 2013 us=839685 myIP Delayed exit in 5 seconds
Wed Sep 25 11:30:41 2013 us=839707 myIP SENT CONTROL [outpox]: 'AUTH_FAILED' (status=1)
WWWed Sep 25 11:30:41 2013 us=907057 myIP Connection reset, restarting [0]
Wed Sep 25 11:30:41 2013 us=907086 myIP SIGUSR1[soft,connection-reset] received, client-instance restarting
Wed Sep 25 11:30:41 2013 us=907173 TCP/UDP: Closing socket
Any idea ? If you need anything else just ask !
Thanks in advance