DependencyTrack / DependencyTrack/dependency-track
API key lifecycle events and external secret manager integration
- Dominant language
- Java
- Stars
- 4.2k
- Forks
- 811
- Avg merge
- 8h 39m
- Merged PRs (30d)
- 237
Description
### Current Behavior
Dependency-Track API keys are commonly used by CI/CD pipelines, automation tools, and external systems to upload SBOMs or consume the REST API.
In enterprise environments, API keys usually need to comply with security policies such as:
- Secure storage in an approved secrets manager
- Avoiding manual copy/paste of secrets
- Periodic rotation
- Auditability of key creation and revocation
- Separation between human users and automation identities
- Avoiding exposure of API keys in pipeline variables, logs, or local files
Currently, when an API key is created, organizations must manually copy and store it in an external secret management solution. This process is error-prone and difficult to govern at scale.
There is no built-in lifecycle event or extensible mechanism to automatically publish newly generated API keys to external secret management systems such as AWS Secrets Manager, Azure Key Vault, HashiCorp Vault, Kubernetes Secrets, or similar platforms.
### Proposed Behavior
I would like to propose an enhancement to allow externally generated API keys to be imported and associated with a Dependency-Track team.
This proposal follows the feedback from the maintainers suggesting an inverted approach: instead of Dependency-Track pushing newly generated API keys to external secret managers, organizations could generate and store the key externally first, and then import it into Dependency-Track.
The intention of this issue is to validate the feasibility and expected design with the Dependency-Track maintainers before starting implementation. If this proposal is considered useful and aligned with the project direction, I would be willing to take ownership of the development.
## Proposed approach: Import externally managed API keys
Dependency-Track could expose an endpoint such as:
```http
POST /api/v1/team/{uuid}/key/import
Contributor guide
Assessment
This issue has not been assessed yet.