@openai/codex-security 0.1.26 → 0.1.28

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 (253) hide show
  1. package/README.md +637 -74
  2. package/_bundled_plugin/.mcp.json +1 -0
  3. package/_bundled_plugin/mcp/helpers.mjs +24 -0
  4. package/_bundled_plugin/mcp/helpers.mjs.br.part-000 +0 -0
  5. package/_bundled_plugin/mcp/native/COPYRIGHT-library.html +5556 -0
  6. package/_bundled_plugin/mcp/native/THIRD_PARTY_NOTICES.txt +5989 -0
  7. package/_bundled_plugin/mcp/native/darwin-arm64/unix.node +0 -0
  8. package/_bundled_plugin/mcp/native/darwin-x64/unix.node +0 -0
  9. package/_bundled_plugin/mcp/native/licenses/Apache-2.0.txt +73 -0
  10. package/_bundled_plugin/mcp/native/licenses/BSD-2-Clause.txt +9 -0
  11. package/_bundled_plugin/mcp/native/licenses/MIT.txt +9 -0
  12. package/_bundled_plugin/mcp/native/licenses/Unicode-3.0.txt +39 -0
  13. package/_bundled_plugin/mcp/native/linux-arm64-gnu/unix.node +0 -0
  14. package/_bundled_plugin/mcp/native/linux-arm64-musl/unix.node +0 -0
  15. package/_bundled_plugin/mcp/native/linux-x64-gnu/unix.node +0 -0
  16. package/_bundled_plugin/mcp/native/linux-x64-musl/unix.node +0 -0
  17. package/_bundled_plugin/mcp/native/win32-arm64/windows.node +0 -0
  18. package/_bundled_plugin/mcp/native/win32-x64/windows.node +0 -0
  19. package/_bundled_plugin/mcp/server.mjs.br.part-000 +0 -0
  20. package/_bundled_plugin/mcp/server.mjs.br.part-001 +0 -0
  21. package/_bundled_plugin/references/artifact-storage.md +56 -0
  22. package/_bundled_plugin/references/config-preflight.md +9 -1
  23. package/_bundled_plugin/references/core-scan.md +1 -1
  24. package/_bundled_plugin/references/final-report.md +2 -0
  25. package/_bundled_plugin/references/scan-artifacts.md +6 -14
  26. package/_bundled_plugin/references/scan-contract.md +35 -35
  27. package/_bundled_plugin/references/scan-prologue.md +2 -0
  28. package/_bundled_plugin/references/security-guidance.md +9 -1
  29. package/_bundled_plugin/scripts/deep_scan_config.py +10 -8
  30. package/_bundled_plugin/scripts/deep_scan_defaults.json +8 -0
  31. package/_bundled_plugin/scripts/generate_in_scope_files.py +2 -2
  32. package/_bundled_plugin/scripts/generate_rank_input.py +8 -1
  33. package/_bundled_plugin/scripts/launch_codex_security_mcp +6 -0
  34. package/_bundled_plugin/scripts/launch_codex_security_mcp.cmd +43 -9
  35. package/_bundled_plugin/scripts/rank_preview.py +4 -1
  36. package/_bundled_plugin/scripts/reserved_artifact_paths.json +6 -0
  37. package/_bundled_plugin/scripts/windows_scan_local_files.py +1 -3
  38. package/_bundled_plugin/scripts/workbench/storage.py +18 -0
  39. package/_bundled_plugin/scripts/workbench_cli.py +17 -0
  40. package/_bundled_plugin/scripts/workbench_db.py +46 -42
  41. package/_bundled_plugin/scripts/workbench_saved_results.py +72 -1
  42. package/_bundled_plugin/scripts/workbench_scan_history.py +117 -2
  43. package/_bundled_plugin/scripts/workbench_scan_usage.py +23 -10
  44. package/_bundled_plugin/scripts/workbench_validation.py +4 -0
  45. package/_bundled_plugin/skills/assess-patch-risk/SKILL.md +2 -0
  46. package/_bundled_plugin/skills/attack-path-analysis/SKILL.md +2 -0
  47. package/_bundled_plugin/skills/deep-security-scan/SKILL.md +5 -1
  48. package/_bundled_plugin/skills/define-security-policy/SKILL.md +3 -3
  49. package/_bundled_plugin/skills/finding-discovery/SKILL.md +2 -0
  50. package/_bundled_plugin/skills/fix-finding/SKILL.md +3 -1
  51. package/_bundled_plugin/skills/fix-finding/agents/openai.yaml +1 -1
  52. package/_bundled_plugin/skills/propose-security-hardening/SKILL.md +2 -0
  53. package/_bundled_plugin/skills/security-scan/references/desktop-scan.md +5 -1
  54. package/_bundled_plugin/skills/threat-model/SKILL.md +2 -0
  55. package/_bundled_plugin/skills/validation/SKILL.md +2 -0
  56. package/_bundled_plugin/skills/vulnerability-writeup/SKILL.md +2 -0
  57. package/dist/api.d.ts +14 -24
  58. package/dist/api.d.ts.map +1 -1
  59. package/dist/api.js +585 -168
  60. package/dist/api.js.map +1 -1
  61. package/dist/auth.d.ts.map +1 -1
  62. package/dist/auth.js +10 -0
  63. package/dist/auth.js.map +1 -1
  64. package/dist/bulk-scan-discovery.d.ts +1 -1
  65. package/dist/bulk-scan-discovery.d.ts.map +1 -1
  66. package/dist/bulk-scan-discovery.js +2 -2
  67. package/dist/bulk-scan-discovery.js.map +1 -1
  68. package/dist/classify-scan-severity.js.map +1 -1
  69. package/dist/classify-severity.d.ts.map +1 -1
  70. package/dist/classify-severity.js.map +1 -1
  71. package/dist/cli.d.ts +24 -4
  72. package/dist/cli.d.ts.map +1 -1
  73. package/dist/cli.js +1577 -610
  74. package/dist/cli.js.map +1 -1
  75. package/dist/cloud-publish.d.ts.map +1 -1
  76. package/dist/cloud-publish.js +2 -207
  77. package/dist/cloud-publish.js.map +1 -1
  78. package/dist/component-plan.d.ts.map +1 -1
  79. package/dist/component-plan.js +116 -32
  80. package/dist/component-plan.js.map +1 -1
  81. package/dist/component-scan.d.ts +4 -2
  82. package/dist/component-scan.d.ts.map +1 -1
  83. package/dist/component-scan.js +7 -1
  84. package/dist/component-scan.js.map +1 -1
  85. package/dist/config-path.d.ts +6 -0
  86. package/dist/config-path.d.ts.map +1 -0
  87. package/dist/config-path.js +6 -0
  88. package/dist/config-path.js.map +1 -0
  89. package/dist/config.d.ts +3 -0
  90. package/dist/config.d.ts.map +1 -1
  91. package/dist/config.js +30 -5
  92. package/dist/config.js.map +1 -1
  93. package/dist/contract.d.ts +5 -10
  94. package/dist/contract.d.ts.map +1 -1
  95. package/dist/contract.js.map +1 -1
  96. package/dist/cost-model.d.ts +30 -0
  97. package/dist/cost-model.d.ts.map +1 -1
  98. package/dist/cost-model.js +123 -4
  99. package/dist/cost-model.js.map +1 -1
  100. package/dist/cost.d.ts.map +1 -1
  101. package/dist/cost.js +18 -3
  102. package/dist/cost.js.map +1 -1
  103. package/dist/custom-publish.js.map +1 -1
  104. package/dist/custom-validation-prompt.js +1 -1
  105. package/dist/custom-validation-prompt.js.map +1 -1
  106. package/dist/deduplication/checkpointed-review.d.ts.map +1 -1
  107. package/dist/deduplication/checkpointed-review.js.map +1 -1
  108. package/dist/deduplication/codex-review.d.ts +6 -1
  109. package/dist/deduplication/codex-review.d.ts.map +1 -1
  110. package/dist/deduplication/codex-review.js +72 -17
  111. package/dist/deduplication/codex-review.js.map +1 -1
  112. package/dist/deduplication/deduplication-reviewer.d.ts.map +1 -1
  113. package/dist/deduplication/deduplication-reviewer.js.map +1 -1
  114. package/dist/deduplication/deduplication.d.ts +2 -0
  115. package/dist/deduplication/deduplication.d.ts.map +1 -1
  116. package/dist/deduplication/deduplication.js +99 -26
  117. package/dist/deduplication/deduplication.js.map +1 -1
  118. package/dist/deduplication/retry.d.ts +3 -0
  119. package/dist/deduplication/retry.d.ts.map +1 -0
  120. package/dist/deduplication/retry.js +15 -0
  121. package/dist/deduplication/retry.js.map +1 -0
  122. package/dist/deduplication/scan.d.ts +2 -0
  123. package/dist/deduplication/scan.d.ts.map +1 -1
  124. package/dist/deduplication/scan.js +4 -2
  125. package/dist/deduplication/scan.js.map +1 -1
  126. package/dist/deep-config.d.ts +17 -0
  127. package/dist/deep-config.d.ts.map +1 -0
  128. package/dist/deep-config.js +145 -0
  129. package/dist/deep-config.js.map +1 -0
  130. package/dist/deep-progress.d.ts.map +1 -1
  131. package/dist/deep-scan-defaults.d.ts +9 -0
  132. package/dist/deep-scan-defaults.d.ts.map +1 -0
  133. package/dist/deep-scan-defaults.js +10 -0
  134. package/dist/deep-scan-defaults.js.map +1 -0
  135. package/dist/errors.d.ts.map +1 -1
  136. package/dist/errors.js +2 -2
  137. package/dist/errors.js.map +1 -1
  138. package/dist/feedback.d.ts +20 -0
  139. package/dist/feedback.d.ts.map +1 -0
  140. package/dist/feedback.js +135 -0
  141. package/dist/feedback.js.map +1 -0
  142. package/dist/finding-catalogue.js.map +1 -1
  143. package/dist/finding-workflow.d.ts.map +1 -1
  144. package/dist/finding-workflow.js.map +1 -1
  145. package/dist/findings-client.d.ts +7 -1
  146. package/dist/findings-client.d.ts.map +1 -1
  147. package/dist/findings-client.js +55 -10
  148. package/dist/findings-client.js.map +1 -1
  149. package/dist/findings-import.d.ts +44 -0
  150. package/dist/findings-import.d.ts.map +1 -0
  151. package/dist/findings-import.js +302 -0
  152. package/dist/findings-import.js.map +1 -0
  153. package/dist/github.d.ts +625 -7
  154. package/dist/github.d.ts.map +1 -1
  155. package/dist/github.js.map +1 -1
  156. package/dist/import-scan.d.ts +27 -0
  157. package/dist/import-scan.d.ts.map +1 -0
  158. package/dist/import-scan.js +236 -0
  159. package/dist/import-scan.js.map +1 -0
  160. package/dist/index.d.ts +7 -0
  161. package/dist/index.d.ts.map +1 -1
  162. package/dist/index.js +2 -0
  163. package/dist/index.js.map +1 -1
  164. package/dist/knowledge-base.d.ts +1 -1
  165. package/dist/knowledge-base.d.ts.map +1 -1
  166. package/dist/knowledge-base.js +19 -8
  167. package/dist/knowledge-base.js.map +1 -1
  168. package/dist/models.d.ts.map +1 -1
  169. package/dist/models.js.map +1 -1
  170. package/dist/multiscan.d.ts +7 -5
  171. package/dist/multiscan.d.ts.map +1 -1
  172. package/dist/multiscan.js +212 -55
  173. package/dist/multiscan.js.map +1 -1
  174. package/dist/patch-tui.d.ts.map +1 -1
  175. package/dist/patch-tui.js.map +1 -1
  176. package/dist/project-config-schema.d.ts +191 -0
  177. package/dist/project-config-schema.d.ts.map +1 -0
  178. package/dist/project-config-schema.js +85 -0
  179. package/dist/project-config-schema.js.map +1 -0
  180. package/dist/project-config.d.ts +50 -0
  181. package/dist/project-config.d.ts.map +1 -0
  182. package/dist/project-config.js +220 -0
  183. package/dist/project-config.js.map +1 -0
  184. package/dist/prompt-files.d.ts +13 -0
  185. package/dist/prompt-files.d.ts.map +1 -0
  186. package/dist/prompt-files.js +74 -0
  187. package/dist/prompt-files.js.map +1 -0
  188. package/dist/publication-events.d.ts.map +1 -1
  189. package/dist/publication-events.js +7 -2
  190. package/dist/publication-events.js.map +1 -1
  191. package/dist/publish.d.ts.map +1 -1
  192. package/dist/publish.js +1 -1
  193. package/dist/publish.js.map +1 -1
  194. package/dist/result.d.ts +2 -1
  195. package/dist/result.d.ts.map +1 -1
  196. package/dist/result.js +5 -0
  197. package/dist/result.js.map +1 -1
  198. package/dist/runtime.d.ts +5 -1
  199. package/dist/runtime.d.ts.map +1 -1
  200. package/dist/runtime.js +12 -6
  201. package/dist/runtime.js.map +1 -1
  202. package/dist/scan-comparison.d.ts.map +1 -1
  203. package/dist/scan-comparison.js.map +1 -1
  204. package/dist/scan-dashboard.d.ts +1 -0
  205. package/dist/scan-dashboard.d.ts.map +1 -1
  206. package/dist/scan-dashboard.js +45 -20
  207. package/dist/scan-dashboard.js.map +1 -1
  208. package/dist/scan-history-renderer.d.ts.map +1 -1
  209. package/dist/scan-history-renderer.js.map +1 -1
  210. package/dist/scan-logs.d.ts +39 -3
  211. package/dist/scan-logs.d.ts.map +1 -1
  212. package/dist/scan-logs.js +77 -15
  213. package/dist/scan-logs.js.map +1 -1
  214. package/dist/scan-modes.d.ts +3 -0
  215. package/dist/scan-modes.d.ts.map +1 -0
  216. package/dist/scan-modes.js +2 -0
  217. package/dist/scan-modes.js.map +1 -0
  218. package/dist/scan-settings.d.ts +81 -0
  219. package/dist/scan-settings.d.ts.map +1 -0
  220. package/dist/scan-settings.js +123 -0
  221. package/dist/scan-settings.js.map +1 -0
  222. package/dist/security-policy-cli.d.ts +39 -0
  223. package/dist/security-policy-cli.d.ts.map +1 -0
  224. package/dist/security-policy-cli.js +193 -0
  225. package/dist/security-policy-cli.js.map +1 -0
  226. package/dist/security-policy.d.ts +80 -0
  227. package/dist/security-policy.d.ts.map +1 -0
  228. package/dist/security-policy.js +672 -0
  229. package/dist/security-policy.js.map +1 -0
  230. package/dist/server/dashboard/THIRD_PARTY_NOTICES.txt +2 -2
  231. package/dist/server/dashboard/app.js +2 -2
  232. package/dist/server/dashboard.js.map +1 -1
  233. package/dist/server/embeddings.d.ts.map +1 -1
  234. package/dist/server/embeddings.js.map +1 -1
  235. package/dist/server/errors.d.ts.map +1 -1
  236. package/dist/server/errors.js.map +1 -1
  237. package/dist/server/findings-service.d.ts.map +1 -1
  238. package/dist/server/findings-service.js.map +1 -1
  239. package/dist/server/serve.js.map +1 -1
  240. package/dist/server/sqlite-store.d.ts.map +1 -1
  241. package/dist/server/sqlite-store.js.map +1 -1
  242. package/dist/severity-store.js.map +1 -1
  243. package/dist/targets.d.ts +10 -2
  244. package/dist/targets.d.ts.map +1 -1
  245. package/dist/targets.js +243 -14
  246. package/dist/targets.js.map +1 -1
  247. package/dist/thread-source.d.ts.map +1 -1
  248. package/dist/version.js.map +1 -1
  249. package/dist/worker-progress.d.ts.map +1 -1
  250. package/dist/worker-progress.js.map +1 -1
  251. package/package.json +36 -29
  252. package/schemas/project-config.schema.json +211 -0
  253. package/_bundled_plugin/scripts/resolve_security_md.py +0 -158
