* feat(cli): expose identifiers for saved scan follow-up
* test(sdk): exercise dedupe representatives in publication
* feat(cli): make project setup and authentication easier to inspect
* docs(cli): distinguish sign-in flows and credential sources
* feat(cli): link interrupted scans and imported evidence to their next commands
* fix(cli): make command help and discovery reflect runnable workflows
* build(sdk): include the command argument helper in package checks
* refactor(cli): reuse shell path quoting for project previews
* docs(cli): identify the shell used for Windows preview commands
* test(cli): account for the internal publication CSV in help coverage
* fix(cli): scope recovery hints to supported sessions and shells
* fix(cli): declare exclusive scan import sources in the schema
* refactor(cli): share credential locking and project preview preparation
* fix(cli): resolve repository arguments consistently during scan discovery
* refactor(cli): simplify the result handoffs and verify PowerShell recovery
* fix(cli): check sign-in from the same directory in every format
* fix(cli): preserve diagnostics when project initialization fails
---------
Co-authored-by: Codex <noreply@openai.com>
* feat(cli): expose identifiers for saved scan follow-up
* test(sdk): exercise dedupe representatives in publication
* feat(cli): link interrupted scans and imported evidence to their next commands
* fix(cli): make command help and discovery reflect runnable workflows
* build(sdk): include the command argument helper in package checks
* test(cli): account for the internal publication CSV in help coverage
* fix(cli): scope recovery hints to supported sessions and shells
* fix(cli): declare exclusive scan import sources in the schema
* fix(cli): resolve repository arguments consistently during scan discovery
* refactor(cli): simplify the result handoffs and verify PowerShell recovery
---------
Co-authored-by: Codex <noreply@openai.com>
* fix(cli): inspect integration commands before installation
* fix(cli): include the integration dispatcher in package validation
* fix(cli): list generated skills at the requested grouping depth
* docs(cli): clarify which installation skills list checks
* refactor(cli): share integration commands across dispatch and discovery
* fix(cli): complete integration flags without executing their commands
* fix(cli): register MCP clients through the installed SDK dependency
* fix(cli): preserve shell completion words and cursor positions
* fix(cli): serve all shell completions before executable dispatch
---------
Co-authored-by: Codex <noreply@openai.com>
* fix(cli): update the active installation and migrate legacy options
* fix(cli): recognize local projects named lib during updates
* fix(cli): use supported pnpm workspace and Bun optional flags
* fix(cli): isolate self-updates from project configuration
* fix(cli): recognize global npm under nvm checkouts
* refactor(cli): simplify package manager update resolution
* refactor(cli): skip updater registration during inspection
* refactor(cli): share metadata flags with update notices
---------
Co-authored-by: Codex <noreply@openai.com>
* feat(cli): expose identifiers for saved scan follow-up
* test(sdk): exercise dedupe representatives in publication
* feat(cli): link interrupted scans and imported evidence to their next commands
* build(sdk): include the command argument helper in package checks
* fix(cli): scope recovery hints to supported sessions and shells
* refactor(cli): simplify the result handoffs and verify PowerShell recovery
* fix(scan): reduce setup and tool output in Standard scans
* fix(workbench): keep policy paths optional for scan lookups
* fix(sdk): retain the preflight callback before scan dispatch
* fix(workbench): only advertise scoped inventory for Standard scans
* docs(workbench): explain optional scope report failures
* fix(workbench): preserve the Deep Scan registration response
* test(workbench): use the current scan context request in the Deep Scan fixture
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* Stage validated custom ZIP plugins for Windows scans
* Support long Windows plugin ZIP staging paths
* Prefer shorter trusted paths for Windows ZIP scan plugins
* Keep Windows path-length and ZIP publication tests independently mergeable
* Cancel slow Windows scan-input parent lookup promptly
* Verify ZIP fixtures exercise their temporary-path spies
* test: accept either eligible Windows ZIP resume stage parent
* test(windows): allow the CI timeout for ZIP workspace reuse
* test: restore owned sticky parents before cleanup
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
Co-authored-by: Codex <codex@users.noreply.github.com>
* fix(scan): verify assumed-unchanged files for committed diffs
* test(workbench): read the index flag before asserting
* fix(workbench): isolate Git settings during private index refresh
* fix(runtime): honor literal POSIX executable override paths
* fix(runtime): retain the lookup origin of padded executable paths
* fix(runtime): keep bare executable overrides on their original lookup path
Deep Scan accepts --stop-after-no-new 1 and --max-discovery-runs 1, but
the completion summary then said "The last 1 review rounds" or "Reached
the limit of 1 review rounds". Use the singular when the count is one.
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* fix(plugin): fall back to system Python when a Linux UID has no home
* fix(sdk): discover system Python when a Linux UID has no home
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* fix(publish): explain when Cloud import is unavailable
`publish findings --to cloud` starts with the repository catalog. For a
ChatGPT account or deployment without Codex Security Cloud import, that
request returns 404 and the CLI printed only "Cloud import failed (HTTP
404). Not found", which does not say whether the repository, the file, or
the account was missing.
Keep the server's text and add the same explanation `publish scan` gives
for this case: Cloud import is not available for this account or
deployment. Other statuses and endpoints are unchanged.
* fix(publish): handle an empty catalog error response
* docs(imports): correct AWS Continuum and mktemp guidance
- Name the first AWS CLI v2 release with `aws continuum` (2.38.5); earlier
v2 releases reject the command.
- Say that validation results come with findings Continuum detects, while
findings submitted to Continuum can omit them.
- macOS `mktemp -d` ignores TMPDIR, so the advice to set TMPDIR did not
move report directories there. Suggest a template instead.
* docs(imports): honor temporary report paths and clarify validation evidence
* fix(imports): read Continuum weakness IDs from subCategory
Findings that AWS Continuum detects itself omit cweIds and name their
weakness only in subCategory, for example "CWE-89: Improper
Neutralization ...". The reader mapped weakness_ids from cweIds alone,
so every native Continuum code finding imported without a CWE.
Fall back to the leading CWE ID in subCategory when cweIds is absent.
Explicit cweIds still win, and the previous-release replay projection
keeps reading cweIds only.
* fix(imports): preserve Continuum replay and evidence admission
* fix(cli): point native sign-in hints at codex-security login
After starting browser sign-in, native Codex prints "On a remote or
headless machine? Use `codex login --device-auth` instead." Running that
command signs in to the regular Codex home, not the Codex Security
credential home, so the suggested recovery does not help.
For the sign-in commands that pass native output straight through
(login, login status and logout), forward native stderr through a small
streaming rewrite of `codex login` to `codex-security login`. Stdin and
stdout stay attached to the terminal, other output is unchanged, and only
a possible partial match is held back between chunks.
* fix(cli): forward login hints and reap interrupted sign-ins
* fix(auth): sign in with the credential storage set in Codex config
On macOS, a fresh `codex-security login` could not be used to publish to
Cloud. Scans write `cli_auth_credentials_store = "auto"` into the Codex
Security credential home, so native login saved the token in the system
keyring and removed auth.json, while Cloud publication reads file-backed
credentials only.
The documented fix, setting `cli_auth_credentials_store = "file"` in
Codex config.toml and signing in again, had no effect: `login` used
whatever the last scan wrote, and SDK scans ignored the user's Codex
config for sign-in settings (only skill commands mirrored it).
- Layer the user's Codex config sign-in settings
(cli_auth_credentials_store, forced_login_method,
forced_chatgpt_workspace_id) between the wrapper defaults and explicit
overrides in mergedCodexConfig, so scans, their runtime config and Deep
Scan workers use them. A Codex config that cannot be read or parsed
sets no preference here; the commands that use it still report why.
- Before `login` and `login status`, write the keys that config sets into
the credential home. Native argv is unchanged, so managed policy still
wins. Unset keys and `logout` leave the stored location alone.
- Make the Cloud sign-in error and CLI docs name the setting and command.
* fix(cli): exit interrupted login when stderr stops draining
* fix(auth): keep sign-in, credential cleanup, and Cloud publication consistent
* fix(sdk): cancel queued logins without aborting settled operations
* test(sdk): guard the budget cancellation wait after usage is recorded
---------
Co-authored-by: mldangelo <michael.l.dangelo@gmail.com>
* fix(scans): archive long POSIX output directory names
* fix(logs): recover bound sessions from short scan archives
* fix(package): include the scan archive path helper in the release contract
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* fix(windows): resume Deep Scans before the first checkpoint
* fix(windows): retain the resume directory handle through registration
* fix(windows): finish Deep output registration after cancellation
* fix(windows): retain registration control across plugin entrypoints
* fix(windows): read Deep resume identities from pinned handles
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* Invoke the selected Windows policy helper without re-expanding paths
* Keep the reviewed Windows policy workflow available to custom validation
* Keep PowerShell native preferences local to the policy command
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* fix(bulk-scan): preserve occupied and replaced checkouts
* fix(bulk-scan): verify checkout ownership on every cleanup
* fix(bulk-scan): explain recovery without moving local work
---------
Co-authored-by: Codex <codex@users.noreply.github.com>
* Retry custom plugin ZIP publication on Windows
* fix(sdk): declare the Windows rename helper for source consumers
Strict eval builds type-check the SDK source without JavaScript inference. Pair the shared helper with its source declaration and include its JavaScript explicitly so clean SDK builds still emit the implementation, declarations, and maps.
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* test(sdk): resolve a usable Python interpreter for Windows workbench tests
* fix(package): include the plugin Python probe in the dist inventory
* test(sdk): prepare Windows Python outside individual test deadlines
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
fix(sdk): name the state directory in protected-root scan errors
When the Codex Security state directory resolves inside the scanned
directory or its enclosing Git worktree, preflight rejects it with
OutputInsideProtectedRootError but leaves pathKind at its "output"
default. The CLI then prints "Scan output directory must be outside ..."
and "Re-run with --output-dir <parent>/<root>-codex-security-scan".
Following that advice fails with the same message, because the output
directory was never the problem. This happens when $HOME is a Git
repository and the target is under it, when scanning ~ itself, or when
CODEX_HOME sits inside the workspace.
Tag the state-directory check with a "state" path kind, keep the check
that a state directory must not contain the scan root, and have the CLI
name the state directory and suggest setting CODEX_SECURITY_STATE_DIR
outside the protected root. Output, temporary, and runtime messages are
unchanged.
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Michael D'Angelo <mdangelo@openai.com>
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
* fix(sdk): read millisecond retry delays in rate limit reconnects
Rate limit messages from the API can give the wait in milliseconds, for
example "Please try again in 28ms." Codex accepts both s and ms units,
but the scan reconnect details only read seconds, so these delays were
dropped from onReconnect and the CLI retry message.
Read the ms unit and convert it to seconds.
* fix(sdk): retain millisecond retry hints through the one-hour limit
---------
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>
fix: keep scan history rendering total over workbench payloads
runWorkbench only checks that the workbench response parsed as a JSON
object, so nothing validates the shape between the Python workbench and
the history renderer. The renderer then cast fields unconditionally, so a
plugin or database that drifted from the expected shape surfaced as an
unhandled TypeError with a stack trace instead of a usable view.
Confirmed crashes: a finding whose `severity` is absent or null threw on
`severity.level`; a `scans` row without `progress` threw on
`progress.status`; a `knownSince` that is not a parsable timestamp threw
RangeError out of Intl.DateTimeFormat.
Read every field through small optional accessors instead. Missing data
now renders as empty or `UNKNOWN`, an unparsable `knownSince` falls back
to its raw value, and an unrecognized severity sorts below the known
levels rather than above CRITICAL, where indexOf's -1 had placed it.
Output for well-formed payloads is unchanged; the existing renderer tests
assert exact text and pass unmodified.
Co-authored-by: mldangelo-oai <mdangelo@openai.com>
Co-authored-by: mldangelo-oai <269034524+mldangelo-oai@users.noreply.github.com>