diff --git a/crypto/x509/x509_test.cc b/crypto/x509/x509_test.cc index d2b1a6ff28..9498c9aa3a 100644 --- a/crypto/x509/x509_test.cc +++ b/crypto/x509/x509_test.cc @@ -2770,6 +2770,9 @@ TEST(X509Test, SignCSR) { bssl::UniquePtr copy_pubkey(X509_REQ_get_pubkey(copy.get())); ASSERT_TRUE(copy_pubkey); EXPECT_EQ(1, EVP_PKEY_cmp(pkey.get(), copy_pubkey.get())); + + // Check again specifically with |X509_REQ_check_private_key|. + EXPECT_TRUE(X509_REQ_check_private_key(csr.get(), pkey.get())); } } }