@pensar/apex 0.0.115-canary.64723b60 → 0.0.115-canary.78d2d7dd

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.
Files changed (38) hide show
  1. package/build/agent-bpxwmtxm.js +17 -0
  2. package/build/{agent-vrnba8ws.js → agent-nm6c5ns8.js} +8 -8
  3. package/build/{auth-1dhkbpeg.js → auth-skr2man1.js} +4 -4
  4. package/build/{authentication-0eg7n3v2.js → authentication-s0vvhxpa.js} +7 -7
  5. package/build/blackboxAgent-dvhet08t.js +18 -0
  6. package/build/{blackboxPentest-cc6as3hk.js → blackboxPentest-r67jj0j1.js} +13 -13
  7. package/build/{cli-dgpkxmt4.js → cli-0wve372a.js} +1 -1
  8. package/build/{cli-sgtzc326.js → cli-2jdpgtmk.js} +1 -1
  9. package/build/{cli-vrdwpwb2.js → cli-4fze1nfh.js} +1 -1
  10. package/build/{cli-a452prk0.js → cli-867kbj0c.js} +2 -2
  11. package/build/{cli-9rv77746.js → cli-9j8k95v4.js} +1 -1
  12. package/build/{cli-22mjhaz9.js → cli-bksgzyyn.js} +2 -2
  13. package/build/{cli-wkgjp34p.js → cli-fvpmqcde.js} +125 -54
  14. package/build/{cli-ttbfspd9.js → cli-hdb9d7r0.js} +11 -15
  15. package/build/{cli-fvrz7v76.js → cli-hy4qmtqq.js} +1 -1
  16. package/build/{cli-3xndhsz3.js → cli-km6s27mj.js} +259 -152
  17. package/build/{cli-jqw2fbxa.js → cli-mg3bvqq9.js} +1 -1
  18. package/build/{cli-1nfbxmkk.js → cli-n3ndwpgc.js} +1 -1
  19. package/build/{cli-vfs7stvy.js → cli-nw1pczc7.js} +1 -1
  20. package/build/{cli-jsptcww6.js → cli-ttar2ydd.js} +2 -2
  21. package/build/{cli-0cgytw99.js → cli-zmgzw8jk.js} +2 -2
  22. package/build/cli.js +22 -22
  23. package/build/{fixes-qka9371w.js → fixes-rq19qrch.js} +4 -4
  24. package/build/{index-32nycbdr.js → index-8m4md3q3.js} +2 -2
  25. package/build/{index-nrd809qg.js → index-af83er0y.js} +6 -6
  26. package/build/{index-56wg9hma.js → index-tsfgqzz5.js} +9 -9
  27. package/build/{issues-mkse7cbm.js → issues-3rp5hxxb.js} +4 -4
  28. package/build/{logs-h4ftff5t.js → logs-s2a7mnkh.js} +4 -4
  29. package/build/pentest-c7k6xda1.js +28 -0
  30. package/build/{pentests-v3c7tvrj.js → pentests-vqj1te11.js} +4 -4
  31. package/build/{projects-ca2cm6ft.js → projects-w96qzpap.js} +4 -4
  32. package/build/{targetedPentest-nzeegs7f.js → targetedPentest-0bwfqj2j.js} +8 -8
  33. package/build/{threatModel-czy9a0x7.js → threatModel-ay7pjt4k.js} +8 -8
  34. package/build/{uninstall-byt7pse6.js → uninstall-jjfp0cd8.js} +1 -1
  35. package/package.json +1 -1
  36. package/build/agent-fqx43shp.js +0 -17
  37. package/build/blackboxAgent-1gdfegxj.js +0 -18
  38. package/build/pentest-m88xx4y2.js +0 -28
@@ -0,0 +1,17 @@
1
+ import {
2
+ CodeAgent
3
+ } from "./cli-ttar2ydd.js";
4
+ import"./cli-km6s27mj.js";
5
+ import"./cli-0wve372a.js";
6
+ import"./cli-3y0dgy56.js";
7
+ import"./cli-fvpmqcde.js";
8
+ import"./cli-r8cerdwk.js";
9
+ import"./cli-2jdpgtmk.js";
10
+ import"./cli-hy4qmtqq.js";
11
+ import"./cli-nw1pczc7.js";
12
+ import"./cli-mg3bvqq9.js";
13
+ import"./cli-gpnb45ck.js";
14
+ import"./cli-8rxa073f.js";
15
+ export {
16
+ CodeAgent
17
+ };
@@ -1,20 +1,20 @@
1
1
  import {
2
2
  WhiteboxAttackSurfaceResultSchema
3
- } from "./cli-9rv77746.js";
3
+ } from "./cli-9j8k95v4.js";
4
4
  import {
5
5
  OffensiveSecurityAgent
6
- } from "./cli-3xndhsz3.js";
7
- import"./cli-dgpkxmt4.js";
6
+ } from "./cli-km6s27mj.js";
7
+ import"./cli-0wve372a.js";
8
8
  import"./cli-3y0dgy56.js";
