The audit is not accepted as truth
The instructor asks Codex for a read-only audit. Each finding must cite files and receive a grade. Then you close or ignore the AI output, run your own manual scan, and compare the two sets of findings. The useful artifact is the report you review, label, reconcile and prioritize.
- 1Read-only auditCodex cites files for every finding
- 2GradeValid, False Positive or Noise
- 3Manual scanYour own pass, AI output closed
- 4ReconcileAgreement, AI-only, You-only
- 5Top-3 backlogRanked Valid findings with next actions
What a strong security prompt requires
The notes’ prompt names the files to inspect, forbids edits, asks for file, risk and repo relevance for every finding, and makes an empty category an acceptable answer. That last line matters: it removes the pressure to invent a finding to fill space. Prompt 5.2A in the library extends it with six focus areas and a table format.
Prompt from the notesPerform a read-only security audit of this Task Tracker repository. Inspect relevant files before answering, including app/, tests/, frontend if present, requirements or dependency files, Dockerfile, and GitHub workflows if present. Do not edit files. For each finding, cite the file, explain the risk, and state why it matters for this repo. If a category has no finding, say that explicitly rather than inventing one.
Three grades for every finding
Each AI finding gets exactly one grade and a one-sentence reason.
| Grade | Use when... | Example reasoning |
|---|---|---|
| Valid | The issue is real for this codebase and the risk explanation fits the project. | The task body has no length limit, so a client can create oversized in-memory data. |
| False Positive | The finding is wrong about behavior, severity, or project context. | The audit claims SQL injection, but this learning project does not use SQL. |
| Noise | The statement is technically true but too generic, trivial, or not actionable. | “Validate all input” without a file, field, or concrete failure mode is not useful. |
Read with careThe library’s grading prompt (5.2B) defines Valid a little more broadly than the notes: it also counts a course-scope limitation that would matter outside the learning context. Say which definition you used in your report.
Your manual scan
Close the AI output and look for yourself. The notes give six lenses and why each matters. Your findings here are usually Valid, but they still need evidence.
| Look for | Why it matters |
|---|---|
| Unbounded fields | Long titles, descriptions, authors, or comment bodies can create storage and response-size risks. |
| Authorization or ownership gaps | A no-auth course project may be intentional, but the production risk still needs to be named clearly. |
| Client-trusted data | Data such as IDs, timestamps, or status changes may need server-side rules. |
| Error leakage | Raw stack traces, internal paths, or verbose errors can expose implementation details. |
| Secrets or real data | Credentials, tokens, environment files, local paths, and real customer data should not be exposed. |
| Docker and CI defaults | Running as root, broad permissions, or weak workflow assumptions may matter later. |
Examples from the lecture
The notes walk through four typical findings. The common thread is context: grade how accurately Codex frames the risk for this project, not whether the sentence sounds alarming.
| Example | How to think about it |
|---|---|
| No authentication, authorization, or ownership checks on task endpoints | In the learning project this may be an intentional scope decision. In production it is still a real risk. Grade based on how accurately Codex frames the context. |
| Unbounded task creation or string fields | A concrete, repo-specific finding if the model or validation layer lacks length limits. |
| CORS allows null origins or broad methods/headers | May be acceptable for local development, but the risk should be documented before deployment. |
| Generic OWASP-style advice | Useful as background, but not a finding unless tied to a file, behavior, and project-specific risk. |
The security review artifact
docs/security-review.md has four sections. The notes’ instructor emphasis: a useful audit cites real files, a weak audit gives generic advice, and the most important column is You-only, because it shows the judgment Codex did not supply.
| Section in docs/security-review.md | What to include |
|---|---|
| AI findings table | Finding, file evidence, risk, grade, and one sentence explaining the grade. |
| My manual findings | Findings you identified without relying on Codex output. These are usually Valid, but still need evidence. |
| Reconciliation | Three columns: Agreement, AI-only, You-only. The You-only column is where your business logic and threat-model judgment often appears. |
| Top-3 backlog | The three most important Valid findings, ranked by severity and given suggested owners or next actions. |
Key ideaThe You-only column is the evidence of your judgment. An empty one usually means the manual scan was skipped.
Before you call it done
The notes’ verification checklist for this activity. The only code change the module allows here is an optional, explicitly approved one-line fix; prompt 5.2X asks for the diff without applying it and sends anything larger to the backlog.
- Every AI finding has one grade: Valid, False Positive, or Noise.
- Every grade has a one-sentence explanation.
- The report includes at least one manual finding or a clear note explaining what you checked and found.
- The reconciliation section includes Agreement, AI-only, and You-only categories.
- The top-3 backlog contains concrete next actions, not just a list of risks.
- No feature work or broad app/ edits were accepted as part of this activity.
Key takeaways
- The AI audit is input to grade, not a report to submit.
- Valid is real for this repo; False Positive is wrong about behavior, severity or context; Noise is true but not actionable.
- Close the AI output and scan yourself with the six lenses.
- You-only is the most important column; the backlog needs owners and next actions.