@@ -174,18 +174,21 @@ def _scan_root_thread_ids(
174
174
  connection: sqlite3.Connection,
175
175
  scan: sqlite3.Row,
176
176
  supplied_thread_id: str | None,
177
+ *,
178
+ include_owner_threads: bool = True,
177
179
  ) -> list[str]:
178
180
  candidates: list[str | None] = [supplied_thread_id]
179
- if "continuation_thread_id" in scan.keys():
180
- candidates.append(scan["continuation_thread_id"])
181
- if "deep_scan_owner_thread_id" in scan.keys():
182
- candidates.append(scan["deep_scan_owner_thread_id"])
183
- workspace = connection.execute(
184
- "SELECT thread_id FROM workspaces WHERE id = ?",
185
- (scan["workspace_id"],),
186
- ).fetchone()
187
- if workspace is not None:
188
- candidates.append(workspace["thread_id"])
181
+ if include_owner_threads:
182
+ if "continuation_thread_id" in scan.keys():
183
+ candidates.append(scan["continuation_thread_id"])
184
+ if "deep_scan_owner_thread_id" in scan.keys():
185
+ candidates.append(scan["deep_scan_owner_thread_id"])
186
+ workspace = connection.execute(
187
+ "SELECT thread_id FROM workspaces WHERE id = ?",
188
+ (scan["workspace_id"],),
189
+ ).fetchone()
190
+ if workspace is not None:
191
+ candidates.append(workspace["thread_id"])
189
192
  if scan["mode"] == "deep":
