@f5-sales-demo/xcsh 19.98.8 → 19.98.10

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@f5-sales-demo/xcsh",
4
- "version": "19.98.8",
4
+ "version": "19.98.10",
5
5
  "description": "Coding agent CLI with read, bash, edit, write tools and session management",
6
6
  "homepage": "https://github.com/f5-sales-demo/xcsh",
7
7
  "author": "Can Boluk",
@@ -57,13 +57,13 @@
57
57
  "dependencies": {
58
58
  "@agentclientprotocol/sdk": "1.3.0",
59
59
  "@mozilla/readability": "^0.6",
60
- "@f5-sales-demo/xcsh-stats": "19.98.8",
61
- "@f5-sales-demo/pi-agent-core": "19.98.8",
62
- "@f5-sales-demo/pi-ai": "19.98.8",
63
- "@f5-sales-demo/pi-natives": "19.98.8",
64
- "@f5-sales-demo/pi-resource-management": "19.98.8",
65
- "@f5-sales-demo/pi-tui": "19.98.8",
66
- "@f5-sales-demo/pi-utils": "19.98.8",
60
+ "@f5-sales-demo/xcsh-stats": "19.98.10",
61
+ "@f5-sales-demo/pi-agent-core": "19.98.10",
62
+ "@f5-sales-demo/pi-ai": "19.98.10",
63
+ "@f5-sales-demo/pi-natives": "19.98.10",
64
+ "@f5-sales-demo/pi-resource-management": "19.98.10",
65
+ "@f5-sales-demo/pi-tui": "19.98.10",
66
+ "@f5-sales-demo/pi-utils": "19.98.10",
67
67
  "@sinclair/typebox": "^0.34",
68
68
  "@xterm/headless": "^6.0",
69
69
  "ajv": "^8.20",
@@ -17,17 +17,17 @@ export interface BuildInfo {
17
17
  }
18
18
 
19
19
  export const BUILD_INFO: BuildInfo = {
20
- "version": "19.98.8",
21
- "commit": "8d1e4f3e9673585d8835fd45b7b6eb7c0f21b529",
22
- "shortCommit": "8d1e4f3",
20
+ "version": "19.98.10",
21
+ "commit": "8523f605f109087c188c50d82aa0d20add2e7544",
22
+ "shortCommit": "8523f60",
23
23
  "branch": "main",
24
- "tag": "v19.98.8",
25
- "commitDate": "2026-07-28T13:27:14Z",
26
- "buildDate": "2026-07-28T13:48:35.687Z",
24
+ "tag": "v19.98.10",
25
+ "commitDate": "2026-07-28T14:58:14Z",
26
+ "buildDate": "2026-07-28T15:23:24.282Z",
27
27
  "dirty": true,
28
28
  "prNumber": "",
29
29
  "repoUrl": "https://github.com/f5-sales-demo/xcsh",
30
30
  "repoSlug": "f5-sales-demo/xcsh",
31
- "commitUrl": "https://github.com/f5-sales-demo/xcsh/commit/8d1e4f3e9673585d8835fd45b7b6eb7c0f21b529",
32
- "releaseUrl": "https://github.com/f5-sales-demo/xcsh/releases/tag/v19.98.8"
31
+ "commitUrl": "https://github.com/f5-sales-demo/xcsh/commit/8523f605f109087c188c50d82aa0d20add2e7544",
32
+ "releaseUrl": "https://github.com/f5-sales-demo/xcsh/releases/tag/v19.98.10"
33
33
  };
@@ -19,12 +19,19 @@ import stealthLocaleScript from "./puppeteer/09_stealth_locale.txt" with { type:
19
19
  import stealthPluginsScript from "./puppeteer/10_stealth_plugins.txt" with { type: "text" };
20
20
  import stealthHardwareScript from "./puppeteer/11_stealth_hardware.txt" with { type: "text" };
21
21
  import stealthCodecsScript from "./puppeteer/12_stealth_codecs.txt" with { type: "text" };
22
- import stealthWorkerScript from "./puppeteer/13_stealth_worker.txt" with { type: "text" };
23
22
 
24
23
  /**
25
24
  * The injected surfaces, in load order. Order is load-bearing: `tampering` must
26
25
  * run first so later scripts' patched functions are already covered by its
27
26
  * `Function.prototype.toString` shim.
27
+ *
28
+ * There is deliberately no `worker` surface. It rewrote every Worker to a `blob:`
29
+ * URL to inject a prelude, which broke relative-URL workers outright and any
30
+ * worker under `worker-src 'self'`, while its prelude was dead code — it called
31
+ * `Object_defineProperty`, a page-realm binding a worker realm does not inherit.
32
+ * Chrome already propagates the page's CDP user-agent override into workers,
33
+ * including the brand list, so nothing was lost by removing it. See #2560 and
34
+ * test/e2e/stealth-workers.e2e.test.ts.
28
35
  */
29
36
  export const STEALTH_SCRIPTS: ReadonlyArray<{ readonly name: string; readonly source: string }> = [
30
37
  { name: "tampering", source: stealthTamperingScript },
@@ -40,7 +47,6 @@ export const STEALTH_SCRIPTS: ReadonlyArray<{ readonly name: string; readonly so
40
47
  { name: "plugins", source: stealthPluginsScript },
41
48
  { name: "hardware", source: stealthHardwareScript },
42
49
  { name: "codecs", source: stealthCodecsScript },
43
- { name: "worker", source: stealthWorkerScript },
44
50
  ];
45
51
 
46
52
  export type StealthBundleOptions = {
@@ -1,74 +0,0 @@
1
- const patchWorkerConstructor = (name, OriginalWorker) => {
2
- if (typeof OriginalWorker !== "function") return;
3
-
4
- const buildWrappedUrl = (scriptURL, options) => {
5
- const ua = navigator.userAgent;
6
- const platform = navigator.platform;
7
- const uaData = navigator.userAgentData && typeof navigator.userAgentData.toJSON === "function"
8
- ? navigator.userAgentData.toJSON()
9
- : navigator.userAgentData;
10
-
11
- const preludeLines = [
12
- "try {",
13
- `const ua = ${JSON.stringify(ua)};`,
14
- `const platform = ${JSON.stringify(platform)};`,
15
- "Object_defineProperty(self.navigator, 'userAgent', { get: () => ua, configurable: true });",
16
- "Object_defineProperty(self.navigator, 'platform', { get: () => platform, configurable: true });",
17
- ];
18
-
19
- if (uaData) {
20
- preludeLines.push(`const uaData = ${JSON.stringify(uaData)};`);
21
- preludeLines.push(
22
- "Object_defineProperty(self.navigator, 'userAgentData', { get: () => uaData, configurable: true });",
23
- );
24
- }
25
-
26
- preludeLines.push("} catch (e) {};");
27
- const prelude = preludeLines.join("\n");
28
- const importLine = options?.type === "module"
29
- ? `import ${JSON.stringify(String(scriptURL))};`
30
- : `importScripts(${JSON.stringify(String(scriptURL))});`;
31
- const blob = new Window_Blob([prelude, "\n", importLine], { type: "application/javascript" });
32
- const url = URL.createObjectURL(blob);
33
- return url;
34
- };
35
-
36
- const handler = {
37
- construct(target, args) {
38
- try {
39
- const scriptURL = args?.[0];
40
- const options = args?.[1];
41
- if (!scriptURL) {
42
- return new target(...(args || []));
43
- }
44
- const wrappedUrl = buildWrappedUrl(scriptURL, options);
45
- const worker = new target(wrappedUrl, options);
46
- URL.revokeObjectURL(wrappedUrl);
47
- return worker;
48
- } catch {
49
- return new target(...(args || []));
50
- }
51
- },
52
- apply(target, thisArg, args) {
53
- return Reflect.apply(target, thisArg, args || []);
54
- },
55
- };
56
-
57
- const proxied = new Window_Proxy(OriginalWorker, handler);
58
- Object_defineProperty(window, name, {
59
- value: proxied,
60
- writable: true,
61
- configurable: true,
62
- });
63
- Object_defineProperty(window[name], "toString", {
64
- value: Function_toString.bind(OriginalWorker),
65
- writable: false,
66
- configurable: true,
67
- enumerable: false,
68
- });
69
- };
70
-
71
- try {
72
- patchWorkerConstructor("Worker", window.Worker);
73
- patchWorkerConstructor("SharedWorker", window.SharedWorker);
74
- } catch {}