Skip to content

Commit c7dcd4c

Browse files
committed
fix(webhooks): enforce HTTP/1.1 in op_proxy_request
1 parent 71e2f70 commit c7dcd4c

3 files changed

Lines changed: 9 additions & 2 deletions

File tree

.cargo/config.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,7 @@
11
[target.'cfg(all())']
22
rustflags = ["--cfg", "uuid_unstable"]
3+
4+
[env]
5+
# Limit test parallelism to avoid exceeding PostgreSQL's max_connections (default 100).
6+
# Each #[sqlx::test] gets a pool of up to 5 connections plus 20 for the master pool.
7+
RUST_TEST_THREADS = "5"

components/secutils-docs/docs/guides/platform/deno_runtime.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,7 @@ By default, `op_proxy_request` only allows requests to **publicly routable** IP
351351
:::
352352

353353
:::info Limits
354-
Each responder has a maximum number of concurrent proxy requests it can handle simultaneously (configurable per subscription tier). When the limit is reached, additional requests receive a `429 Too Many Requests` response with a `Retry-After` header. The upstream response body size is also limited (default: 10 MB) to prevent memory exhaustion. Every proxy request has a timeout (default: 30 s) that can be lowered per-request via the `timeout` field but cannot exceed the server-configured maximum.
354+
Each responder has a maximum number of concurrent proxy requests it can handle simultaneously (configurable per subscription tier). When the limit is reached, additional requests receive a `429 Too Many Requests` response with a `Retry-After` header. The upstream response body size is also limited (default: 10 MB) to prevent memory exhaustion. Every proxy request has a timeout (default: 30 s) that can be lowered per-request via the `timeout` field but cannot exceed the server-configured maximum. All proxy requests use **HTTP/1.1** - HTTP/2 is not supported.
355355
:::
356356

357357
:::tip Response tracking

src/js_runtime/op_proxy_request.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,9 @@ impl ProxyState {
6262
&self.client
6363
};
6464
cell.get_or_init(|| {
65-
let mut builder = reqwest::Client::builder().redirect(RedirectPolicy::none());
65+
let mut builder = reqwest::Client::builder()
66+
.redirect(RedirectPolicy::none())
67+
.http1_only();
6668
if insecure {
6769
builder = builder.danger_accept_invalid_certs(true);
6870
}

0 commit comments

Comments
 (0)