190
193
  candidates.extend(
191
194
  row["sdk_thread_id"]
@@ -208,6 +211,16 @@ def _scan_root_thread_ids(
208
211
  return roots
209
212
 
210
213
 
214
+ def _scan_execution_thread_ids(connection: sqlite3.Connection, scan: sqlite3.Row) -> list[str]:
215
+ # CLI recipes identify dedicated executions; Desktop continuations can be shared.
216
+ return _scan_root_thread_ids(
217
+ connection,
218
+ scan,
219
+ scan["continuation_thread_id"] if scan["recipe_json"] is not None else None,
220
+ include_owner_threads=False,
221
+ )
222
+
223
+
211
224
  def _codex_state_database() -> Path | None:
212
225
  configured_database = os.environ.get("CODEX_STATE_DB", "").strip()
213
226
  if configured_database:
@@ -16,6 +16,10 @@ from typing import Any
16
16
  sys.path.insert(0, str(Path(__file__).resolve().parent))
17
17
 
18
18
 
19
+ def reject_non_finite_json(value: str) -> None:
20
+ raise ValueError(f"non-finite JSON number {value!r} is not supported")
21
+
22
+
19
23
  def require_uuid(value: str, label: str) -> str:
20
24
  try:
21
25
  return str(uuid.UUID(value))
@@ -5,6 +5,8 @@ description: "Assess an immutable patch artifact's program impact, regression ri
5
5
 
6
6
  # Assess Patch Risk
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  Explain what can change if the patch merges and whether the available evidence supports merging it. Keep these concepts separate:
9
11
 
10
12
  - **impact if wrong**: the consequence and blast radius of a regression;
@@ -5,6 +5,8 @@ description: Use when Codex is already in the attack-path-analysis phase of a se
5
5
 
6
6
  # Security Attack Path Analysis
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  ## Objective
9
11
 
10
12
  Turn validated or still-plausible findings into explicit attacker stories, structured attack-path analysis facts, severity calibration, and a final reportability decision grounded in the threat model.
@@ -39,7 +39,11 @@ After preserving any native continuation's scan context and applying its one-tim
39
39
 
40
40
  ## Daybreak Access Advisory
41
41
 
42
- Immediately before the first `start_codex_security_deep_scan` call, the top-level parent calls the plugin's `get_codex_security_daybreak_access` tool once when available; workers never perform this advisory. ChatGPT-authenticated desktop and CLI sessions both support this advisory; API-key-only sessions cannot verify account access. Reuse an existing result when continuing the same scan. Report the exact `status` and available Daybreak programs. If `status` is `not_granted`, prominently warn before scan-start progress that Daybreak access is not granted and protected outputs may not be displayable, and include the returned `enrollmentUrl` as a clickable application link, falling back to `https://chatgpt.com/cyber` when it is absent. If `status` is `unknown`, `stale` is `true`, or the tool is unavailable or fails, warn that access could not be verified and protected outputs may not be displayable. Then continue regardless: the advisory never authorizes, gates, or becomes a capability preflight for the scan. Do not poll or repeat it between phases; recheck only when the user explicitly requests a fresh result after an account or Daybreak access change.
42
+ Immediately before the first `start_codex_security_deep_scan` call, the top-level parent calls the plugin's `get_codex_security_daybreak_access` tool once only if it is available in the current session; workers never perform this advisory. If the tool is unavailable, skip the advisory silently: do not attempt a call, probe for it, or use a replacement access tool or connector. ChatGPT-authenticated desktop and CLI sessions support this advisory; skip it silently in known API-key-only sessions, which cannot verify account access. Reuse an existing result when continuing the same scan.
43
+
44
+ If the call fails, returns `status: "unknown"`, or returns `stale: true`, continue silently. Do not expose the unavailable check, unknown status, empty program list, or a speculative protected-output warning in progress messages or the final response. For a fresh `granted` result, report the exact status and available Daybreak programs. For a fresh `not_granted` result, prominently warn before scan-start progress that Daybreak access is not granted and protected outputs may not be displayable, and include the returned `enrollmentUrl` as a clickable application link, falling back to `https://chatgpt.com/cyber` when absent.
45
+
46
+ Continue regardless: the advisory never authorizes, gates, or becomes a capability preflight for the scan. Do not retry, poll, or repeat it between phases. If the user explicitly asks about Daybreak access, report the result or explain that it could not be verified; an unavailable or unknown result does not establish that access is denied. Recheck only when the user explicitly requests a fresh result after an account or Daybreak access change, and only when the tool is available.
43
47
 
44
48
  ## Run Independent Standard Scans
45
49
 
@@ -12,15 +12,15 @@ A useful `SECURITY.md` tells Codex Security what matters in a repository: the sy
12
12
  Confirm the repository or component the user wants to cover. Inventory policy paths, including hidden directories, before reading them:
13
13
 
14
14
  ```bash
15
- <python_command> <plugin_dir>/scripts/resolve_security_md.py --repo <repo_root> --list
15
+ <plugin_dir>/scripts/launch_codex_security_mcp --helper resolve-security-md --repo <repo_root> --list
16
16
  ```
17
17
 
18
- The command runs on Windows, macOS, and Linux. It emits a sorted JSON array of repository-relative policy paths, escapes control characters unambiguously, includes linked policies without following directory links, and prunes Git metadata. Resolve each candidate within the repository and check the resolved regular file's byte size. Do not pass policies larger than 1 MiB to the resolver; report them so the user can decide how to proceed. The resolver enforces the same limit for regular files and repository-local symbolic links.
18
+ On Windows, use `launch_codex_security_mcp.cmd` with the same arguments. The launcher reuses the plugin's configured or bundled Node runtime. It emits a sorted JSON array of repository-relative policy paths, escapes control characters unambiguously, includes linked policies without following directory links, and prunes Git metadata. Resolve each candidate within the repository and check the resolved regular file's byte size. Do not pass policies larger than 1 MiB to the resolver; report them so the user can decide how to proceed. The resolver enforces the same limit for regular files and repository-local symbolic links.
19
19
 
20
20
  Read `../../references/security-guidance.md`, then resolve the policy chain for the file or directory being reviewed:
21
21
 
22
22
  ```bash
23
- <python_command> <plugin_dir>/scripts/resolve_security_md.py --repo <repo_root> --scope <file_or_directory> --out -
23
+ <plugin_dir>/scripts/launch_codex_security_mcp --helper resolve-security-md --repo <repo_root> --scope <file_or_directory> --out -
24
24
  ```
25
25
 
26
26
  `<plugin_dir>` is the Codex Security plugin root containing `.codex-plugin/plugin.json`, not the target repository or this skill directory.
@@ -5,6 +5,8 @@ description: Use when Codex is already in the finding-discovery phase of a secur
5
5
 
6
6
  # Security Finding Discovery
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  ## Objective
9
11
 
10
12
  Investigate the proposed code or code changes for technically plausible security vulnerabilities using the threat model as context.
@@ -1,10 +1,12 @@
1
1
  ---
2
2
  name: fix-finding
3
- description: Use when the user explicitly asks to fix and verify a validated or plausible security finding. Do not use as the primary trigger for full PR, commit, branch, patch, or repository scans.
3
+ description: Use only when the user explicitly asks to fix and verify a validated or plausible security vulnerability. Do not use for ordinary bug fixes, correctness or design review findings, general validation, or full PR, commit, branch, patch, or repository scans.
4
4
  ---
5
5
 
6
6
  # Fix Finding
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  ## Objective
9
11
 
10
12
  Turn a current security finding into a minimal, validated code change. If the code is already safe, prove that and report that no change was needed.
@@ -1,4 +1,4 @@
1
1
  interface:
2
- display_name: "Fix Finding"
2
+ display_name: "Fix Security Finding"
3
3
  short_description: "Fix and verify a given security finding"
4
4
  default_prompt: "Use $fix-finding to fix a given security finding and verify the issue no longer reproduces."
@@ -5,6 +5,8 @@ description: Develop evidence-backed structural and architectural security harde
5
5
 
6
6
  # Propose Security Hardening
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  ## Objective
9
11
 
10
12
  Turn a collection of security evidence into a decision-ready portfolio of structural or architectural hardening opportunities. The evidence may be a Codex Security scan that is still in final reporting or is already complete,
@@ -12,7 +12,11 @@ Resolve the target, requested scope, and user-provided security context before s
12
12
 
13
13
  Use the returned `scanId`, `scanDir`, scope, and exact `userContext` throughout the parent workflow. Read `../../../references/desktop-config-preflight.md` and run capability preflight only after this authoritative context exists.
14
14
 
15
- Use the existing desktop phase labels for work that actually occurs: threat mapping, investigation, parent-led validation, attack-path assessment, and report assembly. Preserve the authoritative scan ID and handoff token. Increase the investigator total before dispatching each newly discovered assignment; the concurrently running baseline is independent and does not inflate that total. Capture each completed, source-backed investigation as a real coverage surface before advancing its `review_receipts` progress count. Do not create separate receipt files. Advance later phase counts only after the corresponding finding or report artifact exists, and never invent counts, phase workers, or coverage.
15
+ ## Publish Live Progress
16
+
17
+ Call `update_codex_security_scan_progress({ scanId, handoffClaimToken, phase })` when entering each real phase. After publishing a ready preflight result, set `phase: "threat_model"` before mapping security boundaries. Set `discovery` before dispatching investigation packets, `validation` before parent validation, `attack_path` before assessing reachability, and `reporting` before assembling the final report inputs. Preserve the current phase when work overlaps; never move backward or repeat completed work. Use the returned `scan.userContext` for the new phase and its workers.
18
+
19
+ Publish meaningful completed-review batches through the same tool. Increase the investigator total before dispatching each newly discovered assignment; the concurrently running baseline is independent and does not inflate that total. Capture each completed, source-backed investigation as a real coverage surface before advancing its `review_receipts` progress count. Do not create separate receipt files. Advance later phase counts only after the corresponding finding or report artifact exists, and never invent counts, phase workers, or coverage. Accepted checkpoints also advance a Standard scan to at least `discovery`, and the final draft advances it to `reporting`; publish earlier phase transitions as they happen instead of waiting for a checkpoint.
16
20
 
17
21
  ## Complete The Same Scan
18
22
 
@@ -5,6 +5,8 @@ description: Use when Codex is already in the threat-modeling phase of a securit
5
5
 
6
6
  # Security Threat Model
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  Create or reuse the repository-scoped threat model defined in `../../references/scan-artifacts.md`. Honor explicit user-provided input and output paths. If an explicitly required input is missing, ask for it instead of substituting a generated model. A generated model describes the repository's actual architecture, attacker capabilities, trust boundaries, and security-relevant failure modes.
9
11
 
10
12
  Standard scans and Deep Scan workers build their threat models within their ordinary Standard scan workflow; neither invokes this separate phase skill.
@@ -5,6 +5,8 @@ description: Use when Codex is already in the validation phase of a security sca
5
5
 
6
6
  # Security Validation
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  ## Objective
9
11
 
10
12
  Take candidate findings from discovery and produce the strongest evidence-backed validation assessment you can. Prefer targeted, non-interactive reproduction or falsification when it is feasible and proportionate, but use focused code tracing when dynamic execution is blocked by missing services, unavailable infrastructure, or excessive setup relative to the candidate and scan scope.
@@ -5,6 +5,8 @@ description: Turn vulnerability notes, disclosure reports, PoCs, source code, or
5
5
 
6
6
  # Vulnerability Writeup
7
7
 
8
+ Before choosing paths or saving retained output, read `../../references/artifact-storage.md` and follow its storage policy.
9
+
8
10
  ## Purpose
9
11
 
10
12
  Produce a disclosure report that another security researcher can understand, check and, where safely possible, reproduce. Treat the original finding as a hypothesis, not a conclusion. Establish the assessed software version, attacker position, reachable entry point, expected security behaviour, actual failure and narrowest demonstrated impact before deciding how strongly the report can speak. Pin the exact underlying source privately so the report remains accurate without burdening the reader with unnecessary commit hashes.
package/dist/api.d.ts CHANGED
@@ -3,39 +3,26 @@ import { CodexLoginHandle, type AccountStatus } from "./auth.js";
3
3
  import { type CodexSecurityConfig, type JsonObject } from "./config.js";
4
4
  import { type ScanCost, type ScanSessionEvent } from "./cost.js";
5
5
  import { type DeepScanProgress } from "./deep-progress.js";
6
+ import { type DeepScanSources } from "./deep-config.js";
7
+ import { type DeepScanOptions, type ScanAuthMode, type ScanSettings } from "./scan-settings.js";
8
+ export { SCAN_AUTH_MODES } from "./scan-settings.js";
9
+ export type { DeepScanOptions, ScanAuthMode } from "./scan-settings.js";
6
10
  import { ScanResult } from "./result.js";
7
- import type { SeverityLevel } from "./models.js";
11
+ import { type SecurityPolicyDraft, type SecurityPolicyOptions, type SecurityPolicyPreflight } from "./security-policy.js";
8
12
  import { type ScanActivity } from "./scan-activity.js";
9
13
  import { type ScanProgress, type ScanWorkerStatus } from "./worker-progress.js";
10
14
  import { importAmbientAuth, type ProcessEnvironment } from "./runtime.js";
11
- import { type NormalizedTarget, type ScanMode, type ScanTarget } from "./targets.js";
12
- export interface DeepScanOptions {
13
- workers?: number;
14
- subagents?: number;
15
- stopAfterNoNew?: number;
16
- maxDiscoveryRuns?: number;
17
- maxTimeHours?: number;
18
- }
19
- export interface ScanOptions extends DeepScanOptions {
15
+ import { type NormalizedTarget, type ScanMode } from "./targets.js";
16
+ export interface ScanOptions extends ScanSettings {
20
17
  /** Save synthetic Standard scan results without calling Codex or a model. */
21
18
  mock?: boolean;
22
19
  /** Opt into a durable scan -> custom publication -> dedupe workflow. */
23
20
  workflowId?: string;
24
- auth?: ScanAuthMode;
25
21
  /** Stable, privacy-preserving end-user ID for this scan's model requests. */
26
22
  safetyIdentifier?: string;
27
- target?: ScanTarget;
28
- mode?: ScanMode;
29
- knowledgeBasePaths?: string[];
30
- scanPrompt?: string;
31
- validationPrompt?: string;
32
- postScanPrompt?: string;
33
- outputDir?: string;
34
23
  archiveExisting?: boolean;
35
24
  parentScanId?: string;
36
25
  expectedPluginVersion?: string;
37
- failureSeverity?: SeverityLevel;
38
- maxCostUsd?: number;
39
26
  onCost?: (cost: Readonly<ScanCost>, maxCostUsd?: number) => void;
40
27
  onBudgetApproaching?: (budget: ScanBudget) => number | undefined | Promise<number | undefined>;
41
28
  onOutputArchived?: (archiveDir: string) => void;
@@ -65,8 +52,6 @@ export interface ValidationResult {
65
52
  outputDir: string;
66
53
  threadId: string | null;
67
54
  }
68
- export declare const SCAN_AUTH_MODES: readonly ["auto", "chatgpt", "api-key"];
69
- export type ScanAuthMode = (typeof SCAN_AUTH_MODES)[number];
70
55
  export type ScanAuthentication = {
71
56
  method: "command";
72
57
  verified: false;
@@ -96,7 +81,7 @@ export interface ScanBudget {
96
81
  cost: Readonly<ScanCost>;
97
82
  signal: AbortSignal;
98
83
  }
99
- type ScanObserverName = "onAuthentication" | "onCost" | "onOutputArchived" | "onOutputDirReady" | "onScanStarted" | "onTrustedAccessStatus" | "onReconnect" | "onActivity" | "onSessionEvent" | "onProgress" | "onDeepProgress" | "onWorkerStatus" | "onWarning";
84
+ type ScanObserverName = "onAuthentication" | "onCost" | "onOutputArchived" | "onOutputDirReady" | "onScanStarted" | "onTrustedAccessStatus" | "onReconnect" | "onActivity" | "onSessionEvent" | "onProgress" | "onDeepProgress" | "onWorkerStatus" | "onStage" | "onWarning";
100
85
  export interface ScanPreflight extends DeepScanOptions {
101
86
  repository: string;
102
87
  target: NormalizedTarget;
@@ -109,6 +94,7 @@ export interface ScanPreflight extends DeepScanOptions {
109
94
  modelProvider?: string;
110
95
  reasoningEffort: string;
111
96
  maxCostUsd?: number;
97
+ deepScanSources?: DeepScanSources;
112
98
  }
113
99
  export interface CodexSecurityMetadata {
114
100
  sdk: "@openai/codex-sdk";
@@ -128,6 +114,11 @@ export declare class CodexSecurity {
128
114
  run(repository: string, options?: ScanOptions): Promise<ScanResult>;
129
115
  validate(options: ValidationOptions): Promise<ValidationResult>;
130
116
  preflight(repository: string, options?: ScanOptions): Promise<ScanPreflight>;
117
+ preflightPolicy(repository: string, options?: SecurityPolicyOptions): Promise<SecurityPolicyPreflight>;
118
+ generatePolicy(repository: string, options?: SecurityPolicyOptions): Promise<SecurityPolicyDraft>;
119
+ previewPolicy(draft: SecurityPolicyDraft, options?: {
120
+ signal?: AbortSignal;
121
+ }): Promise<string>;
131
122
  loginApiKey(apiKey: string): Promise<void>;
132
123
  loginChatGPT(): Promise<CodexLoginHandle>;
133
124
  loginChatGPTDeviceCode(): Promise<CodexLoginHandle>;
@@ -147,5 +138,4 @@ export declare function classifyConnectionFailure(error: unknown): "rate_limited
147
138
  export declare function scanRuntimeCodexConfig(config: JsonObject, protectedCredentialHome?: string): JsonObject;
148
139
  export declare function scanPreflightCodexConfig(config: JsonObject): JsonObject;
149
140
  export declare function environmentValue(environment: ProcessEnvironment, requested: string): string | undefined;
150
- export {};
151
141
  //# sourceMappingURL=api.d.ts.map
package/dist/api.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":";AAqCA,OAAO,EAGL,gBAAgB,EAGhB,KAAK,aAAa,EACnB,MAAM,WAAW,CAAC;AAMnB,OAAO,EAWL,KAAK,mBAAmB,EACxB,KAAK,UAAU,EAEhB,MAAM,aAAa,CAAC;AACrB,OAAO,EAGL,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACtB,MAAM,WAAW,CAAC;AACnB,OAAO,EAEL,KAAK,gBAAgB,EACtB,MAAM,oBAAoB,CAAC;AA+B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