beast
beast copied to clipboard
WSS Examples Currently Don't Set TLS SNI
Currently the WebSocket Secure examples (I only checked the sync/async client examples) don't set the TLS SNI on the ssl_stream
layer via the SSL_set_tlsext_host_name
function. This leads to errors in some handshakes, such as the necropost in issue #1702
Adding the following snippet should help with most users' use cases, I think:
// my_stream is a beast::websocket::stream
if (!SSL_set_tlsext_host_name(my_stream.next_layer().native_handle(), host))
{
// ...
}
Maybe we could also inform users of https://en.wikipedia.org/wiki/Server_Name_Indication#Security_implications in the example, though maybe it's out-of-scope to teach people the finer points of TLS?
This issue has been open for a while with no activity, has it been resolved?
There is a fix for this issue in the pipeline.
This issue has been open for a while with no activity, has it been resolved?
@madmongo1 where can I track that progress?
Addressed in https://github.com/boostorg/beast/pull/2019.