9
9
  import {
10
10
  hasToolCall,
11
11
  tool
12
- } from "./cli-wkgjp34p.js";
12
+ } from "./cli-fvpmqcde.js";
13
13
  import"./cli-r8cerdwk.js";
14
- import"./cli-sgtzc326.js";
15
- import"./cli-fvrz7v76.js";
16
- import"./cli-vfs7stvy.js";
17
- import"./cli-jqw2fbxa.js";
14
+ import"./cli-2jdpgtmk.js";
15
+ import"./cli-hy4qmtqq.js";
16
+ import"./cli-nw1pczc7.js";
17
+ import"./cli-mg3bvqq9.js";
18
18
  import"./cli-gpnb45ck.js";
19
19
  import"./cli-8rxa073f.js";
20
20
 
@@ -8,14 +8,14 @@ import {
8
8
  pollWorkOSToken,
9
9
  selectWorkspace,
10
10
  startDeviceFlow
11
- } from "./cli-sgtzc326.js";
11
+ } from "./cli-2jdpgtmk.js";
12
12
  import {
13
13
  config,
14
14
  getPensarApiUrl,
15
15
  getPensarConsoleUrl
16
- } from "./cli-fvrz7v76.js";
17
- import"./cli-vfs7stvy.js";
18
- import"./cli-jqw2fbxa.js";
16
+ } from "./cli-hy4qmtqq.js";
17
+ import"./cli-nw1pczc7.js";
18
+ import"./cli-mg3bvqq9.js";
19
19
  import {
20
20
  __require
21
21
  } from "./cli-8rxa073f.js";
@@ -3,17 +3,17 @@ import {
3
3
  } from "./cli-6gtnyaqf.js";
4
4
  import {
5
5
  OffensiveSecurityAgent
6
- } from "./cli-3xndhsz3.js";
7
- import"./cli-dgpkxmt4.js";
6
+ } from "./cli-km6s27mj.js";
7
+ import"./cli-0wve372a.js";
8
8
  import"./cli-3y0dgy56.js";
9
9
  import {
10
10
  hasToolCall
11
- } from "./cli-wkgjp34p.js";
11
+ } from "./cli-fvpmqcde.js";
12
12
  import"./cli-r8cerdwk.js";
13
- import"./cli-sgtzc326.js";
14
- import"./cli-fvrz7v76.js";
15
- import"./cli-vfs7stvy.js";
16
- import"./cli-jqw2fbxa.js";
13
+ import"./cli-2jdpgtmk.js";
14
+ import"./cli-hy4qmtqq.js";
15
+ import"./cli-nw1pczc7.js";
16
+ import"./cli-mg3bvqq9.js";
17
17
  import"./cli-gpnb45ck.js";
18
18
  import"./cli-8rxa073f.js";
19
19
 
@@ -0,0 +1,18 @@
1
+ import {
2
+ BlackboxAttackSurfaceAgent
3
+ } from "./cli-bksgzyyn.js";
4
+ import"./cli-6gtnyaqf.js";
5
+ import"./cli-km6s27mj.js";
6
+ import"./cli-0wve372a.js";
7
+ import"./cli-3y0dgy56.js";
8
+ import"./cli-fvpmqcde.js";
9
+ import"./cli-r8cerdwk.js";
10
+ import"./cli-2jdpgtmk.js";
11
+ import"./cli-hy4qmtqq.js";
12
+ import"./cli-nw1pczc7.js";
13
+ import"./cli-mg3bvqq9.js";
14
+ import"./cli-gpnb45ck.js";
15
+ import"./cli-8rxa073f.js";
16
+ export {
17
+ BlackboxAttackSurfaceAgent
18
+ };
@@ -1,22 +1,22 @@
1
1
  import {
2
2
  runPentestWorkflow
3
- } from "./cli-ttbfspd9.js";
4
- import"./cli-0cgytw99.js";
5
- import"./cli-a452prk0.js";
6
- import"./cli-22mjhaz9.js";
3
+ } from "./cli-hdb9d7r0.js";
4
+ import"./cli-zmgzw8jk.js";
5
+ import"./cli-867kbj0c.js";
6
+ import"./cli-bksgzyyn.js";
7
7
  import"./cli-fw5r7pfj.js";
8
- import"./cli-jsptcww6.js";
8
+ import"./cli-ttar2ydd.js";
9
9
  import"./cli-6gtnyaqf.js";
10
- import"./cli-9rv77746.js";
11
- import"./cli-3xndhsz3.js";
12
- import"./cli-dgpkxmt4.js";
10
+ import"./cli-9j8k95v4.js";
11
+ import"./cli-km6s27mj.js";
12
+ import"./cli-0wve372a.js";
13
13
  import"./cli-3y0dgy56.js";
14
- import"./cli-wkgjp34p.js";
14
+ import"./cli-fvpmqcde.js";
15
15
  import"./cli-r8cerdwk.js";
16
- import"./cli-sgtzc326.js";
17
- import"./cli-fvrz7v76.js";
18
- import"./cli-vfs7stvy.js";
19
- import"./cli-jqw2fbxa.js";
16
+ import"./cli-2jdpgtmk.js";
17
+ import"./cli-hy4qmtqq.js";
18
+ import"./cli-nw1pczc7.js";
19
+ import"./cli-mg3bvqq9.js";
20
20
  import"./cli-gpnb45ck.js";
21
21
  import"./cli-8rxa073f.js";
22
22
 
@@ -3,7 +3,7 @@ import {
3
3
  generateObjectResponse,
4
4
  init_zod,
5
5
  zod_default
6
- } from "./cli-wkgjp34p.js";
6
+ } from "./cli-fvpmqcde.js";
7
7
  import {
8
8
  __callDispose,
9
9
  __using
@@ -3,7 +3,7 @@ import {
3
3
  ensureValidToken,
4
4
  getPensarApiUrl,
5
5
  getPensarGatewayUrl
6
- } from "./cli-fvrz7v76.js";
6
+ } from "./cli-hy4qmtqq.js";
7
7
 
8
8
  // src/core/auth/device-flow.ts
9
9
  function sleep(ms) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  OffensiveSecurityAgent
3
- } from "./cli-3xndhsz3.js";
3
+ } from "./cli-km6s27mj.js";
4
4
  import {
5
5
  __commonJS,
6
6
  __require
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  OffensiveSecurityAgent,
3
3
  readPlan
4
- } from "./cli-3xndhsz3.js";
4
+ } from "./cli-km6s27mj.js";
5
5
  import {
6
6
  exports_external,
7
7
  init_zod
8
- } from "./cli-wkgjp34p.js";
8
+ } from "./cli-fvpmqcde.js";
9
9
 
10
10
  // src/core/agents/specialized/pentest/agent.ts
11
11
  import { existsSync, readdirSync, readFileSync } from "fs";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  exports_external,
3
3
  init_zod
4
- } from "./cli-wkgjp34p.js";
4
+ } from "./cli-fvpmqcde.js";
5
5
 
6
6
  // src/core/agents/specialized/whiteboxAttackSurface/types.ts
7
7
  init_zod();
@@ -3,11 +3,11 @@ import {
3
3
  } from "./cli-6gtnyaqf.js";
4
4
  import {
5
5
  OffensiveSecurityAgent
6
- } from "./cli-3xndhsz3.js";
6
+ } from "./cli-km6s27mj.js";
7
7
  import {
8
8
  hasToolCall,
9
9
  stepCountIs
10
- } from "./cli-wkgjp34p.js";
10
+ } from "./cli-fvpmqcde.js";
11
11
 
12
12
  // src/core/agents/specialized/attackSurface/blackboxAgent.ts
13
13
  import { join } from "path";
@@ -4,12 +4,12 @@ import {
4
4
  } from "./cli-r8cerdwk.js";
5
5
  import {
6
6
  signGatewayRequest
7
- } from "./cli-sgtzc326.js";
7
+ } from "./cli-2jdpgtmk.js";
8
8
  import {
9
9
  config,
10
10
  ensureValidToken,
11
11
  getPensarGatewayUrl
12
- } from "./cli-fvrz7v76.js";
12
+ } from "./cli-hy4qmtqq.js";
13
13
  import {
14
14
  require_auth_errors,
15
15
  require_token_error,
@@ -18516,43 +18516,110 @@ class ParseError extends Error {
18516
18516
  super(message), this.name = "ParseError", this.type = options.type, this.field = options.field, this.value = options.value, this.line = options.line;
18517
18517
  }
18518
18518
  }
18519
+ var LF = 10;
18520
+ var CR = 13;
18521
+ var SPACE = 32;
18519
18522
  function noop(_arg) {}
18520
18523
  function createParser(callbacks) {
18521
18524
  if (typeof callbacks == "function")
18522
18525
  throw new TypeError("`callbacks` must be an object, got a function instead. Did you mean `{onEvent: fn}`?");
18523
18526
  const { onEvent = noop, onError = noop, onRetry = noop, onComment } = callbacks;
18524
- let incompleteLine = "", isFirstChunk = true, id, data = "", eventType = "";
18525
- function feed(newChunk) {
18526
- const chunk = isFirstChunk ? newChunk.replace(/^\xEF\xBB\xBF/, "") : newChunk, [complete, incomplete] = splitLines(`${incompleteLine}${chunk}`);
18527
- for (const line of complete)
18528
- parseLine(line);
18529
- incompleteLine = incomplete, isFirstChunk = false;
18527
+ let incompleteLine = "", isFirstChunk = true, id, data = "", dataLines = 0, eventType;
18528
+ function feed(chunk) {
18529
+ if (isFirstChunk) {
18530
+ isFirstChunk = false, feedFirst(chunk);
18531
+ return;
18532
+ }
18533
+ const input = incompleteLine === "" ? chunk : incompleteLine + chunk;
18534
+ incompleteLine = processLines(input);
18530
18535
  }
18531
- function parseLine(line) {
18532
- if (line === "") {
18536
+ function feedFirst(chunk) {
18537
+ chunk.charCodeAt(0) === 239 && chunk.charCodeAt(1) === 187 && chunk.charCodeAt(2) === 191 && (chunk = chunk.slice(3));
18538
+ const input = incompleteLine === "" ? chunk : incompleteLine + chunk;
18539
+ incompleteLine = processLines(input);
18540
+ }
18541
+ function processLines(chunk) {
18542
+ let searchIndex = 0;
18543
+ if (chunk.indexOf("\r") === -1) {
18544
+ let lfIndex = chunk.indexOf(`
18545
+ `, searchIndex);
18546
+ for (;lfIndex !== -1; ) {
18547
+ if (searchIndex === lfIndex) {
18548
+ dataLines > 0 && onEvent({ id, event: eventType, data }), id = undefined, data = "", dataLines = 0, eventType = undefined, searchIndex = lfIndex + 1, lfIndex = chunk.indexOf(`
18549
+ `, searchIndex);
18550
+ continue;
18551
+ }
18552
+ const firstCharCode = chunk.charCodeAt(searchIndex);
18553
+ if (isDataPrefix(chunk, searchIndex, firstCharCode)) {
18554
+ const valueStart = chunk.charCodeAt(searchIndex + 5) === SPACE ? searchIndex + 6 : searchIndex + 5, value = chunk.slice(valueStart, lfIndex);
18555
+ if (dataLines === 0 && chunk.charCodeAt(lfIndex + 1) === LF) {
18556
+ onEvent({ id, event: eventType, data: value }), id = undefined, data = "", eventType = undefined, searchIndex = lfIndex + 2, lfIndex = chunk.indexOf(`
18557
+ `, searchIndex);
18558
+ continue;
18559
+ }
18560
+ data = dataLines === 0 ? value : `${data}
18561
+ ${value}`, dataLines++;
18562
+ } else
18563
+ isEventPrefix(chunk, searchIndex, firstCharCode) ? eventType = chunk.slice(chunk.charCodeAt(searchIndex + 6) === SPACE ? searchIndex + 7 : searchIndex + 6, lfIndex) || undefined : parseLine(chunk, searchIndex, lfIndex);
18564
+ searchIndex = lfIndex + 1, lfIndex = chunk.indexOf(`
18565
+ `, searchIndex);
18566
+ }
18567
+ return chunk.slice(searchIndex);
18568
+ }
18569
+ for (;searchIndex < chunk.length; ) {
18570
+ const crIndex = chunk.indexOf("\r", searchIndex), lfIndex = chunk.indexOf(`
18571
+ `, searchIndex);
18572
+ let lineEnd = -1;
18573
+ if (crIndex !== -1 && lfIndex !== -1 ? lineEnd = crIndex < lfIndex ? crIndex : lfIndex : crIndex !== -1 ? crIndex === chunk.length - 1 ? lineEnd = -1 : lineEnd = crIndex : lfIndex !== -1 && (lineEnd = lfIndex), lineEnd === -1)
18574
+ break;
18575
+ parseLine(chunk, searchIndex, lineEnd), searchIndex = lineEnd + 1, chunk.charCodeAt(searchIndex - 1) === CR && chunk.charCodeAt(searchIndex) === LF && searchIndex++;
18576
+ }
18577
+ return chunk.slice(searchIndex);
18578
+ }
18579
+ function parseLine(chunk, start, end) {
18580
+ if (start === end) {
18533
18581
  dispatchEvent();
18534
18582
  return;
18535
18583
  }
18536
- if (line.startsWith(":")) {
18537
- onComment && onComment(line.slice(line.startsWith(": ") ? 2 : 1));
18584
+ const firstCharCode = chunk.charCodeAt(start);
18585
+ if (isDataPrefix(chunk, start, firstCharCode)) {
18586
+ const valueStart = chunk.charCodeAt(start + 5) === SPACE ? start + 6 : start + 5, value2 = chunk.slice(valueStart, end);
18587
+ data = dataLines === 0 ? value2 : `${data}
18588
+ ${value2}`, dataLines++;
18538
18589
  return;
18539
18590
  }
18540
- const fieldSeparatorIndex = line.indexOf(":");
18541
- if (fieldSeparatorIndex !== -1) {
18542
- const field = line.slice(0, fieldSeparatorIndex), offset = line[fieldSeparatorIndex + 1] === " " ? 2 : 1, value = line.slice(fieldSeparatorIndex + offset);
18543
- processField(field, value, line);
18591
+ if (isEventPrefix(chunk, start, firstCharCode)) {
18592
+ eventType = chunk.slice(chunk.charCodeAt(start + 6) === SPACE ? start + 7 : start + 6, end) || undefined;
18544
18593
  return;
18545
18594
  }
18546
- processField(line, "", line);
18595
+ if (firstCharCode === 105 && chunk.charCodeAt(start + 1) === 100 && chunk.charCodeAt(start + 2) === 58) {
18596
+ const value2 = chunk.slice(chunk.charCodeAt(start + 3) === SPACE ? start + 4 : start + 3, end);
18597
+ id = value2.includes("\x00") ? undefined : value2;
18598
+ return;
18599
+ }
18600
+ if (firstCharCode === 58) {
18601
+ if (onComment) {
18602
+ const line2 = chunk.slice(start, end);
18603
+ onComment(line2.slice(chunk.charCodeAt(start + 1) === SPACE ? 2 : 1));
18604
+ }
18605
+ return;
18606
+ }
18607
+ const line = chunk.slice(start, end), fieldSeparatorIndex = line.indexOf(":");
18608
+ if (fieldSeparatorIndex === -1) {
18609
+ processField(line, "", line);
18610
+ return;
18611
+ }
18612
+ const field = line.slice(0, fieldSeparatorIndex), offset = line.charCodeAt(fieldSeparatorIndex + 1) === SPACE ? 2 : 1, value = line.slice(fieldSeparatorIndex + offset);
18613
+ processField(field, value, line);
18547
18614
  }
18548
18615
  function processField(field, value, line) {
18549
18616
  switch (field) {
18550
18617
  case "event":
18551
- eventType = value;
18618
+ eventType = value || undefined;
18552
18619
  break;
18553
18620
  case "data":
18554
- data = `${data}${value}
18555
- `;
18621
+ data = dataLines === 0 ? value : `${data}
18622
+ ${value}`, dataLines++;
18556
18623
  break;
18557
18624
  case "id":
18558
18625
  id = value.includes("\x00") ? undefined : value;
@@ -18570,35 +18637,22 @@ function createParser(callbacks) {
18570
18637
  }
18571
18638
  }
18572
18639
  function dispatchEvent() {
18573
- data.length > 0 && onEvent({
18640
+ dataLines > 0 && onEvent({
18574
18641
  id,
18575
- event: eventType || undefined,
18576
- data: data.endsWith(`
18577
- `) ? data.slice(0, -1) : data
18578
- }), id = undefined, data = "", eventType = "";
18642
+ event: eventType,
18643
+ data
18644
+ }), id = undefined, data = "", dataLines = 0, eventType = undefined;
18579
18645
  }
18580
18646
  function reset(options = {}) {
18581
- incompleteLine && options.consume && parseLine(incompleteLine), isFirstChunk = true, id = undefined, data = "", eventType = "", incompleteLine = "";
18647
+ incompleteLine && options.consume && parseLine(incompleteLine, 0, incompleteLine.length), isFirstChunk = true, id = undefined, data = "", dataLines = 0, eventType = undefined, incompleteLine = "";
18582
18648
  }
18583
18649
  return { feed, reset };
18584
18650
  }
18585
- function splitLines(chunk) {
18586
- const lines = [];
18587
- let incompleteLine = "", searchIndex = 0;
18588
- for (;searchIndex < chunk.length; ) {
18589
- const crIndex = chunk.indexOf("\r", searchIndex), lfIndex = chunk.indexOf(`
18590
- `, searchIndex);
18591
- let lineEnd = -1;
18592
- if (crIndex !== -1 && lfIndex !== -1 ? lineEnd = Math.min(crIndex, lfIndex) : crIndex !== -1 ? crIndex === chunk.length - 1 ? lineEnd = -1 : lineEnd = crIndex : lfIndex !== -1 && (lineEnd = lfIndex), lineEnd === -1) {
18593
- incompleteLine = chunk.slice(searchIndex);
18594
- break;
18595
- } else {
18596
- const line = chunk.slice(searchIndex, lineEnd);
18597
- lines.push(line), searchIndex = lineEnd + 1, chunk[searchIndex - 1] === "\r" && chunk[searchIndex] === `
18598
- ` && searchIndex++;
18599
- }
18600
- }
18601
- return [lines, incompleteLine];
18651
+ function isDataPrefix(chunk, i, firstCharCode) {
18652
+ return firstCharCode === 100 && chunk.charCodeAt(i + 1) === 97 && chunk.charCodeAt(i + 2) === 116 && chunk.charCodeAt(i + 3) === 97 && chunk.charCodeAt(i + 4) === 58;
18653
+ }
18654
+ function isEventPrefix(chunk, i, firstCharCode) {
18655
+ return firstCharCode === 101 && chunk.charCodeAt(i + 1) === 118 && chunk.charCodeAt(i + 2) === 101 && chunk.charCodeAt(i + 3) === 110 && chunk.charCodeAt(i + 4) === 116 && chunk.charCodeAt(i + 5) === 58;
18602
18656
  }
18603
18657
 
18604
18658
  // node_modules/eventsource-parser/dist/stream.js
@@ -37754,7 +37808,7 @@ function createParser2(callbacks) {
37754
37808
  const { onEvent = noop2, onError = noop2, onRetry = noop2, onComment } = callbacks;
37755
37809
  let incompleteLine = "", isFirstChunk = true, id, data = "", eventType = "";
37756
37810
  function feed(newChunk) {
37757
- const chunk = isFirstChunk ? newChunk.replace(/^\xEF\xBB\xBF/, "") : newChunk, [complete, incomplete] = splitLines2(`${incompleteLine}${chunk}`);
37811
+ const chunk = isFirstChunk ? newChunk.replace(/^\xEF\xBB\xBF/, "") : newChunk, [complete, incomplete] = splitLines(`${incompleteLine}${chunk}`);
37758
37812
  for (const line of complete)
37759
37813
  parseLine(line);
37760
37814
  incompleteLine = incomplete, isFirstChunk = false;
@@ -37813,7 +37867,7 @@ function createParser2(callbacks) {
37813
37867
  }
37814
37868
  return { feed, reset };
37815
37869
  }
37816
- function splitLines2(chunk) {
37870
+ function splitLines(chunk) {
37817
37871
  const lines = [];
37818
37872
  let incompleteLine = "", searchIndex = 0;
37819
37873
  for (;searchIndex < chunk.length; ) {
@@ -44644,7 +44698,8 @@ var amazonBedrockLanguageModelOptions = exports_external.object({
44644
44698
  exports_external.literal("adaptive")
44645
44699
  ]).optional(),
44646
44700
  budgetTokens: exports_external.number().optional(),
44647
- maxReasoningEffort: exports_external.enum(["low", "medium", "high", "max"]).optional()
44701
+ maxReasoningEffort: exports_external.enum(["low", "medium", "high", "xhigh", "max"]).optional(),
44702
+ display: exports_external.enum(["omitted", "summarized"]).optional()
44648
44703
  }).optional(),
44649
44704
  anthropicBeta: exports_external.array(exports_external.string()).optional(),
44650
44705
  serviceTier: exports_external.enum(["reserved", "priority", "default", "flex"]).optional()
@@ -45262,7 +45317,7 @@ var BedrockChatLanguageModel = class {
45262
45317
  toolChoice,
45263
45318
  providerOptions
45264
45319
  }) {
45265
- var _a26, _b16, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
45320
+ var _a26, _b16, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
45266
45321
  const bedrockOptions = (_a26 = await parseProviderOptions({
45267
45322
  provider: "bedrock",
45268
45323
  providerOptions,
@@ -45340,6 +45395,7 @@ var BedrockChatLanguageModel = class {
45340
45395
  }
45341
45396
  const thinkingType = (_e = bedrockOptions.reasoningConfig) == null ? undefined : _e.type;
45342
45397
  const thinkingBudget = thinkingType === "enabled" ? (_f = bedrockOptions.reasoningConfig) == null ? undefined : _f.budgetTokens : undefined;
45398
+ const thinkingDisplay = thinkingType === "adaptive" ? (_g = bedrockOptions.reasoningConfig) == null ? undefined : _g.display : undefined;
45343
45399
  const isAnthropicThinkingEnabled = isAnthropicModel && isThinkingEnabled;
45344
45400
  const inferenceConfig = {
45345
45401
  ...maxOutputTokens != null && { maxTokens: maxOutputTokens },
@@ -45366,12 +45422,13 @@ var BedrockChatLanguageModel = class {
45366
45422
  bedrockOptions.additionalModelRequestFields = {
45367
45423
  ...bedrockOptions.additionalModelRequestFields,
45368
45424
  thinking: {
45369
- type: "adaptive"
45425
+ type: "adaptive",
45426
+ ...thinkingDisplay != null && { display: thinkingDisplay }
45370
45427
  }
45371
45428
  };
45372
45429
  }
45373
45430
  } else if (!isAnthropicModel) {
45374
- if (((_g = bedrockOptions.reasoningConfig) == null ? undefined : _g.budgetTokens) != null) {
45431
+ if (((_h = bedrockOptions.reasoningConfig) == null ? undefined : _h.budgetTokens) != null) {
45375
45432
  warnings.push({
45376
45433
  type: "unsupported",
45377
45434
  feature: "budgetTokens",
@@ -45386,14 +45443,14 @@ var BedrockChatLanguageModel = class {
45386
45443
  });
45387
45444
  }
45388
45445
  }
45389
- const maxReasoningEffort = (_h = bedrockOptions.reasoningConfig) == null ? undefined : _h.maxReasoningEffort;
45446
+ const maxReasoningEffort = (_i = bedrockOptions.reasoningConfig) == null ? undefined : _i.maxReasoningEffort;
45390
45447
  const isOpenAIModel = this.modelId.startsWith("openai.");
45391
45448
  if (maxReasoningEffort != null) {
45392
45449
  if (isAnthropicModel) {
45393
45450
  bedrockOptions.additionalModelRequestFields = {
45394
45451
  ...bedrockOptions.additionalModelRequestFields,
45395
45452
  output_config: {
45396
- ...(_i = bedrockOptions.additionalModelRequestFields) == null ? undefined : _i.output_config,
45453
+ ...(_j = bedrockOptions.additionalModelRequestFields) == null ? undefined : _j.output_config,
45397
45454
  effort: maxReasoningEffort
45398
45455
  }
45399
45456
  };
@@ -45417,7 +45474,7 @@ var BedrockChatLanguageModel = class {
45417
45474
  bedrockOptions.additionalModelRequestFields = {
45418
45475
  ...bedrockOptions.additionalModelRequestFields,
45419
45476
  output_config: {
45420
- ...(_j = bedrockOptions.additionalModelRequestFields) == null ? undefined : _j.output_config,
45477
+ ...(_k = bedrockOptions.additionalModelRequestFields) == null ? undefined : _k.output_config,
45421
45478
  format: {
45422
45479
  type: "json_schema",
45423
45480
  schema: responseFormat.schema
@@ -45449,7 +45506,7 @@ var BedrockChatLanguageModel = class {
45449
45506
  details: "topK is not supported when thinking is enabled"
45450
45507
  });
45451
45508
  }
45452
- const hasAnyTools = ((_l = (_k = toolConfig.tools) == null ? undefined : _k.length) != null ? _l : 0) > 0 || additionalTools;
45509
+ const hasAnyTools = ((_m = (_l = toolConfig.tools) == null ? undefined : _l.length) != null ? _m : 0) > 0 || additionalTools;
45453
45510
  let filteredPrompt = prompt;
45454
45511
  if (!hasAnyTools) {
45455
45512
  const hasToolContent = prompt.some((message) => ("content" in message) && Array.isArray(message.content) && message.content.some((part) => part.type === "tool-call" || part.type === "tool-result"));
@@ -45816,6 +45873,13 @@ var BedrockChatLanguageModel = class {
45816
45873
  delta: reasoningContent.text
45817
45874
  });
45818
45875
  } else if ("signature" in reasoningContent && reasoningContent.signature) {
45876
+ if (contentBlocks[blockIndex] == null) {
45877
+ contentBlocks[blockIndex] = { type: "reasoning" };
45878
+ controller.enqueue({
45879
+ type: "reasoning-start",
45880
+ id: String(blockIndex)
45881
+ });
45882
+ }
45819
45883
  controller.enqueue({
45820
45884
  type: "reasoning-delta",
45821
45885
  id: String(blockIndex),
@@ -45827,6 +45891,13 @@ var BedrockChatLanguageModel = class {
45827
45891
  }
45828
45892
  });
45829
45893
  } else if ("data" in reasoningContent && reasoningContent.data) {
45894
+ if (contentBlocks[blockIndex] == null) {
45895
+ contentBlocks[blockIndex] = { type: "reasoning" };
45896
+ controller.enqueue({
45897
+ type: "reasoning-start",
45898
+ id: String(blockIndex)
45899
+ });
45900
+ }
45830
45901
  controller.enqueue({
45831
45902
  type: "reasoning-delta",
45832
45903
  id: String(blockIndex),
@@ -46339,7 +46410,7 @@ var bedrockImageResponseSchema = exports_external.object({
46339
46410
  details: exports_external.record(exports_external.string(), exports_external.unknown()).optional(),
46340
46411
  preview: exports_external.unknown().optional()
46341
46412
  });
46342
- var VERSION7 = "4.0.95";
46413
+ var VERSION7 = "4.0.96";
46343
46414
  function createSigV4FetchFunction(getCredentials, fetch2 = globalThis.fetch) {
46344
46415
  return async (input, init) => {
46345
46416
  var _a26, _b16;
@@ -14,33 +14,33 @@ import {
14
14
  updateManifestEntryStatus,
15
15
  writeAgentManifest,
16
16
  writeExecutionMetrics
17
- } from "./cli-0cgytw99.js";
17
+ } from "./cli-zmgzw8jk.js";
18
18
  import {
19
19
  TargetedPentestAgent,
20
20
  buildPentestSystemPrompt
21
- } from "./cli-a452prk0.js";
21
+ } from "./cli-867kbj0c.js";
22
22
  import {
23
23
  BlackboxAttackSurfaceAgent
24
- } from "./cli-22mjhaz9.js";
24
+ } from "./cli-bksgzyyn.js";
25
25
  import {
26
26
  createThreatModelPrompt
27
27
  } from "./cli-fw5r7pfj.js";
28
28
  import {
29
29
  CodeAgent
30
- } from "./cli-jsptcww6.js";
30
+ } from "./cli-ttar2ydd.js";
31
31
  import {
32
32
  EndpointSchema
33
- } from "./cli-9rv77746.js";
33
+ } from "./cli-9j8k95v4.js";
34
34
  import {
35
35
  FindingsRegistry,
36
36
  OffensiveSecurityAgent,
37
37
  PLAN_MODE_TOOL_NAMES
38
- } from "./cli-3xndhsz3.js";
38
+ } from "./cli-km6s27mj.js";
39
39
  import {
40
40
  exports_external,
41
41
  hasToolCall,
42
42
  init_zod
43
- } from "./cli-wkgjp34p.js";
43
+ } from "./cli-fvpmqcde.js";
44
44
 
45
45
  // src/core/workflows/pentest.ts
46
46
  import { existsSync as existsSync3, readdirSync as readdirSync2, readFileSync as readFileSync3, writeFileSync as writeFileSync2 } from "fs";
@@ -447,8 +447,7 @@ function readAppsFromAssetsDirectory(assetsPath, appsDiscovery) {
447
447
  function assetRecordToEndpoint(record) {
448
448
  const rawMethod = record.method;
449
449
  const method = Array.isArray(rawMethod) ? rawMethod.join(", ") : rawMethod ?? "UNKNOWN";
450
- const legacy = record;
451
- const path = record.routePath ?? legacy.url ?? record.endpointName;
450
+ const path = record.routePath;
452
451
  const file = record.file ?? "";
453
452
  const parsed = EndpointSchema.safeParse({
454
453
  method,
@@ -599,10 +598,9 @@ Find ALL web pages, views, and routes that render HTML or serve client-side UI *
599
598
  ### How to document each page
600
599
  For each page, call \`document_endpoint\` with:
601
600
  - **appName**: \`${appInfo.name}\`
602
- - **endpointName**: The route path (e.g., \`/dashboard\`, \`/admin\`, \`/settings\`)
603
601
  - **endpointType**: \`"web-endpoint"\`
604
602
  - **description**: Brief description of what this page shows
605
- - **routePath**: The HTTP route this page serves (e.g., \`/dashboard\`). This is the URL path, NOT a file path.
603
+ - **routePath**: The HTTP route this page serves (e.g., \`/dashboard\`). This is the URL path a client requests — it is the endpoint's identity. NOT a file path.
606
604
  - **method**: \`"PAGE"\`
607
605
  - **file**: Source-code file where this page is defined (e.g., \`src/pages/dashboard.tsx\`). Must be inside \`${appInfo.location}\`. This is NOT the route.
608
606
  - **line**: Line number (if determinable)
@@ -645,10 +643,9 @@ Find ALL API endpoints **whose route definitions live in this application's sour
645
643
  ### How to document each endpoint
646
644
  For each **unique route path**, call \`document_endpoint\` with:
647
645
  - **appName**: \`${appInfo.name}\`
648
- - **endpointName**: The route path (e.g., \`/api/users\`, \`/api/orders/:id\`)
649
646
  - **endpointType**: \`"api-endpoint"\`
650
647
  - **description**: Brief description of what this endpoint does across all its methods
651
- - **routePath**: The HTTP route (e.g., \`/api/users\`). This is the URL path a client requests — NOT a source-file path.
648
+ - **routePath**: The HTTP route (e.g., \`/api/users\`, \`/api/orders/:id\`). This is the URL path a client requests — it is the endpoint's identity. NOT a source-file path.
652
649
  - **method**: Array of ALL HTTP methods this path supports (e.g., \`["GET", "POST"]\`). **Do NOT create separate entries for each method — consolidate them.**
653
650
  - **file**: Source-code file where the endpoint is defined (e.g., \`src/routes/users.ts\`). Must be inside \`${appInfo.location}\`. This is NOT the route.
654
651
  - **line**: Line number (if determinable)
@@ -711,10 +708,9 @@ Find the **distinct access patterns and resource identifiers** for this cloud re
711
708
  ### How to document each entry point
712
709
  For each entry point, call \`document_endpoint\` with:
713
710
  - **appName**: \`${appInfo.name}\`
714
- - **endpointName**: A descriptive name for this access pattern (e.g., "Pre-signed URL access", "Bucket ARN", "Queue URL")
715
711
  - **endpointType**: \`"asset"\`
716
712
  - **description**: What this entry point exposes (e.g., "Pre-signed HTTP URLs for temporary read access to objects", "AWS resource ARN for programmatic access through IAM policies")
717
- - **routePath**: The specific access pattern, path template, or ARN — NOT the base domain URL. Examples: \`/{objectKey}?X-Amz-Signature={signature}&X-Amz-Credential={credential}\`, \`arn:aws:s3:::bucket-name\`, \`https://sqs.region.amazonaws.com/account/queue-name\`
713
+ - **routePath**: The specific access pattern, path template, or ARN — this is the endpoint's identity. NOT the base domain URL. Examples: \`/{objectKey}?X-Amz-Signature={signature}&X-Amz-Credential={credential}\`, \`arn:aws:s3:::bucket-name\`, \`https://sqs.region.amazonaws.com/account/queue-name\`
718
714
  - **method**: Access methods on the resource (e.g., \`["GET", "PUT"]\` for S3, \`["SendMessage", "ReceiveMessage"]\` for SQS, \`["READ", "WRITE"]\` for generic)
719
715
  - **file**: Infrastructure or config file where this resource is defined (e.g., \`infra/storage.ts\`). NOT application code that calls it.
720
716
  - **line**: Line number if determinable
@@ -2,7 +2,7 @@ import {
2
2
  get,
3
3
  init,
4
4
  update
5
- } from "./cli-vfs7stvy.js";
5
+ } from "./cli-nw1pczc7.js";
6
6
 
7
7
  // src/core/api/constants.ts
8
8
  var PENSAR_API_BASE_URL = "https://api.pensar.dev";