Skip to content

Threat model and secure design ​

Assets and trust boundaries ​

AssetWhereBoundary
Artifacts (packages, images)object storage, metadata in PostgreSQLclients reach them only through the HTTP API
Credentials (passwords, API tokens, SSO sessions)PostgreSQLhashed (argon2id) or sealed with AES-256-GCM under OPENARTIFACT_SECRET_KEY
Signing keys (GPG)PostgreSQL, sealednever returned by the API
Upstream proxiesoutbound HTTP(S)untrusted content; URLs validated, responses size-limited

Trust boundaries: internet to the server (TLS terminated by a reverse proxy or the server), server to PostgreSQL and object storage (trusted network), server to upstream registries and webhooks (untrusted).

Threats and mitigations ​

ThreatMitigation
Unauthorized read/write of packagesauthentication on every write path; RBAC per repository and project (rbac, projects)
Credential theft from the databaseargon2id password hashes, hashed API tokens, sealed secrets
Path traversal and malicious archive namespaths and archive entries validated before storage
SSRF through proxy repositories and webhooksdestination validation, redirect and size limits
Malicious or vulnerable packagesvulnerability scanning, license policy, quarantine (scanning)
Tampered releaseschecksums, keyless cosign signatures, build provenance (signing)
Vulnerable dependenciesDependabot, govulncheck, OSV and Trivy in CI and a scheduled scan
Compromised CIpinned action SHAs, minimal workflow permissions, zizmor and CodeQL

Secure design principles applied ​

Least privilege (minimal workflow and role permissions), fail closed on authorization errors, input validation at the HTTP boundary, defense in depth (RBAC plus audit log), economy of mechanism (a single binary with PostgreSQL and S3 storage), secure defaults, and reuse of vetted libraries instead of custom cryptography. Cryptography uses the Go standard library and golang.org/x/crypto (argon2); passwords are never stored reversibly, TLS verification is on by default, and random values come from crypto/rand.

Assurance argument ​

The security requirements above are verified by the automated test suite (including authorization tests per format), static analysis (golangci-lint, CodeQL), dependency and image scanning on every pull request, and the process in SECURITY.md for reports.

Free software under the AGPL-3.0-or-later.