Check ID: codeartifact_packages_external_public_publishing_disabled
Provider: AWS
Service: codeartifact
Severity: CRITICAL
Categories: software-supply-chain, internet-exposed
Resource type: Other

What this check verifies

AWS CodeArtifact packages with an internal or unknown origin are evaluated for their package origin controls. The check identifies packages where the upstream setting allows ingesting versions from external or upstream repositories.

Risk

Allowing upstream on internal packages enables dependency confusion: public repos can supply higher versions to builds, leading to malicious code execution and package tampering. This threatens integrity, exposes secrets and data (confidentiality), and may disrupt pipelines and services (availability).

Recommendation

Enforce Package Origin Controls so internal packages use upstream=BLOCK and only trusted publish paths. Apply least privilege with package groups and private namespaces, pin versions, and prefer private endpoints. Add artifact signing and CI isolation, and monitor package events for unexpected source changes.

Remediation

aws codeartifact put-package-origin-configuration --domain <DOMAIN> --repository <REPOSITORY> --format <FORMAT> --package <PACKAGE_NAME> --restrictions publish=ALLOW,upstream=BLOCK

References

Where this check fires

This check runs on every scheduled scan against your AWS account. Findings appear at Cloud Security → Findings filterable by Check ID = codeartifact_packages_external_public_publishing_disabled. To re-evaluate after a fix, hit Run now on the account’s schedule under Cloud Security → Schedules — the next scan re-checks this control and marks the finding fixed or keeps it persistent.
← Back to AWS checks