Reputation: 1217
I'm encountering an issue with gRPC SSL/TLS verification on Linux. I expected the following Python code to use the system's root certificates:
channel_credentials = grpc.ssl_channel_credentials(
root_certificates=None
)
However, I get the following error:
E0819 21:07:14.214747562 68815 ssl_transport_security.cc:1519] Handshake failed with fatal error SSL_ERROR_SSL: error:1000007d:SSL routines:OPENSSL_internal:CERTIFICATE_VERIFY_FAILED.
E0819 21:07:14.330714247 68817 ssl_transport_security.cc:1519] Handshake failed with fatal error SSL_ERROR_SSL: error:1000007d:SSL routines:OPENSSL_internal:CERTIFICATE_VERIFY_FAILED.
E0819 21:07:14.541603980 68822 ssl_transport_security.cc:1519] Handshake failed with fatal error SSL_ERROR_SSL: error:1000007d:SSL routines:OPENSSL_internal:CERTIFICATE_VERIFY_FAILED.
When I manually load the certificate, the connection works fine, which indicates the certificate is valid.
I've added the certificate to the system's trust store by copying it to /usr/local/share/ca-certificates/certificate.crt
and running update-ca-certificates
, but it seems gRPC isn't picking up the system certificates.
I'm on Linux and unsure what might be causing this issue. Is there something else I need to do to ensure gRPC uses the system's root certificates automatically?
I even tried it on Windows and got the same error.
Any help would be appreciated!
Upvotes: 0
Views: 44