@push.rocks/smartproxy 25.16.0 → 25.16.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/changelog.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2026-03-19 - 25.16.2 - fix(rustproxy-http)
|
|
4
|
+
cache backend Alt-Svc only from original upstream responses during protocol auto-detection
|
|
5
|
+
|
|
6
|
+
- Moves Alt-Svc discovery into streaming response construction so it reads backend headers before response filters inject client-facing Alt-Svc values
|
|
7
|
+
- Stores the protocol cache key in connection activity during auto-detect mode and clears it after HTTP/3 connection failure to avoid re-caching failed H3 routes
|
|
8
|
+
- Prevents fallback requests from reintroducing stale or self-injected Alt-Svc entries that could cause repeated H3 retry loops
|
|
9
|
+
|
|
10
|
+
## 2026-03-19 - 25.16.1 - fix(http-proxy)
|
|
11
|
+
avoid repeated HTTP/3 recaching after QUIC fallback and document backend protocol selection
|
|
12
|
+
|
|
13
|
+
- Suppress Alt-Svc HTTP/3 recaching after a failed QUIC backend connection to prevent repeated H3 timeout fallback loops
|
|
14
|
+
- Force an ALPN probe on TCP fallback so auto detection correctly reselects HTTP/2 or HTTP/1.1 after H3 connection failure
|
|
15
|
+
- Add README documentation for best-effort backendProtocol selection and supported protocol modes
|
|
16
|
+
|
|
3
17
|
## 2026-03-19 - 25.16.0 - feat(quic,http3)
|
|
4
18
|
add HTTP/3 proxy handling and hot-reload QUIC TLS configuration
|
|
5
19
|
|
|
Binary file
|
|
Binary file
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export const commitinfo = {
|
|
5
5
|
name: '@push.rocks/smartproxy',
|
|
6
|
-
version: '25.16.
|
|
6
|
+
version: '25.16.2',
|
|
7
7
|
description: 'A powerful proxy package with unified route-based configuration for high traffic management. Features include SSL/TLS support, flexible routing patterns, WebSocket handling, advanced security options, and automatic ACME certificate management.'
|
|
8
8
|
};
|
|
9
9
|
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMDBfY29tbWl0aW5mb19kYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvMDBfY29tbWl0aW5mb19kYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0sVUFBVSxHQUFHO0lBQ3hCLElBQUksRUFBRSx3QkFBd0I7SUFDOUIsT0FBTyxFQUFFLFNBQVM7SUFDbEIsV0FBVyxFQUFFLHFQQUFxUDtDQUNuUSxDQUFBIn0=
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@push.rocks/smartproxy",
|
|
3
|
-
"version": "25.16.
|
|
3
|
+
"version": "25.16.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "A powerful proxy package with unified route-based configuration for high traffic management. Features include SSL/TLS support, flexible routing patterns, WebSocket handling, advanced security options, and automatic ACME certificate management.",
|
|
6
6
|
"main": "dist_ts/index.js",
|
package/readme.md
CHANGED
|
@@ -328,6 +328,41 @@ const proxy = new SmartProxy({
|
|
|
328
328
|
});
|
|
329
329
|
```
|
|
330
330
|
|
|
331
|
+
### 🚄 Best-Effort Backend Protocol (H3 > H2 > H1)
|
|
332
|
+
|
|
333
|
+
SmartProxy automatically uses the **highest protocol your backend supports** for HTTP requests. The backend protocol is independent of the client protocol — a client using HTTP/1.1 can be forwarded over HTTP/3 to the backend, and vice versa.
|
|
334
|
+
|
|
335
|
+
```typescript
|
|
336
|
+
const route: IRouteConfig = {
|
|
337
|
+
name: 'auto-protocol',
|
|
338
|
+
match: { ports: 443, domains: 'app.example.com' },
|
|
339
|
+
action: {
|
|
340
|
+
type: 'forward',
|
|
341
|
+
targets: [{ host: 'backend', port: 8443 }],
|
|
342
|
+
tls: { mode: 'terminate', certificate: 'auto' },
|
|
343
|
+
options: {
|
|
344
|
+
backendProtocol: 'auto' // 👈 Default — best-effort selection
|
|
345
|
+
}
|
|
346
|
+
}
|
|
347
|
+
};
|
|
348
|
+
```
|
|
349
|
+
|
|
350
|
+
**How protocol discovery works (browser model):**
|
|
351
|
+
|
|
352
|
+
1. First request → TLS ALPN probe detects H2 or H1
|
|
353
|
+
2. Backend response inspected for `Alt-Svc: h3=":port"` header
|
|
354
|
+
3. If H3 advertised → cached and used for subsequent requests via QUIC
|
|
355
|
+
4. Graceful fallback: H3 failure → H2 → H1 with automatic cache invalidation
|
|
356
|
+
|
|
357
|
+
| `backendProtocol` | Behavior |
|
|
358
|
+
|---|---|
|
|
359
|
+
| `'auto'` (default) | Best-effort: H3 > H2 > H1 with Alt-Svc discovery |
|
|
360
|
+
| `'http1'` | Always HTTP/1.1 |
|
|
361
|
+
| `'http2'` | Always HTTP/2 (hard-fail if unsupported) |
|
|
362
|
+
| `'http3'` | Always HTTP/3 via QUIC (hard-fail if unsupported) |
|
|
363
|
+
|
|
364
|
+
> **Note:** WebSocket upgrades always use HTTP/1.1 to the backend regardless of `backendProtocol`, since there's no performance benefit from H2/H3 Extended CONNECT for tunneled connections, and backend support is rare.
|
|
365
|
+
|
|
331
366
|
### 🔁 Dual-Stack TCP + UDP Route
|
|
332
367
|
|
|
333
368
|
Listen on both TCP and UDP with a single route — handle each transport with its own handler:
|
|
@@ -776,6 +811,28 @@ interface IRouteLoadBalancing {
|
|
|
776
811
|
}
|
|
777
812
|
```
|
|
778
813
|
|
|
814
|
+
### Backend Protocol Options
|
|
815
|
+
|
|
816
|
+
```typescript
|
|
817
|
+
// Set on action.options
|
|
818
|
+
{
|
|
819
|
+
action: {
|
|
820
|
+
type: 'forward',
|
|
821
|
+
targets: [...],
|
|
822
|
+
options: {
|
|
823
|
+
backendProtocol: 'auto' | 'http1' | 'http2' | 'http3'
|
|
824
|
+
}
|
|
825
|
+
}
|
|
826
|
+
}
|
|
827
|
+
```
|
|
828
|
+
|
|
829
|
+
| Value | Backend Behavior |
|
|
830
|
+
|-------|-----------------|
|
|
831
|
+
| `'auto'` | Best-effort: discovers H3 via Alt-Svc, probes H2 via ALPN, falls back to H1 |
|
|
832
|
+
| `'http1'` | Always HTTP/1.1 (no ALPN probe) |
|
|
833
|
+
| `'http2'` | Always HTTP/2 (hard-fail if handshake fails) |
|
|
834
|
+
| `'http3'` | Always HTTP/3 over QUIC (3s connect timeout, hard-fail if unreachable) |
|
|
835
|
+
|
|
779
836
|
### UDP & QUIC Options
|
|
780
837
|
|
|
781
838
|
```typescript
|
package/ts/00_commitinfo_data.ts
CHANGED
|
@@ -3,6 +3,6 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export const commitinfo = {
|
|
5
5
|
name: '@push.rocks/smartproxy',
|
|
6
|
-
version: '25.16.
|
|
6
|
+
version: '25.16.2',
|
|
7
7
|
description: 'A powerful proxy package with unified route-based configuration for high traffic management. Features include SSL/TLS support, flexible routing patterns, WebSocket handling, advanced security options, and automatic ACME certificate management.'
|
|
8
8
|
}
|