ChoiceSecurity signalsCommunity

Leaked secret response urgency

Decide how urgently to respond when an API key, token, password or private key shows up where it should not: confirm a false positive, note an already contained leak, plan a rotation, rotate immediately, or escalate to a security incident when there are signs of misuse.

F@f

Limits to keep in mind

Provider logs may be delayed, sampled or missing, so no visible use does not prove the secret was unused.

This label supports triage only; legal, contractual or regulatory notification duties are decided by the security and legal owners.

Never test whether a leaked secret works against production by using it; check validity through the provider console or API status.

Problem

Secret scanners, code reviews and coworkers regularly find credentials in commits, CI logs, chat messages, tickets and screenshots. Teams either treat every alert as a fire, burning hours on test fixtures and example keys, or they quietly delete the line and move on, leaving a live production key valid in git history, forks and logs. The right response depends on what the secret can do, where it was exposed, for how long and to whom, and whether anyone has already used it.

Goal

Label each finding so harmless placeholders and test keys are closed quickly, leaks that are already revoked are recorded, low-risk live secrets are rotated on a plan, live secrets with real reach are rotated immediately, any sign of misuse is escalated as a security incident, and a security owner decides when facts are missing.

Input / state

One exposed-secret finding with the facts needed to judge it: what kind of secret it is and what it can access, where it was exposed, how long and to whom it was visible, and what is known about its current state and use.

secret_and_scope
Type of secret (API key, token, password, private key, webhook secret), the service and environment, and what it can read, write, pay for or administer.
where_exposed
Where it was found: public or private repository, git history, CI log, container image, chat channel, ticket, screenshot or paste site.
exposure_window
How long it was visible and to whom: minutes or months, internal team, contractors, forks, the whole internet, and whether it was indexed or cloned.
current_state
Whether the secret is still valid, already revoked or expired, a placeholder or test value, and what access logs or billing show about recent use.

Decision question

ChoiceQuestion key leak_response

How urgently should the team respond to this exposed secret? First check for any sign of misuse in logs, billing or data; that means escalate_incident. Then check whether the value is a real credential at all and whether it is still valid. For live secrets, weigh what the secret can do, how public the exposure was and how long it lasted. Deleting the line or rewriting history never counts as containment; only revocation does. Use needs_review when validity, scope or exposure are unknown.

Options

  • escalate_incidentAccess logs, billing, alerts or data show unexpected use of the secret, or it grants admin, payment or customer-data access and was public long enough to be harvested; start the security incident process.
  • rotate_immediatelyA live secret with meaningful access was exposed publicly or to a wide audience, or a high-privilege secret was exposed anywhere; revoke and replace it now, then check logs.
  • rotate_plannedA live but low-privilege or short-lived secret was exposed briefly in a private, access-controlled place to people who already have similar access; rotate it within days and fix the cause.
  • already_containedThe secret was already revoked, expired or rotated before or right after the exposure, verified by the provider, and logs show no use during the exposure window.
  • false_positiveThe value is not a working credential: a documented example key, a placeholder, a test fixture for a local mock, a public identifier or a hash; close the alert and mark it in the scanner allowlist.

Allowed outcomes

Decided in your code from the answer and its confidence. Thresholds are yours to set and test.

  • Ask the security ownerValidity, scope, audience or use of the secret is unknown or disputed; the security owner investigates and decides.
  • Escalate as an incidentSigns of misuse or very high exposure; revoke at once, preserve logs, involve security and the service owner, and assess data and cost impact.
  • Rotate immediatelyLive secret with real reach; revoke and replace now, deploy the new value, review access logs for the exposure window and remove the leak source.
  • Rotate on a planLow-risk live secret; schedule rotation within a few days, move it to a secret manager and add a scanner or pre-commit check.
  • Already containedRevocation is verified and no use was seen; record the finding, clean up the leak source and close it.
  • Close as false positiveNot a real credential; close the alert, document why and allowlist the exact value or file to avoid repeat alerts.

Example scenarios

Predefined demonstrations. No model is called; the outcome shown is an illustrative judgment.

Example state

{
  "current_state": "Still valid; billing shows dozens of unknown GPU instances started yesterday",
  "where_exposed": "Committed to a public GitHub repository",
  "exposure_window": "Public for 3 days before the scanner alert",
  "secret_and_scope": "Cloud access key with permission to start compute instances in production"
}

Outcome

Illustrative
Escalate as an incident

Signs of misuse or very high exposure; revoke at once, preserve logs, involve security and the service owner, and assess data and cost impact.

Why

Clear misuse of a live, powerful key is a security incident.

Using it well

  • Assume a secret pushed to a public repository is compromised within minutes; bots scan public pushes continuously.
  • Removing the commit, editing the message or rewriting history does not contain a leak; forks, caches and clones keep it, so only revocation counts.
  • Judge by what the secret can do: admin, payment, production-write and customer-data access raise urgency even for short exposures.
  • A private repository or channel is not a secret store; count everyone with access, including contractors, integrations and backups.
  • Verify claims like already revoked or test key with the provider or the code, not with memory.
  • Check access logs and billing for the whole exposure window before closing any live-secret finding.
  • After any real leak, fix the cause: secret manager, environment injection, scanner in CI and a pre-commit hook.

Request definition

POST https://api.typesafe.ai/v1/systemone
{
  "model": "jev-latest",
  "state": {
    "secret_and_scope": "<secret_and_scope>",
    "where_exposed": "<where_exposed>",
    "exposure_window": "<exposure_window>",
    "current_state": "<current_state>"
  },
  "questions": {
    "leak_response": {
      "type": "choice",
      "instructions": "How urgently should the team respond to this exposed secret? First check for any sign of misuse in logs, billing or data; that means escalate_incident. Then check whether the value is a real credential at all and whether it is still valid. For live secrets, weigh what the secret can do, how public the exposure was and how long it lasted. Deleting the line or rewriting history never counts as containment; only revocation does. Use needs_review when validity, scope or exposure are unknown.",
      "criteria": {
        "escalate_incident": "Access logs, billing, alerts or data show unexpected use of the secret, or it grants admin, payment or customer-data access and was public long enough to be harvested; start the security incident process.",
        "rotate_immediately": "A live secret with meaningful access was exposed publicly or to a wide audience, or a high-privilege secret was exposed anywhere; revoke and replace it now, then check logs.",
        "rotate_planned": "A live but low-privilege or short-lived secret was exposed briefly in a private, access-controlled place to people who already have similar access; rotate it within days and fix the cause.",
        "already_contained": "The secret was already revoked, expired or rotated before or right after the exposure, verified by the provider, and logs show no use during the exposure window.",
        "false_positive": "The value is not a working credential: a documented example key, a placeholder, a test fixture for a local mock, a public identifier or a hash; close the alert and mark it in the scanner allowlist."
      }
    }
  }
}

Request shape from the System One API reference; a Kev server accepts the same body. Replace the placeholder state with your data. Requests need your own API key or server.

Version History

v1Current Versionabout 1 hour ago@f

Initial version

Comments (0)