Advisory Database
  • Advisories
  • Dependency Scanning
  1. golang
  2. ›
  3. chainguard.dev/apko
  4. ›
  5. CVE-2026-42576

CVE-2026-42576: apko `DiscoverKeys` has a panic on non-rsa jwks key that causes crash during key discovery

May 4, 2026

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. Affected versions <= 0.30.34.

Fix: No fix available yet.

Acknowledgements

apko thanks Oleh Konko from 1seal for discovering and reporting this issue.

References

  • github.com/advisories/GHSA-m7hm-vm4x-28jf
  • github.com/chainguard-dev/apko
  • github.com/chainguard-dev/apko/security/advisories/GHSA-m7hm-vm4x-28jf
  • nvd.nist.gov/vuln/detail/CVE-2026-42576

Code Behaviors & Features

Detect and mitigate CVE-2026-42576 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 1.2.7

Fixed versions

  • 1.2.7

Solution

Upgrade to version 1.2.7 or above.

Impact 6.5 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-704: Incorrect Type Conversion or Cast

Source file

go/chainguard.dev/apko/CVE-2026-42576.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sat, 09 May 2026 12:18:35 +0000.