1# Audit dependency incidents | Codex use cases1---
2name: Audit dependency incidents
3tagline: Turn a public package advisory into a safe repo-audit plan.
4summary: Use Codex to turn a public package or supply chain advisory into a
5 read-only audit, then inspect manifests, lock files, CI workflows, and scripts
6 without running untrusted code.
7skills:
8 - token: github
9 url: /codex/integrations/github
10 description: Inspect repository files, pull requests, workflows, and
11 security-relevant history.
12bestFor:
13 - Engineering and security teams responding to public package or supply chain
14 advisories.
15 - Maintainers who need to check lock files, scripts, CI permissions, and
16 caches before changing dependencies.
17 - Incident reviews where Codex should gather evidence without installing
18 packages or running untrusted code.
19starterPrompt:
20 title: Build the Incident Audit
21 body: >-
22 Help me audit this repository for exposure to this public package advisory:
23 [advisory URL].
2 24
3Codex use cases
4 25
526 Stay read-only unless I explicitly approve a remediation step.
6 27
7
8 28
9Codex use case29 First, summarize:
10 30
11# Audit dependency incidents31 - affected packages and version ranges
12 32
13Turn a public package advisory into a safe repo-audit plan.33 - authoritative sources versus broader reports
14 34
15Difficulty **Advanced**35 - what evidence would prove exposure in this repo
16 36
17Time horizon **1h**37 - what evidence would rule it out
18 38
19Use Codex to turn a public package or supply chain advisory into a read-only audit, then inspect manifests, lock files, CI workflows, and scripts without running untrusted code.
20 39
21## Best for40 Then inspect:
22 41
23- Engineering and security teams responding to public package or supply chain advisories.42 - package manifests and lock files
24- Maintainers who need to check lock files, scripts, CI permissions, and caches before changing dependencies.
25- Incident reviews where Codex should gather evidence without installing packages or running untrusted code.
26 43
27# Contents44 - CI workflows and permissions
28 45
29[← All use cases](https://developers.openai.com/codex/use-cases)46 - install, build, and postinstall scripts
30 47
31Copy page [Export as PDF](https://developers.openai.com/codex/use-cases/dependency-incident-audits/?export=pdf)48 - vendored artifacts, containers, or generated bundles if relevant
32 49
33Use Codex to turn a public package or supply chain advisory into a read-only audit, then inspect manifests, lock files, CI workflows, and scripts without running untrusted code.50 - cache or token exposure paths if the advisory involves CI or publishing
34 51
35Advanced
36 52
371h53 Return:
38 54
39Related links55 - evidence status: confirmed exposure, needs verification, or ruled out
40 56
41[Codex Security](https://developers.openai.com/codex/security) [Agent approvals and security](https://developers.openai.com/codex/agent-approvals-security) [Codex cyber safety](https://developers.openai.com/codex/concepts/cyber-safety)57 - severity and blast-radius notes
42 58
43## Best for59 - file references for every repo-specific claim
44 60
45- Engineering and security teams responding to public package or supply chain advisories.61 - caveats and recommended next steps
46- Maintainers who need to check lock files, scripts, CI permissions, and caches before changing dependencies.
47- Incident reviews where Codex should gather evidence without installing packages or running untrusted code.
48 62
49## Skills & Plugins
50 63
51- [GitHub](https://developers.openai.com/codex/integrations/github)64 Do not install packages, run lifecycle scripts, build the project, execute
52 65 untrusted code, rotate credentials, or clean up files unless I explicitly
53 Inspect repository files, pull requests, workflows, and security-relevant history.66 approve that step.
54 67 suggestedEffort: high
55| Skill | Why use it |68relatedLinks:
56| --- | --- |69 - label: Codex Security
57| [GitHub](https://developers.openai.com/codex/integrations/github) | Inspect repository files, pull requests, workflows, and security-relevant history. |70 url: /codex/security
58 71 - label: Agent approvals and security
59## Starter prompt72 url: /codex/agent-approvals-security
60 73 - label: Codex cyber safety
61Help me audit this repository for exposure to this public package advisory: [advisory URL].74 url: /codex/concepts/cyber-safety
62Stay read-only unless I explicitly approve a remediation step.75---
63First, summarize:
64- affected packages and version ranges
65- authoritative sources versus broader reports
66- what evidence would prove exposure in this repo
67- what evidence would rule it out
68Then inspect:
69- package manifests and lock files
70- CI workflows and permissions
71- install, build, and postinstall scripts
72- vendored artifacts, containers, or generated bundles if relevant
73- cache or token exposure paths if the advisory involves CI or publishing
74Return:
75- evidence status: confirmed exposure, needs verification, or ruled out
76- severity and blast-radius notes
77- file references for every repo-specific claim
78- caveats and recommended next steps
79Do not install packages, run lifecycle scripts, build the project, execute untrusted code, rotate credentials, or clean up files unless I explicitly approve that step.
80
81Open in the Codex app
82
83Help me audit this repository for exposure to this public package advisory: [advisory URL].
84Stay read-only unless I explicitly approve a remediation step.
85First, summarize:
86- affected packages and version ranges
87- authoritative sources versus broader reports
88- what evidence would prove exposure in this repo
89- what evidence would rule it out
90Then inspect:
91- package manifests and lock files
92- CI workflows and permissions
93- install, build, and postinstall scripts
94- vendored artifacts, containers, or generated bundles if relevant
95- cache or token exposure paths if the advisory involves CI or publishing
96Return:
97- evidence status: confirmed exposure, needs verification, or ruled out
98- severity and blast-radius notes
99- file references for every repo-specific claim
100- caveats and recommended next steps
101Do not install packages, run lifecycle scripts, build the project, execute untrusted code, rotate credentials, or clean up files unless I explicitly approve that step.
102 76
103## Start with a safe audit plan77## Start with a safe audit plan
104 78
105When a dependency or supply chain incident moves quickly, the first useful output isn’t a rushed patch. It’s a clear audit plan: what changed, which packages or workflows might be affected, and what evidence would prove exposure in your repo.79When a dependency or supply chain incident moves quickly, the first useful output isn't a rushed patch. It's a clear audit plan: what changed, which packages or workflows might be affected, and what evidence would prove exposure in your repo.
106 80
107Use Codex to turn the advisory into a conservative, read-only checklist before installing, building, testing, or running anything.81Use Codex to turn the advisory into a conservative, read-only checklist before installing, building, testing, or running anything.
108 82
120 98
121A useful audit result should show both how bad a finding would be and how strong the evidence is:99A useful audit result should show both how bad a finding would be and how strong the evidence is:
122 100
123
124Codex
125 101
126**Confirmed exposure:** the lockfile contains an affected
127package version in a production dependency path.
128 102
129**Needs verification:** one CI job has publish permissions, but103<p>
130the workflow does not appear to install the affected package directly.104 <strong>Confirmed exposure:</strong> the lockfile contains an affected
105 package version in a production dependency path.
106 </p>
107 <p>
108 <strong>Needs verification:</strong> one CI job has publish permissions, but
109 the workflow does not appear to install the affected package directly.
110 </p>
111 <p>
112 <strong>Ruled out:</strong> the package name appears in docs only and is not
113 present in manifests or lock files.
114 </p>
115 <p>
116 <strong>Next step:</strong> review the proposed dependency update and token
117 rotation plan before any destructive action.
118 </p>
131 119
132**Ruled out:** the package name appears in docs only and is not
133present in manifests or lock files.
134 120
135**Next step:** review the proposed dependency update and token
136rotation plan before any destructive action.
137 121
138Once the read-only pass is complete, you can ask Codex to prepare a remediation PR, update CI permissions, or write a follow-up incident note. Keep those actions separate from the initial audit.122Once the read-only pass is complete, you can ask Codex to prepare a remediation PR, update CI permissions, or write a follow-up incident note. Keep those actions separate from the initial audit.
139
140Turn the confirmed findings from this audit into a remediation plan.
141For each finding, include:
142- proposed change
143- files or settings to update
144- test or verification step
145- rollback plan
146- whether I need to rotate a credential or review an external system
147Do not make changes yet. Keep any command that could execute untrusted code out of the plan unless you explain why it is safe.
148
149## Related use cases
150
151[
152
153### Run a deep security scan
154
155Use the Codex Security plugin to run a higher-recall, repository-wide audit that repeats...
156
157Engineering Quality](https://developers.openai.com/codex/use-cases/deep-security-scan)[
158
159### Scan code changes for security
160
161Use the Codex Security plugin to examine a Git-backed change set, validate plausible...
162
163Engineering Quality](https://developers.openai.com/codex/use-cases/scan-code-changes-for-security)[
164
165### Remediate a vulnerability backlog
166
167Bring in approved findings from ticketing tools or vulnerability reporting systems, then use...
168
169Engineering Quality](https://developers.openai.com/codex/use-cases/remediate-vulnerability-backlog)
170