Error out if the default proof provider is unavailable This happens on open source QUICHE builds. PiperOrigin-RevId: 846396937
diff --git a/quiche/quic/masque/masque_client_bin.cc b/quiche/quic/masque/masque_client_bin.cc index c7a4b3d..0dfc958 100644 --- a/quiche/quic/masque/masque_client_bin.cc +++ b/quiche/quic/masque/masque_client_bin.cc
@@ -470,6 +470,12 @@ proof_verifier = std::make_unique<FakeProofVerifier>(); } else { proof_verifier = CreateDefaultProofVerifier(host); + if (!proof_verifier) { + QUICHE_LOG(ERROR) + << "The default proof verifier is not supported. Pass " + "in --disable_certificate_verification."; + return 1; + } } std::unique_ptr<ClientProofSource> proof_source;
diff --git a/quiche/quic/masque/masque_client_tools.cc b/quiche/quic/masque/masque_client_tools.cc index 74ec2ed..5210e80 100644 --- a/quiche/quic/masque/masque_client_tools.cc +++ b/quiche/quic/masque/masque_client_tools.cc
@@ -84,6 +84,11 @@ proof_verifier = std::make_unique<FakeProofVerifier>(); } else { proof_verifier = CreateDefaultProofVerifier(url.host()); + if (!proof_verifier) { + QUICHE_LOG(ERROR) << "The default proof verifier is not supported. Pass " + "in --disable_certificate_verification."; + return nullptr; + } } // Build the client, and try to connect.
diff --git a/quiche/quic/masque/masque_connection_pool.cc b/quiche/quic/masque/masque_connection_pool.cc index af5c7d4..afca6b9 100644 --- a/quiche/quic/masque/masque_connection_pool.cc +++ b/quiche/quic/masque/masque_connection_pool.cc
@@ -257,6 +257,10 @@ proof_verifier_ = std::make_unique<FakeProofVerifier>(); } else { proof_verifier_ = CreateDefaultProofVerifier(host_); + if (!proof_verifier_) { + QUICHE_LOG(FATAL) << "The default proof verifier is not supported. Pass " + "in --disable_certificate_verification."; + } } return true; }
diff --git a/quiche/quic/masque/masque_tcp_client_bin.cc b/quiche/quic/masque/masque_tcp_client_bin.cc index 5a0b4fd..5675dfe 100644 --- a/quiche/quic/masque/masque_tcp_client_bin.cc +++ b/quiche/quic/masque/masque_tcp_client_bin.cc
@@ -128,6 +128,12 @@ proof_verifier_ = std::make_unique<FakeProofVerifier>(); } else { proof_verifier_ = CreateDefaultProofVerifier(url_.host()); + if (!proof_verifier_) { + QUICHE_LOG(ERROR) + << "The default proof verifier is not supported. Pass " + "in --disable_certificate_verification."; + return false; + } } socket_address_ = tools::LookupAddress( address_family_for_lookup_, url_.host(), absl::StrCat(url_.port()));