Hi
We are running a openvpn Server on UDP using TLS authentication with client certs. Some clients have certificates from CA 1, others from CA 2. Therefore we have to implement multiple CRL files in order to check for revoked certificates from both CAs.
We discovered that in our setup, the CRL files are not handled as expected. Even the CRL file is there AND a certificate has been revoked, the user can access - which is a critical flaw.
Listing of /etc/openvpn/ca (obfuscated) shows the two crl files with the hashed names.
-rw-r--r-- 1 root root 1585 11. Aug 15:12 79f1a304.r0
-rw-r--r-- 1 root root 1012 10. Aug 13:12 0f1a85bc.r0
-rw-r--r-- 1 root root 1239 11. Aug 11:33 18321a6e.r0
If we now connect with the revoked client certificate, strace indicates that openvpn is looking for crl file names hash.r1 or hash.r2. If the file is not there, the client gets granted.
stat("/etc/openvpn/ca/18321a6e.r2", 0x7fff7a013b70) = -1 ENOENT (No such file or directory)
stat("/etc/openvpn/ca/18321a6e.r2", 0x7fff7a013b70) = -1 ENOENT (No such file or directory)
stat("/etc/openvpn/ca/79f1a304.r2", 0x7fff7a013b20) = -1 ENOENT (No such file or directory)
stat("/etc/openvpn/ca/0f1a85bc.r1", 0x7fff7a013b20) = -1 ENOENT (No such file or directory)
stat("/etc/openvpn/ca/0f1a85bc.r1", 0x7fff7a013b20) = -1 ENOENT (No such file or directory)
Any ideas/comments are highly appreciated.
Sven
server.conf (obfuscated)
mode server
tls-server
topology subnet
port 1194
proto udp
dev tun
capath /etc/openvpn/ca
cert ca/openvpn.crt
key ca/openvpn.key
dh ca/dh2048.pem
server 10.X.X.X 255.255.255.0
client-config-dir ccd
ccd-exclusive
keepalive 10 120
user nobody
group nobody
persist-key
persist-tun
status /data/openvpn/log/openvpn-status.log
log-append /data/openvpn/log/openvpn.log
verb 3
no-name-remapping