CVE-2026-42576 Details
Description
apko allows users to build and publish OCI container images built from apk packages. Prior to version 1.2.7, DiscoverKeys in pkg/apk/apk/implementation.go unconditionally type-asserts JWKS keys as *rsa.PublicKey without checking the key type. If a repository JWKS endpoint returns a non-RSA key (e.g. EC), the unchecked assertion panics and crashes apko. This affects any workflow that initializes the APK database and fetches repository keys. This issue has been patched in version 1.2.7.
A denial-of-service vulnerability has been identified in Apko versions prior to 1.2.7. The issue arises in the 'DiscoverKeys' function, where JWKS keys are unconditionally type-asserted as RSA public keys without verifying the key type. This flaw can lead to a panic and crash the Apko process if a repository JWKS endpoint returns a non-RSA key, such as an EC key. The vulnerability impacts any workflow that initializes the APK database and retrieves repository keys.
Users can upgrade to Apko version 1.2.7 or later, where this vulnerability has been patched.
Metrics
CVSS 4.0 Severity and Vector Strings:
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
Volerion
Assessed May 9, 2026CISA-ADP
Assessed May 11, 2026References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://github.com/chainguard-dev/apko/commit/6604826b19e36e9bc6e196592800fad93738f4a1 | [email protected] | Source CodeVendor |
| https://github.com/chainguard-dev/apko/releases/tag/v1.2.7 | [email protected] | Release NotesVendor |
| https://github.com/chainguard-dev/apko/security/advisories/GHSA-m7hm-vm4x-28jf | [email protected] | AdvisoryRemedyVendor |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| CWE-704 | Incorrect Type Conversion or Cast | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| chainguard.dev/apko | All versions |
CPE
Remediation
| |
Change History
4 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jul 24, 2026 | CVE Translated | [email protected] |
| Jun 17, 2026 | CVE Modified | [email protected] |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| May 9, 2026 | New CVE Received | [email protected] |
Volerion