mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 19:59:17 +00:00
LibTLS: Replace TLSv12
implementation with OpenSSL
This commit is contained in:
parent
d6e9d2cdbb
commit
7a38a3e994
Notes:
github-actions[bot]
2025-02-17 18:53:51 +00:00
Author: https://github.com/devgianlu
Commit: 7a38a3e994
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3571
Reviewed-by: https://github.com/ADKaster
Reviewed-by: https://github.com/alimpfard ✅
15 changed files with 182 additions and 4709 deletions
|
@ -45,13 +45,8 @@ void WebSocketImplSerenity::connect(ConnectionInfo const& connection_info)
|
|||
auto socket_result = [&]() -> ErrorOr<NonnullOwnPtr<Core::BufferedSocketBase>> {
|
||||
auto host = connection_info.url().serialized_host().to_byte_string();
|
||||
if (connection_info.is_secure()) {
|
||||
TLS::Options options;
|
||||
options.set_alert_handler([this](auto) {
|
||||
on_connection_error();
|
||||
});
|
||||
|
||||
return TRY(Core::BufferedSocket<TLS::TLSv12>::create(
|
||||
TRY(TLS::TLSv12::connect(host, connection_info.url().port_or_default(), move(options)))));
|
||||
TRY(TLS::TLSv12::connect(host, connection_info.url().port_or_default()))));
|
||||
}
|
||||
|
||||
return TRY(Core::BufferedTCPSocket::create(
|
||||
|
@ -66,6 +61,7 @@ void WebSocketImplSerenity::connect(ConnectionInfo const& connection_info)
|
|||
}
|
||||
|
||||
m_socket = socket_result.release_value();
|
||||
MUST(m_socket->set_blocking(false));
|
||||
|
||||
m_socket->on_ready_to_read = [this] {
|
||||
on_ready_to_read();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue