mirror of
https://github.com/ruby/ruby.git
synced 2025-09-17 17:43:59 +02:00
[ruby/openssl] Relax error message check for OpenSSL 3.1
A tentative measures fo https://github.com/ruby/openssl/issues/606.
With OpenSSL 3.1.0, the error message at connection using "self-signed
certificate" seems to return `SSL_R_TLSV1_ALERT_UNKNOWN_CA` instead of
`SSL_R_CERTIFICATE_VERIFY_FAILED`.
fc4629d246
This commit is contained in:
parent
34da58bd17
commit
f89101fa36
1 changed files with 1 additions and 3 deletions
|
@ -1046,9 +1046,7 @@ class OpenSSL::TestSSL < OpenSSL::SSLTestCase
|
|||
start_server(ignore_listener_error: true) { |port|
|
||||
ctx = OpenSSL::SSL::SSLContext.new
|
||||
ctx.set_params
|
||||
# OpenSSL <= 1.1.0: "self signed certificate in certificate chain"
|
||||
# OpenSSL >= 3.0.0: "self-signed certificate in certificate chain"
|
||||
assert_raise_with_message(OpenSSL::SSL::SSLError, /self.signed/) {
|
||||
assert_raise_with_message(OpenSSL::SSL::SSLError, /certificate/) {
|
||||
server_connect(port, ctx)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue