@pensar/apex 2.6.1 → 2.7.0-canary.21cb83dc

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 (226) hide show
  1. package/build/{agent-yby11zaq.js → agent-68t2wzmc.js} +6 -6
  2. package/build/agent-jhekpern.js +13 -0
  3. package/build/{agent-ayreaj6z.js → agent-qvreg8a4.js} +5 -5
  4. package/build/{agent-runs-g37vkrjr.js → agent-runs-30dvbvmm.js} +18 -18
  5. package/build/agent-vybw255f.js +13 -0
  6. package/build/{apps-xn6km9yn.js → apps-na0y0992.js} +13 -13
  7. package/build/{auth-d105wc64.js → auth-dz2c5thx.js} +13 -13
  8. package/build/{blackboxAgent-s56sgx9b.js → blackboxAgent-2mwvaajb.js} +6 -6
  9. package/build/{blackboxPentest-ps78v3w7.js → blackboxPentest-s2mfze9p.js} +17 -12
  10. package/build/{cli-kb21qhvm.js → cli-1pmfnz1a.js} +4 -3
  11. package/build/{cli-ae8jqxqr.js → cli-563yntrb.js} +2 -2
  12. package/build/{cli-7eea4e2y.js → cli-5ab346kd.js} +6 -6
  13. package/build/{cli-1ve18npr.js → cli-72y76bpg.js} +3 -2
  14. package/build/{cli-fy6vh2a7.js → cli-98wmmphf.js} +1 -1
  15. package/build/{cli-c05y640n.js → cli-9jscnhtg.js} +1 -1
  16. package/build/{cli-3sp6nd8d.js → cli-9kk9tm58.js} +2 -2
  17. package/build/{cli-d37a42dc.js → cli-9pz9wjt2.js} +101 -18
  18. package/build/{cli-dpsw2fe6.js → cli-a6x4jm5a.js} +476 -193
  19. package/build/{cli-az3xq70v.js → cli-cfrdr25z.js} +1 -1
  20. package/build/{cli-ngq9dr8n.js → cli-fdrrbb9p.js} +3 -3
  21. package/build/{cli-k2nwxta0.js → cli-t09zj814.js} +2 -2
  22. package/build/{cli-qgz1q9g5.js → cli-t4q4t4dx.js} +223 -76
  23. package/build/{cli-xtc2t6me.js → cli-vdd1s3x9.js} +103 -39
  24. package/build/{cli-gx71jcke.js → cli-vn4cwac3.js} +1 -1
  25. package/build/{cli-65g6rcat.js → cli-w9nw2a4z.js} +1 -1
  26. package/build/{cli-n2en7j5b.js → cli-z7ysyrr4.js} +1 -1
  27. package/build/{cli-709rvekb.js → cli-zbbtr4sb.js} +4 -2
  28. package/build/cli.js +70 -40
  29. package/build/{config-zpqkd5cz.js → config-nkzm9arw.js} +1 -1
  30. package/build/{fastStrike-mcjdvwez.js → fastStrike-16jw1s61.js} +67 -15
  31. package/build/{fixes-kytx5dmj.js → fixes-6wxk22v5.js} +13 -13
  32. package/build/{index-4vqdgb42.js → index-36p56pcf.js} +1473 -1217
  33. package/build/{index-je6hcsqr.js → index-6nejymsc.js} +1 -1
  34. package/build/{index-fv64eb32.js → index-asm4y7e4.js} +2 -2
  35. package/build/{index-n65z6v7b.js → index-bfmn52za.js} +6 -6
  36. package/build/{index-qv4cc65p.js → index-bt4r13q7.js} +13 -13
  37. package/build/{index-dr3tg1w3.js → index-gfq1rp1q.js} +1 -1
  38. package/build/{index-wqetp6gq.js → index-j9pxgrzd.js} +12 -7
  39. package/build/{index-r9yjkfrv.js → index-n9kapn1x.js} +4 -4
  40. package/build/{index-ns4m4s01.js → index-tr6evhyg.js} +4 -4
  41. package/build/{issues-eb3q9d3a.js → issues-7rmf4ker.js} +13 -13
  42. package/build/{knowledge-fqsvtx0f.js → knowledge-s2sxh8nb.js} +13 -13
  43. package/build/lib/{chunk-1azdancq.js → chunk-0dnx79b1.js} +1 -1
  44. package/build/lib/{chunk-4hwzqthr.js → chunk-161ak2am.js} +3 -2
  45. package/build/lib/{chunk-z137x08b.js → chunk-1rqbhx4b.js} +7 -5
  46. package/build/lib/{chunk-1yct6cra.js → chunk-3hjvdf67.js} +1 -1
  47. package/build/lib/{chunk-r2dkp4tb.js → chunk-5j8pp0xf.js} +1 -1
  48. package/build/lib/{chunk-3c00n0cy.js → chunk-77se1d35.js} +8 -3
  49. package/build/lib/{chunk-yrnrbjes.js → chunk-7tft4b8b.js} +4 -2
  50. package/build/lib/{chunk-w66ce82a.js → chunk-8njjwwcw.js} +4 -2
  51. package/build/lib/{chunk-v3dk9j7k.js → chunk-aq9eyxas.js} +80 -21
  52. package/build/lib/{chunk-9tt2021m.js → chunk-d05cvnv8.js} +9 -9
  53. package/build/lib/{chunk-e8yy2k73.js → chunk-f3sq4896.js} +28 -2
  54. package/build/lib/{chunk-1fy8azee.js → chunk-fasqtjq1.js} +1 -1
  55. package/build/lib/{chunk-1jvwqnem.js → chunk-gm3b9j4y.js} +104 -40
  56. package/build/lib/{chunk-r4j8ybn9.js → chunk-hys7nemr.js} +87 -36
  57. package/build/lib/{chunk-7pwa92rn.js → chunk-j9668h16.js} +1 -1
  58. package/build/lib/{chunk-ba41jh41.js → chunk-kcw4cpr3.js} +418 -133
  59. package/build/lib/{chunk-z96pbjhd.js → chunk-m4swxy5r.js} +13 -6
  60. package/build/lib/{chunk-xhdpgpkm.js → chunk-mbsde9d0.js} +2 -2
  61. package/build/lib/{chunk-9yksqgzr.js → chunk-mpvjfvz0.js} +20 -13
  62. package/build/lib/{chunk-2qsq76xq.js → chunk-qkz5sm0d.js} +128 -34
  63. package/build/lib/{chunk-nhfax4gb.js → chunk-rfyjqybp.js} +1 -1
  64. package/build/lib/{chunk-mg03jdmt.js → chunk-vsnwzne5.js} +1 -1
  65. package/build/lib/{chunk-acgbyf5h.js → chunk-ydxhkgjw.js} +3 -2
  66. package/build/lib/{chunk-bb0ekhkw.js → chunk-z8kej0sp.js} +69 -18
  67. package/build/lib/core/agents/agentRuntime.d.ts +2 -1
  68. package/build/lib/core/agents/defineAgent.d.ts +3 -2
  69. package/build/lib/core/agents/offSecAgent/index.d.ts +3 -1
  70. package/build/lib/core/agents/offSecAgent/index.js +10 -8
  71. package/build/lib/core/agents/offSecAgent/prompt.d.ts +3 -1
  72. package/build/lib/core/agents/offSecAgent/subagentSpawner.d.ts +2 -1
  73. package/build/lib/core/agents/offSecAgent/subagentSpawner.js +5 -5
  74. package/build/lib/core/agents/offSecAgent/tools/index.js +4 -4
  75. package/build/lib/core/agents/offSecAgent/tools/listMemories.d.ts +11 -1
  76. package/build/lib/core/agents/offSecAgent/tools/reportError.d.ts +2 -1
  77. package/build/lib/core/agents/offSecAgent/tools/runPentestWorkflow.d.ts +20 -1
  78. package/build/lib/core/agents/offSecAgent/tools/spawnPentestAgent.d.ts +4 -7
  79. package/build/lib/core/agents/offSecAgent/tools/spawnPentestSwarm.d.ts +7 -1
  80. package/build/lib/core/agents/offSecAgent/tools/types.d.ts +2 -1
  81. package/build/lib/core/agents/offSecAgent/types.d.ts +7 -1
  82. package/build/lib/core/agents/specialized/attackSurface/blackboxAgent.js +9 -9
  83. package/build/lib/core/agents/specialized/attackSurface/schemas.js +9 -9
  84. package/build/lib/core/agents/specialized/authenticationAgent/index.js +10 -10
  85. package/build/lib/core/agents/specialized/codeAgent/agent.js +9 -9
  86. package/build/lib/core/agents/specialized/codeAgent/prompts.d.ts +1 -0
  87. package/build/lib/core/agents/specialized/findingJudge/agent.js +8 -8
  88. package/build/lib/core/agents/specialized/findingJudge/index.js +3 -3
  89. package/build/lib/core/agents/specialized/patching/index.js +10 -10
  90. package/build/lib/core/agents/specialized/pentest/agent.d.ts +18 -4
  91. package/build/lib/core/agents/specialized/pentest/agent.js +11 -9
  92. package/build/lib/core/agents/specialized/whiteboxAttackSurface/index.js +9 -9
  93. package/build/lib/core/ai/ai.d.ts +23 -6
  94. package/build/lib/core/ai/ai.js +2 -2
  95. package/build/lib/core/ai/index.js +2 -2
  96. package/build/lib/core/ai/models/claude-capabilities.d.ts +3 -2
  97. package/build/lib/core/ai/models/concentrate.d.ts +1 -0
  98. package/build/lib/core/ai/models/index.d.ts +1 -1
  99. package/build/lib/core/ai/providers/concentrate.d.ts +1 -0
  100. package/build/lib/core/ai/utils.d.ts +2 -0
  101. package/build/lib/core/ai/utils.js +4 -2
  102. package/build/lib/core/api/index.d.ts +3 -0
  103. package/build/lib/core/api/index.js +22 -19
  104. package/build/lib/core/api/targetedPentest.d.ts +1 -0
  105. package/build/lib/core/api/targetedPentest.js +10 -10
  106. package/build/lib/core/config/config.d.ts +3 -0
  107. package/build/lib/core/config/index.js +1 -1
  108. package/build/lib/core/findings/registry.js +3 -3
  109. package/build/lib/core/session/index.d.ts +12 -0
  110. package/build/lib/core/session/index.js +2 -2
  111. package/build/lib/core/session/persistence.d.ts +7 -0
  112. package/build/lib/core/session/persistence.js +7 -3
  113. package/build/lib/core/workflows/fastStrike.d.ts +3 -1
  114. package/build/lib/core/workflows/pentest.d.ts +8 -1
  115. package/build/lib/core/workflows/pentest.js +15 -15
  116. package/build/lib/core/workflows/seams.js +4 -4
  117. package/build/lib/core/workflows/whiteboxAttackSurface.js +11 -11
  118. package/build/lib/index.js +22 -22
  119. package/build/{logs-x62b7hk1.js → logs-70fyr848.js} +13 -13
  120. package/build/{native-rollout-evidence-c9yhfqcs.js → native-rollout-evidence-ntensvzb.js} +3 -3
  121. package/build/{offesecAgent-5whnpeta.js → offesecAgent-kk62tf60.js} +4 -4
  122. package/build/pentest-4jgznn7h.js +22 -0
  123. package/build/{pentests-e0f32aqx.js → pentests-3e41hj08.js} +13 -13
  124. package/build/recordedRunClient-w34kcch1.js +11 -0
  125. package/build/{targetedPentest-rcbs4nvp.js → targetedPentest-t9snxcj2.js} +18 -11
  126. package/build/{targets-xj9g3q0z.js → targets-1pyf21c7.js} +13 -13
  127. package/build/threatModel-48y5qjze.js +21 -0
  128. package/build/{uninstall-7s784q4a.js → uninstall-fbydd9t6.js} +1 -1
  129. package/build/{upload-4gvhwmvr.js → upload-sbhwe2fq.js} +4 -4
  130. package/build/{utils-cjrz64pc.js → utils-23903gcj.js} +3 -3
  131. package/package.json +1 -1
  132. package/src/cli.ts +48 -14
  133. package/src/core/agents/agentRuntime.test.ts +38 -0
  134. package/src/core/agents/agentRuntime.ts +5 -2
  135. package/src/core/agents/defineAgent.ts +3 -1
  136. package/src/core/agents/offSecAgent/index.ts +3 -0
  137. package/src/core/agents/offSecAgent/offensiveSecurityAgent.test.ts +92 -5
  138. package/src/core/agents/offSecAgent/offensiveSecurityAgent.ts +70 -31
  139. package/src/core/agents/offSecAgent/prompt.test.ts +46 -0
  140. package/src/core/agents/offSecAgent/prompt.ts +52 -8
  141. package/src/core/agents/offSecAgent/selectiveConstruction.publicPath.test.ts +38 -0
  142. package/src/core/agents/offSecAgent/selectiveConstruction.test.ts +64 -0
  143. package/src/core/agents/offSecAgent/subagentSpawner.ts +12 -1
  144. package/src/core/agents/offSecAgent/tools/delegateAuth.ts +1 -0
  145. package/src/core/agents/offSecAgent/tools/listMemories.test.ts +230 -0
  146. package/src/core/agents/offSecAgent/tools/listMemories.ts +73 -6
  147. package/src/core/agents/offSecAgent/tools/reportError.test.ts +6 -0
  148. package/src/core/agents/offSecAgent/tools/reportError.ts +10 -2
  149. package/src/core/agents/offSecAgent/tools/runAttackSurface.ts +2 -0
  150. package/src/core/agents/offSecAgent/tools/runPentestWorkflow.test.ts +57 -0
  151. package/src/core/agents/offSecAgent/tools/runPentestWorkflow.ts +19 -1
  152. package/src/core/agents/offSecAgent/tools/runWhiteboxScan.ts +5 -2
  153. package/src/core/agents/offSecAgent/tools/spawnCodingAgent.ts +1 -0
  154. package/src/core/agents/offSecAgent/tools/spawnPentestAgent.test.ts +72 -2
  155. package/src/core/agents/offSecAgent/tools/spawnPentestAgent.ts +32 -11
  156. package/src/core/agents/offSecAgent/tools/spawnPentestSwarm.ts +25 -5
  157. package/src/core/agents/offSecAgent/tools/threatModelGenerator.ts +1 -0
  158. package/src/core/agents/offSecAgent/tools/types.ts +6 -1
  159. package/src/core/agents/offSecAgent/tools/updateTask.ts +5 -1
  160. package/src/core/agents/offSecAgent/tools/whiteboxCandidates.ts +11 -4
  161. package/src/core/agents/offSecAgent/types.ts +9 -0
  162. package/src/core/agents/specialized/codeAgent/agent.test.ts +7 -0
  163. package/src/core/agents/specialized/codeAgent/agent.ts +9 -2
  164. package/src/core/agents/specialized/codeAgent/prompts.ts +6 -0
  165. package/src/core/agents/specialized/pentest/agent.test.ts +116 -0
  166. package/src/core/agents/specialized/pentest/agent.ts +178 -49
  167. package/src/core/agents/specialized/pentest/results.test.ts +59 -4
  168. package/src/core/agents/specialized/whiteboxAttackSurface/endpointDocumentationAgent.ts +1 -0
  169. package/src/core/ai/ai.operator-context.bench.test.ts +1408 -0
  170. package/src/core/ai/ai.recorded-context.test.ts +74 -0
  171. package/src/core/ai/ai.test.ts +54 -0
  172. package/src/core/ai/ai.ts +312 -82
  173. package/src/core/ai/compactionTelemetry.test.ts +2 -2
  174. package/src/core/ai/models/anthropic.ts +6 -0
  175. package/src/core/ai/models/bedrock.ts +18 -0
  176. package/src/core/ai/models/claude-capabilities.ts +29 -8
  177. package/src/core/ai/models/concentrate.ts +52 -0
  178. package/src/core/ai/models/index.ts +25 -4
  179. package/src/core/ai/models/models.test.ts +154 -0
  180. package/src/core/ai/models/openrouter.ts +43 -1
  181. package/src/core/ai/providers/anthropic-models.test.ts +60 -1
  182. package/src/core/ai/providers/bedrock-models.test.ts +81 -0
  183. package/src/core/ai/providers/concentrate.test.ts +31 -0
  184. package/src/core/ai/providers/concentrate.ts +11 -0
  185. package/src/core/ai/providers/gateway-models.test.ts +16 -6
  186. package/src/core/ai/utils.native-rollout-evidence.test.ts +1 -0
  187. package/src/core/ai/utils.ts +189 -143
  188. package/src/core/api/blackboxPentest.ts +9 -1
  189. package/src/core/api/index.ts +9 -0
  190. package/src/core/api/targetedPentest.ts +19 -5
  191. package/src/core/config/config.test.ts +35 -0
  192. package/src/core/config/config.ts +5 -0
  193. package/src/core/observability/telemetry.test.ts +2 -3
  194. package/src/core/session/index.ts +5 -0
  195. package/src/core/session/persistence.test.ts +62 -0
  196. package/src/core/session/persistence.ts +56 -0
  197. package/src/core/workflows/fastStrike.seams.test.ts +149 -0
  198. package/src/core/workflows/fastStrike.test.ts +18 -1
  199. package/src/core/workflows/fastStrike.ts +103 -11
  200. package/src/core/workflows/pentest.test.ts +104 -0
  201. package/src/core/workflows/pentest.ts +110 -7
  202. package/src/core/workflows/seams.test.ts +13 -0
  203. package/src/core/workflows/seams.ts +5 -1
  204. package/src/core/workflows/whiteboxAttackSurface.ts +1 -0
  205. package/src/tui/components/chat/loading-indicator.tsx +20 -4
  206. package/src/tui/components/chat/message-list.tsx +1 -0
  207. package/src/tui/components/commands/__tests__/advanced-settings-lifecycle.tsx +176 -0
  208. package/src/tui/components/commands/advanced-settings.test.ts +28 -0
  209. package/src/tui/components/commands/advanced-settings.tsx +237 -19
  210. package/src/tui/components/operator-dashboard/index.tsx +46 -9
  211. package/src/tui/components/operator-dashboard/logic.test.ts +106 -0
  212. package/src/tui/components/operator-dashboard/logic.ts +42 -2
  213. package/src/tui/components/operator-dashboard/run-events.test.ts +3 -1
  214. package/src/tui/components/shared/__tests__/tool-renderer-lifecycle.tsx +18 -0
  215. package/src/tui/components/shared/action-label.test.ts +9 -0
  216. package/src/tui/components/shared/compacting-icon.tsx +18 -0
  217. package/src/tui/components/shared/index.ts +1 -0
  218. package/src/tui/components/shared/tool-registry.ts +1 -0
  219. package/src/tui/components/shared/tool-renderer.tsx +21 -7
  220. package/src/tui/context/route.tsx +1 -0
  221. package/src/tui/keybindings/registry.ts +2 -0
  222. package/build/agent-6w7egcf1.js +0 -13
  223. package/build/agent-9zx75feh.js +0 -13
  224. package/build/pentest-e61hc38s.js +0 -22
  225. package/build/recordedRunClient-dp032c32.js +0 -11
  226. package/build/threatModel-jkxfa40s.js +0 -21
