sliccy 6.96.4 → 6.96.6
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/dist/node-server/bridge-security.js +6 -0
- package/dist/node-server/fetch-proxy-headers.d.ts +18 -2
- package/dist/node-server/fetch-proxy-headers.js +39 -4
- package/dist/node-server/routes/fetch-proxy.js +12 -1
- package/dist/ui/.vite/manifest.json +132 -132
- package/dist/ui/assets/SKILL-BCDMrL-b.js +1 -0
- package/dist/ui/assets/{account-store-CCKUJ4ge.js → account-store-DRj2SDg8.js} +1 -1
- package/dist/ui/assets/{account-store-DNHiaFJE.js → account-store-f_5Y3loE.js} +1 -1
- package/dist/ui/assets/{adobe-ChIBeQy8.js → adobe-BaKxV1Cm.js} +1 -1
- package/dist/ui/assets/{adobe-D9gzgSMY.js → adobe-DPqPVXTP.js} +1 -1
- package/dist/ui/assets/{apply-layout-BYNMmQ2A.js → apply-layout-Sl4iOs_f.js} +1 -1
- package/dist/ui/assets/{apps-BTXuGdF5.js → apps-BRfZSCY-.js} +1 -1
- package/dist/ui/assets/{azure-openai-BOCtD00s.js → azure-openai-BDGu5Z5A.js} +1 -1
- package/dist/ui/assets/{azure-openai-D6mfW32f.js → azure-openai-D6hCRHFS.js} +1 -1
- package/dist/ui/assets/{cerebras-9vVsMtpx.js → cerebras-BNuGY5Ld.js} +1 -1
- package/dist/ui/assets/{cerebras-xACPHJt5.js → cerebras-DEmdsUe4.js} +1 -1
- package/dist/ui/assets/{connect-surface-iUF4mFkU.js → connect-surface-C1tEQKLv.js} +1 -1
- package/dist/ui/assets/{fs-p11iQ-3k.js → fs-CfQp9efi.js} +2 -2
- package/dist/ui/assets/{fs-BOhjDrbI.js → fs-ChobgFEy.js} +1 -1
- package/dist/ui/assets/{github-ChJr1NBx.js → github-DUTugm3d.js} +1 -1
- package/dist/ui/assets/{github-copilot-Dz9cMkle.js → github-copilot-C101PYye.js} +1 -1
- package/dist/ui/assets/{github-copilot-CugymeLI.js → github-copilot-iVypX4UI.js} +1 -1
- package/dist/ui/assets/{github-install-Bnv462s_.js → github-install-BrTBTu2h.js} +1 -1
- package/dist/ui/assets/{github-CeKa_YoJ.js → github-n1RJGQHw.js} +2 -2
- package/dist/ui/assets/{github-zip-BmdjNKOq.js → github-zip-Ch3k6-sU.js} +1 -1
- package/dist/ui/assets/{js-realm-worker-BgF1E62V.js → js-realm-worker-CSuRptA4.js} +1 -1
- package/dist/ui/assets/{kernel-worker-BM4k_Mq_.js → kernel-worker-DA5hRJup.js} +30 -30
- package/dist/ui/assets/{local-llm-DWKa_3BZ.js → local-llm-Bp0r9Ihd.js} +1 -1
- package/dist/ui/assets/{local-llm-DP54TeOF.js → local-llm-DV5e3ywb.js} +1 -1
- package/dist/ui/assets/{main-CfMjfj4c.js → main-C6rR0w1B.js} +3 -3
- package/dist/ui/assets/{mount-B7OZ-qqc.js → mount-CApaXxHd.js} +2 -2
- package/dist/ui/assets/{mount-hjgE1SBL.js → mount-DuGV4gCw.js} +1 -1
- package/dist/ui/assets/{mount-recovery-BI-fVIQh.js → mount-recovery-CniXIkTB.js} +1 -1
- package/dist/ui/assets/{new-session-BYOnwOXr.js → new-session-CMaZ3GOC.js} +2 -2
- package/dist/ui/assets/{oauth-bootstrap-BJGdx242.js → oauth-bootstrap-k6EdFR1N.js} +2 -2
- package/dist/ui/assets/{openai-codex-bsR-NUrt.js → openai-codex-DXTTx20O.js} +1 -1
- package/dist/ui/assets/{openai-codex-BmtQpGAy.js → openai-codex-LPnPLUIv.js} +1 -1
- package/dist/ui/assets/{openrouter-BIGJTAft.js → openrouter-CmmwIHPt.js} +1 -1
- package/dist/ui/assets/{openrouter-3jV1AeTR.js → openrouter-DyEZMa_B.js} +1 -1
- package/dist/ui/assets/{openrouter-oauth-BifFmgDz.js → openrouter-oauth-C5YDWZza.js} +1 -1
- package/dist/ui/assets/{openrouter-oauth-BjZyQkXX.js → openrouter-oauth-CtAjoPMF.js} +1 -1
- package/dist/ui/assets/{panel-rpc-handlers-DvIejPh8.js → panel-rpc-handlers-D25baSPS.js} +2 -2
- package/dist/ui/assets/{panelize-shell-C2n0OG-k.js → panelize-shell-COz1Z7LB.js} +1 -1
- package/dist/ui/assets/{provider-Dse-s6lF.js → provider-Cy1-3xDc.js} +2 -2
- package/dist/ui/assets/{provider-CAkXxgvX.js → provider-lR4XaVo1.js} +1 -1
- package/dist/ui/assets/{provider-settings-DmMxRhIP.js → provider-settings-B_Av8-kE.js} +1 -1
- package/dist/ui/assets/{provider-settings-CnqPrGj-.js → provider-settings-DvBcrGSB.js} +1 -1
- package/dist/ui/assets/provider-store-access-BYG_vWXq.js +1 -0
- package/dist/ui/assets/{provider-store-access-RCssR_-b.js → provider-store-access-Dm9fer4P.js} +2 -2
- package/dist/ui/assets/{providers-Lvr_kwE3.js → providers-DMRr-d6b.js} +1 -1
- package/dist/ui/assets/{providers-hAtFQPTZ.js → providers-De4bg3HH.js} +2 -2
- package/dist/ui/assets/{quick-llm-BnASRrSi.js → quick-llm-DMWkcwCn.js} +1 -1
- package/dist/ui/assets/{recovery-screen-CMJdkCU-.js → recovery-screen-B33brCeF.js} +1 -1
- package/dist/ui/assets/{redirect-uri-B_tPO0rL.js → redirect-uri-DAG9cXSm.js} +1 -1
- package/dist/ui/assets/{session-freezer-oBR8W8ed.js → session-freezer-BxNDkAZg.js} +3 -3
- package/dist/ui/assets/{setup-feature-flags-remote-Bt8QE81j.js → setup-feature-flags-remote-BGZFr89t.js} +1 -1
- package/dist/ui/assets/{setup-standalone-prelude-MfnCRaqV.js → setup-standalone-prelude-DEhT6zS-.js} +1 -1
- package/dist/ui/assets/{setup-sudo-B17RSZcJ.js → setup-sudo-BD3B0lOG.js} +2 -2
- package/dist/ui/assets/{skills-DH5JJQCz.js → skills-BIpfkJWi.js} +1 -1
- package/dist/ui/assets/slicc-version-Ak3sAJAN.js +1 -0
- package/dist/ui/assets/{src-Bw7lN3n5.js → src-CG9Sp0SZ.js} +80 -76
- package/dist/ui/assets/{store-Bll-_FQw.js → store-Dl7CDFTf.js} +1 -1
- package/dist/ui/assets/{store-Yo1YLTQ2.js → store-pShZ-44M.js} +1 -1
- package/dist/ui/assets/{sudo-Cd1lq7Ra.js → sudo-CQOJDuEr.js} +1 -1
- package/dist/ui/assets/{upgrade-detection-D5v0RaIF.js → upgrade-detection-o_fxk_9R.js} +1 -1
- package/dist/ui/assets/{wc-attach-CtIH1DsM.js → wc-attach-BbEnzTrf.js} +2 -2
- package/dist/ui/assets/{wc-extension-B-i04xyf.js → wc-extension-iLGxpkq2.js} +2 -2
- package/dist/ui/assets/{wc-float-label-Bj-0-MZA.js → wc-float-label-BATxvSb5.js} +1 -1
- package/dist/ui/assets/{wc-floatbar-online-Do-_H9l4.js → wc-floatbar-online-Dogbrrqe.js} +1 -1
- package/dist/ui/assets/{wc-follower-ZYKc5Ngx.js → wc-follower-ouRFKSCy.js} +3 -3
- package/dist/ui/assets/{wc-live-BZ6K2oFF.js → wc-live-ClwxmXsg.js} +4 -4
- package/dist/ui/assets/{wc-nav-Dx9PQgcL.js → wc-nav-Ck57tmuN.js} +2 -2
- package/dist/ui/assets/{wc-onboarding-CMR8g6kB.js → wc-onboarding-CCJ1abTB.js} +2 -2
- package/dist/ui/assets/{wc-placeholder-CSxAzoAY.js → wc-placeholder-Du-3aOoc.js} +2 -2
- package/dist/ui/assets/{wc-settings--E4BUh2C.js → wc-settings-B9elNpIP.js} +2 -2
- package/dist/ui/assets/{wc-shell-BMEagEUk.js → wc-shell-DcossCvn.js} +3 -3
- package/dist/ui/assets/{wc-sprinkles-CgSplLen.js → wc-sprinkles-CGBq_Unu.js} +2 -2
- package/dist/ui/assets/{wc-tray-D7hcyDlz.js → wc-tray-BSghTy-9.js} +2 -2
- package/dist/ui/assets/{xai-grok-CJOfI1UD.js → xai-grok-BqZBRbDW.js} +1 -1
- package/dist/ui/assets/{xai-grok-C3BzCcaL.js → xai-grok-CAWad06z.js} +1 -1
- package/dist/ui/index.html +6 -6
- package/dist/ui/packages/webapp/index.html +6 -6
- package/package.json +1 -1
- package/dist/ui/assets/SKILL-DhKtVqb-.js +0 -1
- package/dist/ui/assets/provider-store-access-BOwZ1eu6.js +0 -1
- package/dist/ui/assets/slicc-version-CUg0SEkq.js +0 -1
|
@@ -111,6 +111,12 @@ const CORS_BASE_ALLOW_HEADERS = [
|
|
|
111
111
|
* (`isProxyError` reads `X-Proxy-Error`) and the forbidden-response
|
|
112
112
|
* bridge (`decodeForbiddenResponseHeaders` reads `X-Proxy-Set-Cookie`). MCP
|
|
113
113
|
* clients also read protocol negotiation/session headers from proxy responses.
|
|
114
|
+
*
|
|
115
|
+
* `/api/fetch-proxy` overrides this per-response with the union of this base
|
|
116
|
+
* set and every forwarded upstream header name (see
|
|
117
|
+
* `buildFetchProxyExposeHeaders`) so agents can inspect non-CORS-safelisted
|
|
118
|
+
* headers such as Content-Security-Policy. Other `/api/*` routes keep this
|
|
119
|
+
* static list.
|
|
114
120
|
*/
|
|
115
121
|
const CORS_EXPOSE_HEADERS = 'Link, X-Proxy-Error, X-Proxy-Set-Cookie, X-Proxy-Content-Length, Mcp-Session-Id, MCP-Protocol-Version';
|
|
116
122
|
/**
|
|
@@ -42,11 +42,27 @@ export declare const FETCH_PROXY_SKIP_RESPONSE_HEADERS: ReadonlySet<string>;
|
|
|
42
42
|
* middleware remains the sole CORS authority. `x-proxy-` is the proxy's
|
|
43
43
|
* own response-marker namespace — never echo an upstream value.
|
|
44
44
|
*/
|
|
45
|
+
export declare const FETCH_PROXY_SKIP_RESPONSE_PREFIXES: readonly string[];
|
|
45
46
|
/**
|
|
46
47
|
* Proxy-set response header carrying the upstream `content-length` when it is
|
|
47
48
|
* exact (identity encoding). Read by the webapp's `proxied-fetch.ts` to drive
|
|
48
49
|
* determinate download progress; never copied from upstream (the `x-proxy-`
|
|
49
|
-
* prefix
|
|
50
|
+
* prefix above guarantees that).
|
|
50
51
|
*/
|
|
51
52
|
export declare const FETCH_PROXY_CONTENT_LENGTH_HEADER = "X-Proxy-Content-Length";
|
|
52
|
-
|
|
53
|
+
/**
|
|
54
|
+
* Response headers the browser must always be allowed to read on the
|
|
55
|
+
* `/api/fetch-proxy` hop, even when the upstream response carries none of
|
|
56
|
+
* them. Kept in sync with `CORS_EXPOSE_HEADERS` in `bridge-security.ts` and
|
|
57
|
+
* `BridgeSecurity.corsExposeHeaders` in the Swift server. The route appends
|
|
58
|
+
* every forwarded upstream header name on top of this base so agents can
|
|
59
|
+
* inspect CSP / HSTS / ETag / etc. — browsers only surface non-CORS-safelisted
|
|
60
|
+
* response headers when they appear here (credentials mode forbids `*`).
|
|
61
|
+
*/
|
|
62
|
+
export declare const FETCH_PROXY_BASE_EXPOSE_HEADERS: readonly string[];
|
|
63
|
+
/**
|
|
64
|
+
* Build the `Access-Control-Expose-Headers` value for a proxied response:
|
|
65
|
+
* the static proxy markers plus every header name we actually forwarded.
|
|
66
|
+
* Dedupes case-insensitively while preserving the first-seen spelling.
|
|
67
|
+
*/
|
|
68
|
+
export declare function buildFetchProxyExposeHeaders(forwardedHeaderNames: Iterable<string>): string;
|
|
@@ -65,14 +65,49 @@ export const FETCH_PROXY_SKIP_RESPONSE_HEADERS = new Set([
|
|
|
65
65
|
* middleware remains the sole CORS authority. `x-proxy-` is the proxy's
|
|
66
66
|
* own response-marker namespace — never echo an upstream value.
|
|
67
67
|
*/
|
|
68
|
+
export const FETCH_PROXY_SKIP_RESPONSE_PREFIXES = [
|
|
69
|
+
'access-control-',
|
|
70
|
+
'x-proxy-',
|
|
71
|
+
];
|
|
68
72
|
/**
|
|
69
73
|
* Proxy-set response header carrying the upstream `content-length` when it is
|
|
70
74
|
* exact (identity encoding). Read by the webapp's `proxied-fetch.ts` to drive
|
|
71
75
|
* determinate download progress; never copied from upstream (the `x-proxy-`
|
|
72
|
-
* prefix
|
|
76
|
+
* prefix above guarantees that).
|
|
73
77
|
*/
|
|
74
78
|
export const FETCH_PROXY_CONTENT_LENGTH_HEADER = 'X-Proxy-Content-Length';
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
79
|
+
/**
|
|
80
|
+
* Response headers the browser must always be allowed to read on the
|
|
81
|
+
* `/api/fetch-proxy` hop, even when the upstream response carries none of
|
|
82
|
+
* them. Kept in sync with `CORS_EXPOSE_HEADERS` in `bridge-security.ts` and
|
|
83
|
+
* `BridgeSecurity.corsExposeHeaders` in the Swift server. The route appends
|
|
84
|
+
* every forwarded upstream header name on top of this base so agents can
|
|
85
|
+
* inspect CSP / HSTS / ETag / etc. — browsers only surface non-CORS-safelisted
|
|
86
|
+
* response headers when they appear here (credentials mode forbids `*`).
|
|
87
|
+
*/
|
|
88
|
+
export const FETCH_PROXY_BASE_EXPOSE_HEADERS = [
|
|
89
|
+
'Link',
|
|
90
|
+
'X-Proxy-Error',
|
|
91
|
+
'X-Proxy-Set-Cookie',
|
|
92
|
+
FETCH_PROXY_CONTENT_LENGTH_HEADER,
|
|
93
|
+
'Mcp-Session-Id',
|
|
94
|
+
'MCP-Protocol-Version',
|
|
95
|
+
'Cache-Control',
|
|
78
96
|
];
|
|
97
|
+
/**
|
|
98
|
+
* Build the `Access-Control-Expose-Headers` value for a proxied response:
|
|
99
|
+
* the static proxy markers plus every header name we actually forwarded.
|
|
100
|
+
* Dedupes case-insensitively while preserving the first-seen spelling.
|
|
101
|
+
*/
|
|
102
|
+
export function buildFetchProxyExposeHeaders(forwardedHeaderNames) {
|
|
103
|
+
const seen = new Set();
|
|
104
|
+
const out = [];
|
|
105
|
+
for (const name of [...FETCH_PROXY_BASE_EXPOSE_HEADERS, ...forwardedHeaderNames]) {
|
|
106
|
+
const lower = name.toLowerCase();
|
|
107
|
+
if (seen.has(lower))
|
|
108
|
+
continue;
|
|
109
|
+
seen.add(lower);
|
|
110
|
+
out.push(name);
|
|
111
|
+
}
|
|
112
|
+
return out.join(', ');
|
|
113
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Readable, Transform } from 'node:stream';
|
|
2
2
|
import { StringDecoder } from 'node:string_decoder';
|
|
3
3
|
import { HMAC_SIGN_HEADER, isLoopbackOrigin, isTextContentType } from '../_shared/index.js';
|
|
4
|
-
import { FETCH_PROXY_CONTENT_LENGTH_HEADER, FETCH_PROXY_SKIP_HEADERS, FETCH_PROXY_SKIP_RESPONSE_HEADERS, FETCH_PROXY_SKIP_RESPONSE_PREFIXES, } from '../fetch-proxy-headers.js';
|
|
4
|
+
import { buildFetchProxyExposeHeaders, FETCH_PROXY_CONTENT_LENGTH_HEADER, FETCH_PROXY_SKIP_HEADERS, FETCH_PROXY_SKIP_RESPONSE_HEADERS, FETCH_PROXY_SKIP_RESPONSE_PREFIXES, } from '../fetch-proxy-headers.js';
|
|
5
5
|
import { AgentActivityTracker, registerAgentActivityRoute } from './agent-activity.js';
|
|
6
6
|
/** Pick the first value of a possibly-multi-valued request header. */
|
|
7
7
|
function firstHeaderValue(value) {
|
|
@@ -141,10 +141,17 @@ function unmaskRequestBody(secretProxy, headers, rawBody, targetHostname) {
|
|
|
141
141
|
* middleware remains the sole authority on the browser→bridge hop —
|
|
142
142
|
* see `FETCH_PROXY_SKIP_RESPONSE_HEADERS` / `..._PREFIXES`. All header
|
|
143
143
|
* values are secret-scrubbed.
|
|
144
|
+
*
|
|
145
|
+
* After forwarding, set `Access-Control-Expose-Headers` to the union of the
|
|
146
|
+
* proxy markers and every forwarded header name. Cross-origin thin-bridge
|
|
147
|
+
* callers (sliccy.ai → localhost) run under credentials mode, so the
|
|
148
|
+
* browser otherwise only surfaces CORS-safelisted headers and agents
|
|
149
|
+
* silently miss CSP / HSTS / X-Frame-Options / ETag / etc.
|
|
144
150
|
*/
|
|
145
151
|
function forwardUpstreamHeaders(res, upstream, secretProxy) {
|
|
146
152
|
res.status(upstream.status);
|
|
147
153
|
res.setHeader('Cache-Control', 'no-store, no-cache');
|
|
154
|
+
const forwardedNames = [];
|
|
148
155
|
const setCookieValues = upstream.headers.getSetCookie();
|
|
149
156
|
upstream.headers.forEach((v, k) => {
|
|
150
157
|
const lower = k.toLowerCase();
|
|
@@ -154,6 +161,7 @@ function forwardUpstreamHeaders(res, upstream, secretProxy) {
|
|
|
154
161
|
return;
|
|
155
162
|
// Headers are small — one-shot scrub, no per-chunk semantics.
|
|
156
163
|
res.setHeader(k, secretProxy.scrubResponse(v));
|
|
164
|
+
forwardedNames.push(k);
|
|
157
165
|
});
|
|
158
166
|
if (setCookieValues.length > 0) {
|
|
159
167
|
res.setHeader('X-Proxy-Set-Cookie', secretProxy.scrubResponse(JSON.stringify(setCookieValues)));
|
|
@@ -175,6 +183,9 @@ function forwardUpstreamHeaders(res, upstream, secretProxy) {
|
|
|
175
183
|
if (upstreamLength && !upstream.headers.get('content-encoding') && /^\d+$/.test(upstreamLength)) {
|
|
176
184
|
res.setHeader(FETCH_PROXY_CONTENT_LENGTH_HEADER, upstreamLength);
|
|
177
185
|
}
|
|
186
|
+
// Override the thin-bridge middleware's static expose list with the
|
|
187
|
+
// full set for this response. Credentials mode forbids `*`.
|
|
188
|
+
res.setHeader('Access-Control-Expose-Headers', buildFetchProxyExposeHeaders(forwardedNames));
|
|
178
189
|
}
|
|
179
190
|
/**
|
|
180
191
|
* Buffer-aware UTF-8 secret scrubber. A `StringDecoder` keeps trailing partial
|