google / google/ml-metadata

Trouble connecting to gRPC server with secure channel

Open
#71 5 comments 1 reaction 0 assignees View on GitHub
Dominant language
C++
Stars
685
Forks
185
PR merge metrics
No merged PRs in 30d

Description

Hi, I want to use the built in ssl in the MetadataStoreServerConfig to secure the channel, but after passing in cert and launching the server, my client can no longer connect to the server. It fails with the following error:

```
~/.pex/install/grpcio-1.32.0-cp37-cp37m-linux_x86_64.whl.b02a34f09fd3663c27b2a62a6c1b4ea3ed2c602b/grpcio-1.32.0-cp37-cp37m-linux_x86_64.whl/grpc/_channel.py in __call__(self, request, timeout, metadata, credentials, wait_for_ready, compression)
824 state, call, = self._blocking(request, timeout, metadata, credentials,
825 wait_for_ready, compression)
--> 826 return _end_unary_response_blocking(state, call, False, None)
827
828 def with_call(self,

~/.pex/install/grpcio-1.32.0-cp37-cp37m-linux_x86_64.whl.b02a34f09fd3663c27b2a62a6c1b4ea3ed2c602b/grpcio-1.32.0-cp37-cp37m-linux_x86_64.whl/grpc/_channel.py in _end_unary_response_blocking(state, call, with_call, deadline)
727 return state.response
728 else:
--> 729 raise _InactiveRpcError(state)
730
731

_InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
status = StatusCode.UNAVAILABLE
details = "failed to connect to all addresses"
debug_error_string = "{"created":"@1603218554.257270012","description":"Failed to pick subchannel","file":"src/core/ext/filters/client_channel/client_channel.cc","file_line":4133,"referenced_errors":[{"created":"@1603218460.778569046","description":"failed to connect to all addresses","file":"src/core/ext/filters/client_channel/lb_policy/pick_first/pick_first.cc","file_line":397,"grpc_status":14}]}"
```
Upon changing client values for certs, I get this error:
```
_InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
status = StatusCode.UNAVAILABLE
details = "Empty Update"
```

On the server side, I get the following error message:
`170490 ssl_transport_security.cc:1239] Handshake failed with fatal error SSL_ERROR_SSL: error:100000f7:SSL routines:OPENSSL_internal:WRONG_VERSION_NUMBER.`

I have tried many different things to make it work, and can provide answers to all the follow up questions this. I have been struggling with this issue for a while now, not sure what's going wrong here.

Using `openssl s_client -connect host:port`, I am able to connect to the server, it's the python ml-metadata store client which is having trouble connecting.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.