@@ -3,7 +3,7 @@ import {
3
3
  get2,
4
4
  update2,
5
5
  init_config2
6
- } from "./cli-709rvekb.js";
6
+ } from "./cli-zbbtr4sb.js";
7
7
 
8
8
  // src/core/config/index.ts
9
9
  init_config2();
@@ -14,8 +14,8 @@ import {
14
14
  createWorkspaceSelection2,
15
15
  pollWorkspaceSelection2,
16
16
  init_auth
17
- } from "./cli-c05y640n.js";
18
- import"./cli-fy6vh2a7.js";
17
+ } from "./cli-9jscnhtg.js";
18
+ import"./cli-98wmmphf.js";
19
19
  init_auth();
20
20
 
21
21
  export {
@@ -6,14 +6,14 @@ import {
6
6
  AppsDiscoveryResultSchema2,
7
7
  DiscoverySummarySchema2,
8
8
  WhiteboxAttackSurfaceAgent2
9
- } from "./cli-ngq9dr8n.js";
10
- import"./cli-1ve18npr.js";
9
+ } from "./cli-fdrrbb9p.js";
10
+ import"./cli-72y76bpg.js";
11
11
  import"./cli-qba2x69h.js";
12
- import"./cli-qgz1q9g5.js";
13
- import"./cli-dpsw2fe6.js";
14
- import"./cli-c05y640n.js";
12
+ import"./cli-t4q4t4dx.js";
13
+ import"./cli-a6x4jm5a.js";
14
+ import"./cli-9jscnhtg.js";
15
15
  import"./cli-c2k4xxaw.js";
