Subscribe to the Non-Human & AI Identity Journal

Secrets Inventory

A secrets inventory is the structured record of where credentials exist, who owns them, and whether they are still valid. It is foundational to remediation because detection alone does not reduce risk unless teams can trace exposure, assign ownership, and revoke access quickly.

Expanded Definition

Secrets inventory is the operational catalog of credentials, tokens, API keys, certificates, and their ownership status across code, cloud, collaboration tools, and runtime systems. In NHI programs, it is the bridge between discovery and remediation, because a found secret is only useful when the organisation knows who owns it, where it is used, and whether it can be revoked safely.

Definitions vary across vendors, but the practical scope usually includes storage location, secret type, application binding, last-seen time, rotation date, and exposure status. The most mature implementations treat inventory as a living control plane, not a spreadsheet. That matters in environments with CI/CD automation, machine identities, and short-lived access paths, where stale secrets can be reintroduced by deployment pipelines or copied into incident workarounds. The OWASP Non-Human Identity Top 10 frames secret handling as a core identity risk, not just a hygiene issue.

The most common misapplication is treating secret scanning as the inventory itself, which occurs when teams record detections but fail to link each credential to an owner, system, and revocation path.

Examples and Use Cases

Implementing secrets inventory rigorously often introduces process overhead, requiring organisations to weigh faster remediation against the cost of continuously maintaining ownership and lifecycle data.

  • A platform team builds a central register of API keys, cloud access keys, and certificates so that a leak in one repository can be traced to the correct service owner within minutes.
  • A security operations team correlates secrets discovered in Slack, Jira, and Confluence with application inventories, because sensitive exposure now occurs outside source control as often as it does inside it, as shown in Guide to the Secret Sprawl Challenge.
  • A DevOps team maps each CI/CD credential to a pipeline stage so that a compromised build runner can be rotated without breaking unrelated deployments, a pattern echoed in the CI/CD pipeline exploitation case study.
  • A cloud security group classifies secrets by exposure and business criticality, then applies different handling for long-lived administrative keys versus ephemeral workload credentials, consistent with the risk focus in the Ultimate Guide to NHIs — Static vs Dynamic Secrets.
  • A supply chain team inventories secrets used by internal GitHub Actions after learning from the Reviewdog GitHub Action supply chain attack, where hidden credentials became an enterprise-wide problem.

These use cases show that inventory is not only about finding secrets, but about making them governable during normal operations and during incident response.

Why It Matters in NHI Security

Secrets inventory matters because NHI exposure is often invisible until a compromise forces the organisation to ask which credentials still exist and where they are valid. GitGuardian reports that 64% of valid secrets leaked in 2022 are still valid and exploitable today in The State of Secrets Sprawl 2026, which shows why detection without revocation leaves real risk on the table.

A strong inventory supports ZSP, PAM, and JIT by limiting standing access, proving ownership, and accelerating credential retirement after offboarding or exposure. It also becomes essential when investigating duplicated credentials, overused NHIs, or secrets that appear in non-code systems. The most difficult failures usually involve stale tokens, copied keys, or multiple apps sharing the same credential, because those patterns turn a single leak into a multi-system incident. Research from The 2025 State of NHIs and Secrets in Cybersecurity shows how often tokens remain active after role changes, which is why inventory has to be tied to lifecycle control, not just storage discovery.

Organisations typically encounter the true cost of poor secrets inventory only after a breach, when credential rotation, ownership disputes, and service outages make the gap operationally unavoidable to address.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Non-Human Identity Top 10 address the attack and risk surface, while NIST CSF 2.0 and NIST Zero Trust (SP 800-207) set the governance and control requirements practitioners need to meet.

Framework Control / Reference Relevance
OWASP Non-Human Identity Top 10 NHI-02 Covers improper secret management, including discovery, storage, and lifecycle control.
NIST CSF 2.0 PR.AA-01 Supports identity and access governance by tracking credential existence and validity.
NIST Zero Trust (SP 800-207) Zero Trust requires continuous verification, which depends on knowing all active credentials.

Inventory every secret, assign an owner, and require revocation paths for exposed or stale credentials.

Related resources from NHI Mgmt Group