Find, confirm and fix security issues in your code without leaving OpenCode.
Ask for a scan in plain words, or drive it yourself from the terminal or the Desktop panel.
The terminal view after a scan. Screenshots use sample data.
It runs [Codex Security](https://developers.openai.com/codex/security) through the official [`@openai/codex-security`](https://www.npmjs.com/package/@openai/codex-security) SDK, using the model and provider you already have configured for Codex. This is an early, unofficial project, not an OpenCode or OpenAI product. ## Quick start **1. Add the plugin** to the `plugins` array in `~/.config/opencode/opencode.json`: ```json { "plugins": [{ "package": "opencode-codex-security@latest" }] } ``` Then restart OpenCode. **2. Open `/security`** in OpenCode. The top of the view shows the provider, model and credentials it will use, and tells you if anything is missing. **3. Ask for a scan**, or press `n`: ```text Run a security scan of this repo. ``` You see a preview of what will be scanned and where the source will be sent, and nothing starts until you approve it. Scans need Python 3.10 or newer.
|
**Scan** Standard or Deep. The whole repository, selected paths, your uncommitted changes, or everything since a branch or commit. For each scan you can pick the reasoning effort, a cost limit and a time limit. Two scans can run at once. **Review findings** Most severe first, each with its location, evidence and a suggested fix. What you have done about a finding (confirmed, dismissed, fix ready, fix applied) is saved with the scan. **Validate** Re-check a finding against the source before you spend time on it. **Fix** The fix is written and verified in a throwaway copy of your last commit. You get a diff, and your files change only if you apply it. Nothing is committed. **Draft a security policy** Ask for a `SECURITY.md` for a repository or one component. The model relays any questions the draft raises, shows you the result, and offers to put it on a branch. Nothing is written unless you say so. **Discuss** Hand any finding to the conversation and have the model explain it. |