16
- import"./cli-fy6vh2a7.js";
16
+ import"./cli-98wmmphf.js";
17
17
  export {
18
18
  AppInfoSchema2 as AppInfoSchema,
19
19
  AppsDiscoveryResultSchema2 as AppsDiscoveryResultSchema,
@@ -32,16 +32,16 @@ import {
32
32
  RunRecoveryBlockedError2,
33
33
  resumeRecordedAgent2,
34
34
  serveLocalRunWorker2
35
- } from "./cli-7eea4e2y.js";
35
+ } from "./cli-5ab346kd.js";
36
36
  import"./cli-xcy2vxj2.js";
37
- import"./cli-d37a42dc.js";
38
- import"./cli-n2en7j5b.js";
39
- import"./cli-ngq9dr8n.js";
40
- import"./cli-k2nwxta0.js";
41
- import"./cli-3sp6nd8d.js";
42
- import"./cli-xtc2t6me.js";
43
- import"./cli-kb21qhvm.js";
44
- import"./cli-1ve18npr.js";
37
+ import"./cli-9pz9wjt2.js";
38
+ import"./cli-z7ysyrr4.js";
39
+ import"./cli-fdrrbb9p.js";
40
+ import"./cli-t09zj814.js";
41
+ import"./cli-9kk9tm58.js";
42
+ import"./cli-vdd1s3x9.js";
43
+ import"./cli-1pmfnz1a.js";
44
+ import"./cli-72y76bpg.js";
45
45
  import"./cli-qba2x69h.js";
