expect_client_success = GetParam() == tsi_tls_version::TSI_TLS1_2
? expect_client_success_1_2_
: expect_client_success_1_3_;
-#else
- // If using OpenSSL version < 1.1, the CRL revocation won't
- // be enabled anyways, so we always expect the connection to
- // be successful.
- expect_server_success = true;
- expect_client_success = expect_server_success;
#endif
tsi_peer peer;
if (expect_client_success) {
auto* fixture_pass = new SslTsiTestFixture(
kServerKeyPath, kServerCertPath, kInvalidUtf8SanKeyPath,
kInvalidUtf8SanCertPath, "", "", kCaPemPath,
- // OpenSSL3 and above will fail the handshake because of the invalid
- // UTF-8 URI SAN.
-#if OPENSSL_VERSION_NUMBER >= 0x30000000L
- /*expect_server_success=*/false,
- /*expect_client_success_1_2=*/false,
-#else
/*expect_server_success=*/true,
/*expect_client_success_1_2=*/true,
-#endif
/*expect_client_success_1_3=*/true);
fixture_pass->Run();
// Should fail SPIFFE verification because of multiple URI SANs.
EXPECT_EQ(result.error_code(), failure_code);
// The expected failure message only matches when building against BoringSSL or
// OpenSSL < 3.0.
-#if GTEST_USES_POSIX_RE && OPENSSL_VERSION_NUMBER < 0x30000000L
+#if GTEST_USES_POSIX_RE && OPENSSL_VERSION_NUMBER < 0x30000000L && \
+ defined(OPENSSL_IS_BORINGSSL)
EXPECT_THAT(result.error_message(),
::testing::MatchesRegex(failure_message_regex));
#endif