-
Notifications
You must be signed in to change notification settings - Fork 73
Introduce an example using TLS #162
Comments
I’m hoping to get some full stack examples with tower-hyper (as a preview to using real hyper) including TLS. I think this is pending a tower-hyper release which @LucioFranco is leading. I will defer to him on this. |
@carllerche i think we need to figure out a |
Initial work is being worked on here tower-rs/tower-http#19 |
Can't wait to see this in. Currently have implemented a server but am blocked on client functionality because I can't figure out how to get TLS/ALPN working. I did see #101 (comment) but haven't had success plumbing this over. (TLS on the client, specifically, because on the server side gRPC will be sitting behind a proxy that handles that stuff already, which is how probably most people will deploy.) |
@davidvartan sorry this TLS work has taken a long time as we have been distracted moving to std::Future. What issues are you running into with TLS/ALPN? |
Thanks for the reply! So I'm using the example code (with the addition of |
So I'm not sure the http_connector from hyper does ALPN negotiation. That said, you should be able to use this example + |
The use of TLS connectors with tower-grpc seems to be a common sticking point for this library, see #59 and @ian-p-cooke's example https://github.com/ian-p-cooke/tower-grpc-tls-client-auth-example given in these issues though I've quite lost where. While it is clear that tower-grpc is not responsible for setting up a connector it's not entirely clear, at least to me, how a TlsStream should be hooked up into tower-grpc's machinery.
I've tried to cobble together an up to date example from bits and pieces I've found in conversations here and by reading project docs. You can find it here: https://github.com/blt/spike Unfortunately the client code doesn't compile yet and I don't have a ton of confidence that it would function if it did compile. I'd be interested in thoughts on what needs to change in spike to get it compiling.
Anyhow, would adding a TLS example to this project be a reasonable addition? I'd be happy to contribute something if there were an interest, but I'd need a touch of help.
The text was updated successfully, but these errors were encountered: