Exceptions
An exception accepts a risk for a limited time: a vulnerability you cannot fix yet, a licence finding on an internal tool, a secret in a test fixture. It works the same way for every kind of finding (dependencies, container images, SAST, licences, secrets, malware in dependencies, registry packages) and for package-policy exceptions.
An exception takes effect only when a second person approves it. Until then the finding stays open and the policy still applies.
A dismissal is an exception that needed no approval. Dismissals, including repo-wide and image-wide ones, are listed, read and revoked in the same place and through the same API as approved exceptions; see Exceptions without approval.
How an exception works
- Request. Anyone who can work with findings asks for one, with a justification and an expiry date. The date may be at most your organisation’s cap away (366 days unless you set a lower one).
- Approve or reject. An approver other than the requester decides, with an optional comment. The approvers are emailed when a request arrives, in their own language.
- In force. The finding is dismissed until the expiry date. The finding
records who asked (
dismissed_by) and who approved (dismissal_approved_by). A rescan keeps the dismissal. - The end. On its expiry date the finding opens again, and the exception
is marked
expired.
The states are requested, approved, rejected, expired and revoked.
Who can approve
- By default: the organisation’s owners and the people on the package-policy approver list.
- Or, if you name an approver team in the settings: only the members of that team.
Nobody can approve their own request: the console shows them no Approve
button, and the API answers self-approve.
A token with no person behind it cannot decide an exception at all
(user-identity-required). By
default an AI agent’s credential cannot either. The one exception is the opt-in
agent approver, which can approve pending finding dismissals,
within its limits, and nothing else.
Automatic revocation
An approved exception is revoked, and its finding opened again at once, when:
| Trigger | Revocation reason |
|---|---|
| Someone revokes it by hand | manual |
| The finding’s severity rises above what was approved | severity_raised |
| A new vulnerability appears on the same component (same package and version, or same image package) | new_vulnerability |
| The approver leaves the organisation | approver_left |
| The exception relied on a not reachable verdict, and a later scan finds the finding reachable or cannot decide | reachability_changed |
The approver leaving is acted on when the membership change happens; the other
checks run every hour. reachability_changed also revokes a plain dismissal that
relied on a no-call-path verdict; see
Reachability.
Audit and SIEM
Every step is a tenant audit event:
code-security.exception.requested, .approved, .rejected, .revoked and
.expired for findings, and package_policy.exception.* for package policies.
A revocation event carries its reason and what changed. Like every audit event,
they reach your SIEM endpoints; filter on the action prefix
code-security.exception. to receive only these.
In the console
Open Security › Findings › Exceptions. The page has:
- Waiting for approval: the pending requests, each with Approve and Reject and a comment box. Your own requests show no Approve button.
- In force: approved exceptions, with Revoke.
- Accepted without approval: dismissals, repo-wide and image-wide ones included, with a type filter and Revoke. See Exceptions without approval.
- History: rejected, revoked and expired exceptions, with who decided, the comment and, for a revocation, why.
- Request an exception for a finding: on any finding’s page, the dismiss form has a Request an exception link that fills this in for you.
- Settings: the longest an exception may run, the approver team, Dismissals require approval with its severity threshold, and the agent approver.
API
Base URL https://frem.sh/_app/api/v1. See the API reference
for the full shapes.
| Method and path | Scope | What it does |
|---|---|---|
GET /orgs/{org}/exceptions | findings:read | Every approved-by-a-second-person exception, newest first. Filter with status (comma-separated), kind (finding or package) and scanner. Add approval=none for exceptions without approval, or approval=all for both. |
POST /orgs/{org}/exceptions | findings:write | Request one. For a finding: scanner, finding_id, justification, expires_at. For a package policy: "kind": "package" and the package-policy exception fields. |
GET /orgs/{org}/exceptions/{id} | findings:read | One exception, approved or not. |
POST /orgs/{org}/exceptions/{id}/approve | findings:write | Approve, with an optional {"comment": "..."}. |
POST /orgs/{org}/exceptions/{id}/reject | findings:write | Reject, with an optional comment. |
POST /orgs/{org}/exceptions/{id}/revoke | findings:write | Withdraw a request, or revoke an exception. A repo-wide or image-wide one needs policy:write. |
GET, PUT /orgs/{org}/exceptions/settings | policy:read, policy:write | max_days (1 to 366), approver_team (a team name, or null for owners plus the approver list), dismissals_require_approval (true or false) and dismissal_approval_min_severity (low, medium, high, critical, or null for every severity; see Severity threshold). Read-only: recommended_min_severity, weaker_than_recommended, weaker_reasons and dismissal_approval_disabled_at. |
GET /orgs/{org}/exceptions/agent-approver | policy:read | The agent approver: on or off, on whose behalf, its limits and when it lapses. |
DELETE /orgs/{org}/exceptions/agent-approver | policy:write | Turn the agent approver off and revoke its credential. Turning it on is possible in the console only. |
PUT /orgs/{org}/exceptions/agent-approver/same-person | policy:write | {"enabled": false} stops the agent approving dismissals made by the owner it acts for. true needs the console. |
POST /orgs/{org}/exceptions/{id}/agent-approve | findings:approve-dismissal | The agent approver’s approval of a pending finding dismissal, with reason and evidence. No other token can call it. |
scanner is one of deps, images, sast, licenses, secrets,
package_malware and packages; finding_id is the id the findings
endpoints return. expires_at is a date (YYYY-MM-DD, through that day UTC)
or an ISO 8601 time. A second request for a finding that already has a pending
or approved exception answers 409 duplicate-pending.
Request an exception for a dependency finding:
curl -sS -X POST https://frem.sh/_app/api/v1/orgs/acme/exceptions \
-H "Authorization: Bearer $FREMFORGE_TOKEN" -H 'Content-Type: application/json' \
-d '{"scanner":"deps","finding_id":"<id>","justification":"Not reachable from user input; fixed by the framework upgrade.","expires_at":"2026-12-31"}'A licence exception for the package policy:
curl -sS -X POST https://frem.sh/_app/api/v1/orgs/acme/exceptions \
-H "Authorization: Bearer $FREMFORGE_TOKEN" -H 'Content-Type: application/json' \
-d '{"kind":"package","scope":"package","rule_kind":"licence","rule_selector":"GPL-3.0-only","pkg_type":"npm","name":"left-pad","justification":"Internal tool, never distributed.","expires_at":"2026-12-31"}'Settings as code
PUT /orgs/{org}/exceptions/settings is a plain idempotent write, so the cap
and the approver team can live in your configuration repository next to the
rest of your organisation settings:
curl -sS -X PUT https://frem.sh/_app/api/v1/orgs/acme/exceptions/settings \
-H "Authorization: Bearer $FREMFORGE_TOKEN" -H 'Content-Type: application/json' \
-d '{"max_days": 90, "approver_team": "security"}'Exceptions without approval
The dismiss button on a finding is the one-person way to accept it. It records who dismissed and why, and can carry an expiry date. It has no second person, so it is an exception without approval. Use an approved exception when you need four eyes, or switch on Dismissals require approval to make every dismissal by someone who is not an approver go through one.
There are three kinds, each listed under Accepted without approval in the
console and by GET /orgs/{org}/exceptions?approval=none:
| Kind | scope | id | What it covers |
|---|---|---|---|
| Dismissal | finding | dismissal.<scanner>.<hash> | One finding. The id stays the same across rescans. findings_count says how many scan results it covers now, for example the same finding on several pull requests. |
| Repo-wide dependency dismissal | repo | repo.<uuid> | One advisory in one package and manifest, in every later scan of the repository. |
| Image-wide dismissal | image | image.<uuid> | One container-image finding in every later scan of the image. |
Each entry has "approval": "none", "status": "approved" (in force) and the
same fields as any exception: justification is the dismissal’s reason,
requested_by who dismissed, and expires_at its expiry date or null. With
approval=all, approved exceptions carry "approval": "required". Without the
approval parameter the list is exactly what it was before.
A dismissal that has lapsed is not listed: the daily expiry job reopens its findings. Not listed either: findings an approved exception dismissed (the exception is the entry), findings that went away by themselves, and licence findings your licence allow list dismisses, which that list governs.
Revoke reopens the findings at once, and a high or critical one alerts
again. Revoking a repo-wide or image-wide one also deletes the decision, so
later scans stop carrying it; it needs policy:write, like
DELETE /orgs/{org}/code-security/deps/repo-dismissals/{id}. Every revoke is
audited: code-security.<scanner>.dismissal_revoked, or
code-security.deps.repo_dismissal_revoked and
code-security.images.repo_dismissal_revoked.
curl -sS "https://frem.sh/_app/api/v1/orgs/acme/exceptions?approval=none&scanner=deps" \
-H "Authorization: Bearer $FREMFORGE_TOKEN"
curl -sS -X POST "https://frem.sh/_app/api/v1/orgs/acme/exceptions/dismissal.deps.3f1c0a9e5b7d2c4e6f8a0b1c/revoke" \
-H "Authorization: Bearer $FREMFORGE_TOKEN"Dismissals require approval
A per-organisation setting, off by default. When it is on, a dismissal of a dependency, SAST, secret, container-image, licence or dependency-malware finding by someone who is not an approver dismisses nothing. Instead:
- each open finding gets an exception request, with the dismissal’s reason as the justification and its expiry date (your organisation’s cap when the dismissal had none);
- the finding stays open, and the approvers are emailed;
- an approver other than the person who dismissed approves or rejects it in the queue. Approval dismisses the finding with both names, exactly like any other exception. Nobody can approve their own dismissal.
A dismissal on a protected release branch
is an exception with the id branch.<finding id> and the scope branch. It
does not go through this queue yet: while this setting is on, only an approver
can dismiss on a release branch, and anyone else gets
403 approval-required.
Approvers still dismiss directly. In the console, a dismissal that went for
approval takes you to the exceptions queue with a notice. Over the API, every
dismiss and bulk-dismiss endpoint then answers 202 instead of 200:
{
"dismissed": false,
"status": "pending_approval",
"pending_count": 1,
"exceptions": [
{ "id": "<exception id>", "finding_id": "<finding id>", "status": "pending_approval", "expires_at": "2027-10-11T15:00:00.000Z" }
],
"skipped": []
}skipped lists findings that were not queued: not-found (not open, or not
yours) or duplicate-pending (it already has a pending or approved exception).
A single-finding dismissal answers 404 or 409 duplicate-pending for those
instead. An expiry date beyond your cap is refused with
400 invalid-expires-at.
A malware finding on an uploaded file (Security › Findings › Malware
scanning) has no reason or expiry to put through the queue. While the setting
is on, only an approver can dismiss one; anyone else gets
403 not-an-approver.
Turn it on in Security › Findings › Exceptions › Settings, over the API:
curl -sS -X PUT https://frem.sh/_app/api/v1/orgs/acme/exceptions/settings \
-H "Authorization: Bearer $FREMFORGE_TOKEN" -H 'Content-Type: application/json' \
-d '{"dismissals_require_approval": true}'or with exception_settings in the
Terraform module. Switching it on or off
writes the audit events exceptions.dismissal_approval.enabled and
.disabled. A request made from a dismissal is the ordinary
code-security.exception.requested event with "via": "dismissal". Requests
already waiting stay in the queue when you switch it off, and can still be
approved.
Severity threshold
With Dismissals require approval on, dismissal_approval_min_severity decides
which dismissals go to approval: a finding at or above it waits for an approver,
one below it is dismissed directly. The default, null, sends every severity.
The recommended setting (recommended_min_severity) is on, with high; it is
not the default. weaker_than_recommended is true while the switch is off or
the threshold is critical, and dismissal_approval_disabled_at says when the
switch was last turned off after being on.
- SAST
error,warningandinfocount as high, medium and low. - A finding without a comparable severity (secrets, licences, malware, dependency health, unknown) always goes to approval.
- A bulk dismissal is judged per finding. A mix answers
200with the dismissed part and apending_approvalmember for the rest; if every finding needs approval, the answer is the202above. - Malware on an uploaded file and dismissals on a release branch still need an approver, whatever the threshold.
- A finding dismissed directly below the threshold is opened again by the
hourly check if a later scan raises it to or above the threshold (revocation
reason
severity_raised). Dismiss it again, and it goes to approval.
curl -sS -X PUT https://frem.sh/_app/api/v1/orgs/acme/exceptions/settings \
-H "Authorization: Bearer $FREMFORGE_TOKEN" -H 'Content-Type: application/json' \
-d '{"dismissals_require_approval": true, "dismissal_approval_min_severity": "high"}'A change that lets more dismissals through without an approver (switching it
off, or raising the threshold) needs a fresh check with a passkey or security
key. Any other value is refused with 400 invalid-severity.
Agent approver
Off by default. An owner who is an approver can let an AI agent approve pending
finding dismissals on their behalf, under Security › Findings › Exceptions ›
Agent approver. Those dismissals are then not reviewed by a second person,
and a warning on the exceptions page and on Security › Overview says so while
it is on. Turning it on needs a passkey, security key or authenticator code, and
shows a dedicated credential once, with the scope findings:approve-dismissal
and nothing else. The API cannot turn it on.
- Each approval needs a
reasonof at least 40 characters andevidence: the finding, its rule and path, and why it is a false positive or an accepted risk. The approval names the owner, and the exception records that an agent made it. - Never: a dismissal made with the agent’s own credential, a package-policy exception, or a dismissal made by the owner it acts for, unless an owner also switches on The same person, which needs a second factor too.
- Always left to a person (
202, the request stays pending): secrets validated as active, known-exploited vulnerabilities, findings an approver rejected before, and anything beyond 3 agent approvals an hour or 10 a day. - Guards: every owner gets a weekly email listing what the agent approved, and an email at once for each critical one. It turns itself off, and emails every owner, if the agent hits its limit twice within 24 hours, if a later scan reopens a finding it approved, or if it tries to approve a dismissal less than 60 seconds after it was made. It also turns off 90 days after an owner last confirmed it.
Turn it off in the console or with DELETE /orgs/{org}/exceptions/agent-approver
(policy:write); the credential is revoked at once.