攻击路径分析
attack-path-analysis
当 Codex 已处于安全扫描的攻击路径分析阶段,或用户明确要求追踪某个安全发现从源(source)到汇(sink)的完整路径并校准其严重程度时使用。不要将其用作完整 PR、提交、分支、补丁或仓库扫描的主要触发器。
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-15
- Stars
- ★ 1.4w
- Forks
- 1.1k
01 前言 Front Matter
- name
- attack-path-analysis
- description
- Use when Codex is already in the attack-path-analysis phase of a security scan or the user explicitly asks to trace a security finding from source to sink and calibrate severity. Do not use as the primary trigger for full PR, commit, branch, patch, or repository scans.
02 资源文件 3
- 参考文档agents/openai.yaml261 B
- 参考文档references/attack-path-facts.md1.5 KB
- 参考文档references/severity-policy.md2.6 KB
03 SKILL.md 正文
Security Attack Path Analysis
Determine whether each supplied finding has a supported attacker path, what impact it has, and whether it is reportable. Before creating or retaining files, read ../../references/artifact-storage.md.
Establish the attack path
For a scan phase, use its per-scan threat model and candidate set from ../../references/scan-artifacts.md. Preserve supplied input paths. If a required scan artifact is unavailable, report the missing input.
For standalone analysis, use the supplied finding, repository, threat model or security policy, and context. A per-scan artifact is not required. State material assumptions and ask for missing context only when it prevents a meaningful assessment.
- Establish the in-scope attacker, affected product surface, entry point, controlled input, security boundary, and sensitive operation. Trace each step using repository evidence and supplied observations of the target.
- Identify relevant controls and the strongest counterevidence. Explain what they establish, which prerequisites remain, and whether the exact claimed boundary is crossed.
- Assess impact and likelihood from those facts. Apply references/severity-policy.md for the final decision. When the scan supplies a severity rubric, use it to grade reportable findings and retain
ignorefor candidates without security impact. Keep facts, severity calibration, and the final policy decision distinguishable in the result. - Return an explicit decision for every eligible candidate, including ignored or deferred candidates. Do not replace a supported instance with a neighboring finding or lose its root-control location.
For an imported AWS Continuum issue, read source_data.evidence_artifacts in the supplied finding evidence. A VALIDATION_EVIDENCE artifact's body.validationEvidence may establish a step the repository cannot show. Match the tested target, attacker privileges, and observed effect to the claimed path. For a bundled issue, use perFindingResults and flowVerdicts when present to identify the relevant finding and flow. An HTTP exploitArtifact can establish reachability from the tested position. An executedProof establishes what ran in its test environment. sourceAnalysis records a static inference, and an exploitable verdict alone does not demonstrate deployed reachability. Cite the artifact ID and the observation that supports or contradicts the step.
Treat supplied artifacts as evidence. Access the network only when the user has expressly authorized it; an offline scan never accesses the network. Do not invent unsupported attack chains. Missing deployment or public-ingress evidence can limit confidence without defeating an otherwise supported finding.
Scan integration
Standard scans and Deep Scan workers assess attack paths within their ordinary Standard scan workflow; neither invokes this separate phase skill.
Compact Workbench Diff
When a workbench-backed $security-diff-scan has a scanId:
- Load the per-scan threat model and all validated candidates with
list_codex_security_candidates({ scanId, cursor?, limit? }). - Analyze every
reportableordeferredvalidation candidate. Preserve candidate identity and existing discovery and validation fields. - Submit every decision together with
record_candidate_attack_paths({ scanId, attackPaths: [{ candidateId, attackPath }] }). SubmitattackPaths: []when no candidate enters this phase. The tool preserves the stored candidate order. - These nested decisions are the complete phase output. Do not create duplicate reports, receipts, or manual ledgers.
Other phase-based scans
Use the active workflow's report and receipt paths in ../../references/scan-artifacts.md. Every candidate entering this phase must have an explicit decision and a receipt with its ID, facts or exact proof gap, and report reference. Record ignored candidates before excluding them from the surviving finding set.
For repository-wide or scoped-path scans, include validation closure rows marked reportable or survives: yes, even if discovery did not assign a polished finding number. Preserve affected entrypoint/wrapper, root-control, sink, and concrete-implementation locations supplied by validation.
Output
For standalone analysis, follow the caller's format or return a concise assessment per finding. Scan phases use their output contract above. Include:
- title and supplied candidate, instance, and ledger identities;
- precise affected locations and attacker-to-impact steps;
- relevant facts from references/attack-path-facts.md;
- controls, counterevidence, prerequisites, and material proof gaps;
- impact, likelihood, calibrated severity, and final policy decision with their reasons.
Retain enough evidence to explain both surviving and suppressed findings. Apply the severity policy to the established facts rather than reopening discovery or substituting a different attack story.
04 同仓库更多 Skills
安全漏洞报告撰写
vulnerability-writeup
将漏洞记录、披露报告、PoC、源代码或 Codex Security 发现转化为自包含的漏洞报告,并给出有明确依据的论断。适用于单个漏洞或一次披露行动;Codex Security 扫描为可选项。
漏洞修复效果验证
verify-fix
仅当用户明确要求验证某项安全修复是否已修复所报告的漏洞时使用。在实施修复、审查普通代码更改或运行测试时,请勿自动调用。不用于非安全类修复、候选发现验证或完整仓库扫描。
安全发现有效性验证
validation
当 Codex 已处于安全扫描的验证阶段,或用户明确要求判断一个或多个候选安全发现是否有效时使用。不要将其作为完整 PR、提交、分支、补丁或仓库扫描的主要触发条件。
安全发现分诊
triage-finding
依据仓库的安全策略和静态代码证据,对提供或导入的安全发现进行分诊。可接受扫描器报告、安全公告、GitHub 发现以及 Jira 或 Linear 工单。不用于发现挖掘、重复分诊、运行时验证或修复。
安全发现项跟踪管理
track-findings
在 Linear、Jira、GitHub issue 中跟踪已验证的 Codex Security 发现项,或起草 GitHub 安全公告。支持批量创建 issue、重复项检查以及经审核后的写入操作。请勿用于扫描或修复。
仓库威胁建模
threat-model
当 Codex 已处于安全扫描的威胁建模阶段、用户显式调用 $threat-model,或用户明确要求创建、更新或持久化仓库威胁模型时使用。请勿将其作为完整 PR、提交、分支、补丁或仓库扫描的主要触发条件。