Hello openvpn users,
I currently have an openvpn server that has a ca.crt that will expire in a few weeks. To keep the transition smooth, I decided to use
stacked certificates.
So first I generated a new ca.crt with:
openssl x509 -in origca.crt -days 720 -enddate -out newca.crt -signkey ca.key
Then stacked both ca:
cat origca.crt newca.crt > ca.crt
And restarted the server. The relevant server config lines are:
ca ca.crt
cert ca.crt
Then copied the new ca.crt, which now contains both old and new ca stacked, to a client.
And now comes the problem, with the new ca.crt above they can connect but if I change it just to use the newca.crt it doesn't connect. Log from the client:
us=880839 UDPv4 link remote: [AF_INET]X.X.X.X:XXXX
us=897026 TLS: Initial packet from [AF_INET]X.X.X.X:XXXX, sid=52e78d19 25ae783d
us=57532 VERIFY ERROR: depth=0, error=self signed certificate: /O=CDC/CN=CDC_CN
us=57614 TLS_ERROR: BIO read tls_read_plaintext error: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
us=57629 TLS Error: TLS object -> incoming plaintext read error
us=57650 TLS Error: TLS handshake failed
But verifiying with openssl works:
openssl verify -CAfile newca.crt -verbose client.crt
client.crt: OK
openssl verify -CAfile origca.crt -verbose client.crt
client.crt: OK
This should work right or am I doing something wrong? :?
Any feedback is appreciated.