I would like to setup stunnel but the certificate from my other tunnel is expired. How would I tell stunnel to ignore verification of expiry date of the certificate coming from stunnel client mode to the stunnel server mode?
verify = LEVEL verify the peer certificate level 0 Request and ignore the peer certificate. level 1 Verify the peer certificate if present. level 2 Verify the peer certificate. level 3 Verify the peer with locally installed certificate. level 4 Ignore the CA chain and only verify the peer certificate. default No verify.
So it seems you can just add
verify = 0
to your config.
Presumably, if your version of stunnel is dynamically linked and you're not against using LD_PRELOAD, you could use libfaketime and its wrapper (faketime) to start stunnel at a time when the certificate was still valid. Albeit this is not a proper answer, I think it could help the OpenSSL checks to pass.