GitGuardian: nearly 3K of the 450K projects submitted to PyPI exposed at least one credential in code, like API keys, including some from “very large companies”
Many transgressions come from “very large companies that have robust security teams.”
Context & Ripple Effects
This report extends a long-running repository-security problem from source-code discovery to package publication: tools that comb public repositories for secrets showed how easily sensitive material can be found once it reaches a public code host.
PyPI has also been a distribution channel for compromised packages that sought developers’ cloud credentials, including the compromised ctx and phpass packages. The distinction matters: here, credentials appear to have been published by project maintainers rather than extracted by a malicious dependency.
First-order effects
- Organizations whose API keys or other credentials were included in affected PyPI code must identify whether the secrets remain valid and rotate or revoke them where necessary.
- PyPI users and maintainers face a more immediate need to inspect published source and release workflows for embedded credentials, including in projects associated with large companies.
Second-order effects
- Security teams are likely to move secret detection earlier into developer and package-release workflows, rather than relying on review after code has become public.
- Credential providers and organizations using their APIs may see more incident-response work around exposed machine identities, as public package code becomes another place keys must be monitored.
Third-order effects
- If this pattern persists, public package registries will increasingly be treated as identity-exposure surfaces, not merely software-distribution infrastructure.
- The durable shift is toward lifecycle controls for non-human credentials—detection, revocation, and replacement across repositories and release artifacts—though the report alone does not establish which controls PyPI will adopt.
The trend: Software supply-chain security is broadening from malicious dependencies to the management of credentials unintentionally shipped alongside legitimate code.