mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 12:47:35 +00:00
headless-browser: Use port 443 as default for HTTPS requests
This commit is contained in:
parent
f33df0ee05
commit
9c431ede7a
1 changed files with 1 additions and 1 deletions
|
@ -365,7 +365,7 @@ public:
|
||||||
static ErrorOr<NonnullRefPtr<HTTPSHeadlessRequest>> create(String const& method, AK::URL const& url, HashMap<String, String> const& request_headers, ReadonlyBytes request_body, Core::ProxyData const&)
|
static ErrorOr<NonnullRefPtr<HTTPSHeadlessRequest>> create(String const& method, AK::URL const& url, HashMap<String, String> const& request_headers, ReadonlyBytes request_body, Core::ProxyData const&)
|
||||||
{
|
{
|
||||||
auto stream_backing_buffer = TRY(ByteBuffer::create_uninitialized(1 * MiB));
|
auto stream_backing_buffer = TRY(ByteBuffer::create_uninitialized(1 * MiB));
|
||||||
auto underlying_socket = TRY(TLS::TLSv12::connect(url.host(), url.port().value_or(80)));
|
auto underlying_socket = TRY(TLS::TLSv12::connect(url.host(), url.port().value_or(443)));
|
||||||
TRY(underlying_socket->set_blocking(false));
|
TRY(underlying_socket->set_blocking(false));
|
||||||
auto socket = TRY(Core::Stream::BufferedSocket<TLS::TLSv12>::create(move(underlying_socket)));
|
auto socket = TRY(Core::Stream::BufferedSocket<TLS::TLSv12>::create(move(underlying_socket)));
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue