Skip to content

Commit

Permalink
fix: set headers for proxies
Browse files Browse the repository at this point in the history
  • Loading branch information
Threated committed Oct 14, 2024
1 parent 6cc7ecf commit 08ae06f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions proxy/src/serve_sockets.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,7 @@ async fn create_socket_con(
};
let (mut parts, body) = req.into_parts();
parts.headers.append(header::TRANSFER_ENCODING, HeaderValue::from_static("chunked"));
parts.headers.append(header::CONNECTION, HeaderValue::from_static("keep-alive"));
let stream = stream::once(ready(Ok(body))).chain(Encrypter::new(key).encrypt(og_req.into_body().into_data_stream()));
let req = Request::from_parts(parts, reqwest::Body::wrap_stream(stream));
match state.client.execute(req.try_into().expect("Conversion to reqwest::Request should always work")).await {
Expand Down

0 comments on commit 08ae06f

Please sign in to comment.