46
46
  import {
47
47
  ENDPOINT_TRANSPORTS2,
@@ -59,14 +59,14 @@ import {
59
59
  searchEndpoints2,
60
60
  listDomains2,
61
61
  createDomain2
62
- } from "./cli-qgz1q9g5.js";
63
- import"./cli-dpsw2fe6.js";
62
+ } from "./cli-t4q4t4dx.js";
63
+ import"./cli-a6x4jm5a.js";
64
64
  import {
65
65
  getPensarApiUrl2,
66
66
  getPensarConsoleUrl2
67
- } from "./cli-c05y640n.js";
67
+ } from "./cli-9jscnhtg.js";
68
68
  import"./cli-c2k4xxaw.js";
69
- import"./cli-fy6vh2a7.js";
69
+ import"./cli-98wmmphf.js";
70
70
  export {
71
71
  CLOSED_DISPOSITIONS2 as CLOSED_DISPOSITIONS,
72
72
  ENDPOINT_TRANSPORTS2 as ENDPOINT_TRANSPORTS,
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  config2,
3
3
  init_config
4
- } from "./cli-fy6vh2a7.js";
4
+ } from "./cli-98wmmphf.js";
5
5
  init_config();
6
6
 
7
7
  export {
@@ -1,5 +1,5 @@
1
- import"./cli-fy6vh2a7.js";
2
- import"./cli-c05y640n.js";
1
+ import"./cli-98wmmphf.js";
2
+ import"./cli-9jscnhtg.js";
3
3
  import {
4
4
  generateRandomName,
5
5
  generateSessionName,
@@ -16,7 +16,7 @@ import {
16
16
  init_storage,
17
17
  ToolsetStateSchema,
18
18
  init_toolset
19
- } from "./cli-dpsw2fe6.js";
19
+ } from "./cli-a6x4jm5a.js";
20
20
  import {
21
21
  schema,
22
22
  descending,
@@ -41,7 +41,7 @@ import {
41
41
  import {
42
42
  getCurrentVersion,
43
43
  init_installation
44
- } from "./cli-65g6rcat.js";
44
+ } from "./cli-w9nw2a4z.js";
45
45
 
46
46
  // src/core/session/index.ts
47
47
  init_zod();
@@ -91,7 +91,8 @@ var OperatorSettingsObject = object({
91
91
  initialMode: _enum(["plan", "manual", "auto"]).default("manual"),
92
92
  requireApproval: boolean().default(true),
93
93
  enableSuggestions: boolean().default(true),
94
- strikeMode: boolean().optional()
94
+ strikeMode: boolean().optional(),
95
+ findingPolicy: _enum(["native", "external"]).optional()
95
96
  });
96
97
  var EmailInboxConfigObject = discriminatedUnion("provider", [
97
98
  object({
@@ -336,7 +337,7 @@ async function create(input) {
336
337
  } else if (input.inheritEnvironmentConfig === false) {
337
338
  snapshotHeaders = {};
338
339
  } else {
339
- const { config: appConfig } = await import("./index-dr3tg1w3.js");
340
+ const { config: appConfig } = await import("./index-gfq1rp1q.js");
340
341
  const cfg = await appConfig.get();
341
342
  snapshotHeaders = cfg.defaultHeaders ? { ...cfg.defaultHeaders } : { ...DEFAULT_HEADER_RECORD };
342
343
  }
@@ -527,7 +528,8 @@ async function updateOperatorSettings(sessionId, settings) {
527
528
  initialMode: "manual",
528
529
  requireApproval: true,
529
530
  enableSuggestions: true,
530
- strikeMode: false
531
+ strikeMode: false,
532
+ findingPolicy: "native"
531
533
  };
532
534
  }
533
535
  if (settings.initialMode !== undefined) {
@@ -542,6 +544,9 @@ async function updateOperatorSettings(sessionId, settings) {
542
544
  if (settings.strikeMode !== undefined) {
543
545
  session.config.operatorSettings.strikeMode = settings.strikeMode;
544
546
  }
547
+ if (settings.findingPolicy !== undefined) {
548
+ session.config.operatorSettings.findingPolicy = settings.findingPolicy;
549
+ }
545
550
  });
546
551
  }
547
552
  async function updateSessionHeaders(sessionId, headers) {
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  ALL_TOOL_NAMES2,
3
3
  SKILL_TOOL_NAMES2
4
- } from "./cli-qgz1q9g5.js";
5
- import"./cli-fy6vh2a7.js";
6
- import"./cli-c05y640n.js";
7
- import"./cli-dpsw2fe6.js";
4
+ } from "./cli-t4q4t4dx.js";
5
+ import"./cli-98wmmphf.js";
6
+ import"./cli-9jscnhtg.js";
7
+ import"./cli-a6x4jm5a.js";
8
8
  import"./cli-c2k4xxaw.js";
9
9
  export {
10
10
  ALL_TOOL_NAMES2 as ALL_TOOL_NAMES,
@@ -1,11 +1,11 @@
1
- import"./cli-fy6vh2a7.js";
2
- import"./cli-c05y640n.js";
1
+ import"./cli-98wmmphf.js";
2
+ import"./cli-9jscnhtg.js";
3
3
  import {
4
4
  scopedLogger,
5
5
  init_lazyLogger,
6
6
  createLogger,
7
7
  init_structured
8
- } from "./cli-dpsw2fe6.js";
8
+ } from "./cli-a6x4jm5a.js";
9
9
  import"./cli-c2k4xxaw.js";
10
10
 
11
11
  // src/core/agents/specialized/findingJudge/index.ts
@@ -14,7 +14,7 @@ init_lazyLogger();
14
14
  var log = scopedLogger(() => createLogger("FindingJudge"));
15
15
  async function judgeFinding(input, ctx) {
16
16
  try {
17
- const { FindingJudgeAgent } = await import("./agent-ayreaj6z.js");
17
+ const { FindingJudgeAgent } = await import("./agent-qvreg8a4.js");
18
18
  const agent = new FindingJudgeAgent({
19
19
  finding: input,
20
20
  model: ctx.model,
@@ -1,6 +1,7 @@
1
1
  #!/usr/bin/env bun
2
- import"./cli-fy6vh2a7.js";
3
- import"./cli-c05y640n.js";
2
+ import"./cli-t4q4t4dx.js";
3
+ import"./cli-98wmmphf.js";
4
+ import"./cli-9jscnhtg.js";
4
5
  import {
5
6
  CLOSED_DISPOSITIONS2,
6
7
  listIssues2,
@@ -11,22 +12,21 @@ import {
11
12
  retestIssue2,
12
13
  linkPullRequest2,
13
14
  listIssuePullRequests2
14
- } from "./cli-7eea4e2y.js";
15
- import"./cli-qgz1q9g5.js";
16
- import"./cli-k2nwxta0.js";
17
- import"./cli-kb21qhvm.js";
18
- import"./cli-ngq9dr8n.js";
19
- import"./cli-d37a42dc.js";
20
- import"./cli-3sp6nd8d.js";
21
- import"./cli-xtc2t6me.js";
22
- import"./cli-n2en7j5b.js";
15
+ } from "./cli-5ab346kd.js";
16
+ import"./cli-t09zj814.js";
17
+ import"./cli-1pmfnz1a.js";
18
+ import"./cli-fdrrbb9p.js";
19
+ import"./cli-9pz9wjt2.js";
20
+ import"./cli-9kk9tm58.js";
21
+ import"./cli-vdd1s3x9.js";
22
+ import"./cli-z7ysyrr4.js";
23
23
  import"./cli-xcy2vxj2.js";
24
24
  import {
25
25
  markCommandFailed
26
26
  } from "./cli-z82n3qk1.js";
27
- import"./cli-1ve18npr.js";
27
+ import"./cli-72y76bpg.js";
28
28
  import"./cli-qba2x69h.js";
29
- import"./cli-dpsw2fe6.js";
29
+ import"./cli-a6x4jm5a.js";
30
30
  import"./cli-c2k4xxaw.js";
31
31
 
32
32
  // src/cli/issues.ts
@@ -1,6 +1,7 @@
1
1
  #!/usr/bin/env bun
2
- import"./cli-fy6vh2a7.js";
3
- import"./cli-c05y640n.js";
2
+ import"./cli-t4q4t4dx.js";
3
+ import"./cli-98wmmphf.js";
4
+ import"./cli-9jscnhtg.js";
4
5
  import {
5
6
  KNOWLEDGE_CATEGORIES2,
6
7
  KNOWLEDGE_STATUSES2,
@@ -9,22 +10,21 @@ import {
9
10
  createKnowledge2,
10
11
  updateKnowledge2,
11
12
  archiveKnowledge2
12
- } from "./cli-7eea4e2y.js";
13
- import"./cli-qgz1q9g5.js";
14
- import"./cli-k2nwxta0.js";
15
- import"./cli-kb21qhvm.js";
16
- import"./cli-ngq9dr8n.js";
17
- import"./cli-d37a42dc.js";
18
- import"./cli-3sp6nd8d.js";
19
- import"./cli-xtc2t6me.js";
20
- import"./cli-n2en7j5b.js";
13
+ } from "./cli-5ab346kd.js";
14
+ import"./cli-t09zj814.js";
15
+ import"./cli-1pmfnz1a.js";
16
+ import"./cli-fdrrbb9p.js";
17
+ import"./cli-9pz9wjt2.js";
18
+ import"./cli-9kk9tm58.js";
19
+ import"./cli-vdd1s3x9.js";
20
+ import"./cli-z7ysyrr4.js";
21
21
  import"./cli-xcy2vxj2.js";
22
22
  import {
23
23
  markCommandFailed
24
24
  } from "./cli-z82n3qk1.js";
25
- import"./cli-1ve18npr.js";
25
+ import"./cli-72y76bpg.js";
26
26
  import"./cli-qba2x69h.js";
27
- import"./cli-dpsw2fe6.js";
27
+ import"./cli-a6x4jm5a.js";
28
28
  import"./cli-c2k4xxaw.js";
29
29
 
30
30
  // src/cli/knowledge.ts
@@ -2,7 +2,7 @@ import {
2
2
  createLogger,
3
3
  scopedLogger,
4
4
  generateObjectResponse2
5
- } from "./chunk-ba41jh41.js";
5
+ } from "./chunk-kcw4cpr3.js";
6
6
  import {
7
7
  __export
8
8
  } from "./chunk-n0ba7khr.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  AgentRuntime,
3
3
  defineAgent
4
- } from "./chunk-acgbyf5h.js";
4
+ } from "./chunk-ydxhkgjw.js";
5
5
 
6
6
  // src/core/agents/specialized/codeAgent/agent.ts
7
7
  import { stepCountIs } from "ai";
@@ -55,6 +55,7 @@ Prefer catalog + code_query for sink-first work; use candidates to separate unve
55
55
  4. **Stay focused** — stick to your objective. Don't wander into unrelated areas of the codebase.
56
56
  5. **Be thorough** — don't stop at the first match. Make sure you've covered everything relevant to the objective.
57
57
  `;
58
+ var CODE_AGENT_EXTERNAL_SYSTEM_PROMPT = CODE_AGENT_SYSTEM_PROMPT.replace("use candidates to separate unverified ideas from `document_vulnerability`", "use candidates to separate unverified ideas from evidence-backed findings returned to the caller");
58
59
 
59
60
  // src/core/agents/specialized/codeAgent/agent.ts
60
61
  var CODE_AGENT_TOOLS = [
@@ -83,7 +84,7 @@ function codeAgentDefinition2() {
83
84
  return defineAgent({
84
85
  name: "code-agent",
85
86
  role: "worker",
86
- system: (opts) => opts.system ?? CODE_AGENT_SYSTEM_PROMPT,
87
+ system: (opts) => opts.system ?? (opts.findingPolicy === "external" ? CODE_AGENT_EXTERNAL_SYSTEM_PROMPT : CODE_AGENT_SYSTEM_PROMPT),
87
88
  activeTools: (opts) => {
88
89
  let activeTools = [...CODE_AGENT_TOOLS];
89
90
  if (opts.excludeTools?.length) {
@@ -4,26 +4,26 @@ import {
4
4
  import {
5
5
  createLogger,
6
6
  scopedLogger
7
- } from "./chunk-ba41jh41.js";
7
+ } from "./chunk-kcw4cpr3.js";
8
8
  import {
9
9
  assertDepth2,
10
10
  inProcessSeams2,
11
11
  resolveItemHooks2
12
- } from "./chunk-yrnrbjes.js";
12
+ } from "./chunk-7tft4b8b.js";
13
13
  import {
14
14
  inProcessSubagentSpawner2
15
- } from "./chunk-3c00n0cy.js";
15
+ } from "./chunk-77se1d35.js";
16
16
  import {
17
17
  collectCommand
18
18
  } from "./chunk-fy3bbbqy.js";
19
19
  import {
20
20
  CodeAgent2
21
- } from "./chunk-4hwzqthr.js";
21
+ } from "./chunk-161ak2am.js";
22
22
  import {
23
23
  WHITEBOX_APPS_DISCOVERY_SYSTEM_PROMPT2,
24
24
  WHITEBOX_ENDPOINT_DOCUMENTATION_SYSTEM_PROMPT,
25
25
  WHITEBOX_DISCOVERY_SYSTEM_PROMPT2
26
- } from "./chunk-r2dkp4tb.js";
26
+ } from "./chunk-5j8pp0xf.js";
27
27
  import {
28
28
  EndpointSchema2,
29
29
  AppInfoSchema2,
@@ -168,6 +168,7 @@ async function runEndpointDocumentationAgent(opts) {
168
168
  attackSurfaceRegistry
169
169
  },
170
170
  runtime: {
171
+ findingPolicy: hooks?.findingPolicy,
171
172
  model,
172
173
  session,
173
174
  authConfig,
@@ -427,6 +428,7 @@ async function runWhiteboxAttackSurfaceApp2(app, appIndex, input) {
427
428
  attackSurfaceRegistry
428
429
  },
429
430
  runtime: {
431
+ findingPolicy: hooksForApp.findingPolicy,
430
432
  model,
431
433
  session,
432
434
  authConfig,
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  AgentRuntime,
3
3
  defineAgent
4
- } from "./chunk-acgbyf5h.js";
4
+ } from "./chunk-ydxhkgjw.js";
5
5
 
6
6
  // src/core/agents/specialized/patching/agent.ts
7
7
  import { readFileSync } from "node:fs";
@@ -10,7 +10,7 @@ import {
10
10
  import {
11
11
  AgentRuntime,
12
12
  defineAgent
13
- } from "./chunk-acgbyf5h.js";
13
+ } from "./chunk-ydxhkgjw.js";
14
14
  import {
15
15
  __export
16
16
  } from "./chunk-n0ba7khr.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  runWithNativeRolloutSession2
3
- } from "./chunk-ba41jh41.js";
3
+ } from "./chunk-kcw4cpr3.js";
4
4
  import {
5
5
  AgentEventBus2
6
6
  } from "./chunk-7gjdygcx.js";
@@ -9,7 +9,7 @@ import {
9
9
  randomSessionIdFactory2,
10
10
  inProcessSeams2,
11
11
  resolveItemHooks2
12
- } from "./chunk-yrnrbjes.js";
12
+ } from "./chunk-7tft4b8b.js";
13
13
  import {
14
14
  __export
15
15
  } from "./chunk-n0ba7khr.js";
@@ -82,6 +82,7 @@ var runPentestChild = async (spec, ctx) => {
82
82
  openAIReasoningEffort: ctx.openAIReasoningEffort,
83
83
  display: ctx.display,
84
84
  hooks: {
85
+ findingPolicy: ctx.findingPolicy,
85
86
  backends: ctx.backends,
86
87
  sandbox: ctx.sandbox,
87
88
  languageModelMiddleware: ctx.languageModelMiddleware,
@@ -101,6 +102,7 @@ var runPentestChild = async (spec, ctx) => {
101
102
  var runCodeChild = async (spec, ctx) => {
102
103
  const { CodeAgent } = await import("./core/agents/specialized/codeAgent/agent.js");
103
104
  const agent = new CodeAgent({
105
+ findingPolicy: ctx.findingPolicy,
104
106
  codebasePath: spec.codebasePath,
105
107
  objective: spec.objective,
106
108
  system: spec.system,
@@ -133,6 +135,7 @@ var runCodeChild = async (spec, ctx) => {
133
135
  var runWhiteboxChild = async (spec, ctx) => {
134
136
  const { WhiteboxAttackSurfaceAgent } = await import("./core/agents/specialized/whiteboxAttackSurface/index.js");
135
137
  const agent = new WhiteboxAttackSurfaceAgent({
138
+ findingPolicy: ctx.findingPolicy,
136
139
  codebasePath: spec.codebasePath,
137
140
  attackSurfaceRegistry: spec.attackSurfaceRegistry,
138
141
  model: ctx.model,
@@ -153,6 +156,7 @@ var runWhiteboxChild = async (spec, ctx) => {
153
156
  var runBlackboxChild = async (spec, ctx) => {
154
157
  const { BlackboxAttackSurfaceAgent } = await import("./core/agents/specialized/attackSurface/blackboxAgent.js");
155
158
  const agent = new BlackboxAttackSurfaceAgent({
159
+ findingPolicy: ctx.findingPolicy,
156
160
  target: spec.target,
157
161
  attackSurfaceRegistry: spec.attackSurfaceRegistry,
158
162
  model: ctx.model,
@@ -170,9 +174,10 @@ var runBlackboxChild = async (spec, ctx) => {
170
174
  return { run: () => agent.consume(), drained: () => agent.drained };
171
175
  };
172
176
  var runAuthChild = async (spec, ctx) => {
173
- const { runAuthenticationAgent } = await import("./chunk-9tt2021m.js");
177
+ const { runAuthenticationAgent } = await import("./chunk-d05cvnv8.js");
174
178
  return {
175
179
  run: () => runAuthenticationAgent({
180
+ findingPolicy: ctx.findingPolicy,
176
181
  target: spec.target,
177
182
  authHints: spec.authHints,
178
183
  session: ctx.session,
@@ -6,7 +6,7 @@ import {
6
6
  } from "./chunk-jdjagvgr.js";
7
7
  import {
8
8
  FindingsRegistry2
9
- } from "./chunk-1azdancq.js";
9
+ } from "./chunk-0dnx79b1.js";
10
10
 
11
11
  // src/core/utils/concurrency.ts
12
12
  import { context } from "@opentelemetry/api";
@@ -131,12 +131,14 @@ function inProcessSeams2(overrides) {
131
131
  };
132
132
  }
133
133
  function resolveItemHooks2(hooks, seams, item, index) {
134
+ const itemHooks = seams.hooksForItem?.(item, index);
134
135
  return {
135
136
  ...hooks,
136
137
  contextRecorder: undefined,
137
138
  inferenceRecorder: undefined,
138
139
  toolExecutionRecorder: undefined,
139
- ...seams.hooksForItem?.(item, index)
140
+ ...itemHooks,
141
+ ...hooks?.findingPolicy === "external" ? { findingPolicy: "external" } : {}
140
142
  };
141
143
  }
142
144
 
@@ -575,7 +575,7 @@ var package_default = {
575
575
  tsc: "tsc --noEmit"
576
576
  },
577
577
  type: "module",
578
- version: "2.6.1"
578
+ version: "2.7.0-canary.21cb83dc"
579
579
  };
580
580
 
581
581
  // src/core/installation/index.ts
@@ -590,7 +590,8 @@ import path from "node:path";
590
590
  var DEFAULT_CONFIG = {
591
591
  responsibleUseAccepted: false,
592
592
  defaultHeaders: { "User-Agent": "pensar-apex" },
593
- strikeMode: false
593
+ strikeMode: false,
594
+ findingPolicy: "native"
594
595
  };
595
596
  async function init() {
596
597
  const folder = path.join(os.homedir(), ".pensar");
@@ -621,6 +622,7 @@ function applyEnvFallbacks(parsedConfig) {
621
622
  responsibleUseAccepted: parsedConfig.responsibleUseAccepted ?? false,
622
623
  defaultHeaders: parsedConfig.defaultHeaders ?? DEFAULT_CONFIG.defaultHeaders,
623
624
  strikeMode: parsedConfig.strikeMode ?? DEFAULT_CONFIG.strikeMode,
625
+ findingPolicy: parsedConfig.findingPolicy === "external" ? "external" : "native",
624
626
  surfaceIntegrationEnabled: parsedConfig.surfaceIntegrationEnabled ?? parseBoolEnv(process.env.PENSAR_SURFACE_INTEGRATION),
625
627
  version,
626
628
  customProviders: loadCustomProviders(parsedConfig.customProviders),