CVE-2025-25204

CVE-2025-25204 is a medium-severity security vulnerability in github.com/cli/cli/v2 (go), affecting versions >= 2.49.0, < 2.67.0. It is fixed in 2.67.0.

Summary

A bug in GitHub's Artifact Attestation CLI tool, gh attestation verify, may return an incorrect zero exit status when no matching attestations are found for the specified --predicate-type <value> or the default https://slsa.dev/provenance/v1 if not specified. This issue only arises if an artifact has an attestation with a predicate type different from the one provided in the command. As a result, users relying solely on these exit codes may mistakenly believe the attestation has been verified, despite the absence of an attestation with the specified predicate type and the tool printing a verification failure.

Users are advised to update gh to version v2.67.0 as soon as possible.

Initial report: https://github.com/cli/cli/issues/10418
Fix: https://github.com/cli/cli/pull/10421

Details

The gh attestation verify command fetches, loads, and attempts to verify attestations associated with a given artifact for a specified predicate type. If an attestation is found, but the predicate type does not match the one specified in the gh attestation verify command, the verification fails, but the program exits early.

Due to a re-used uninitialized error variable, when no matching attestations are found, the relevant function returns nil instead of an error, causing the program to exit with a status code of 0, which incorrectly suggests successful verification.

PoC

Run gh attestation verify with local attestations using the --bundle flag and specify a predicate type with --predicate-type that you know will not match any of the attestations the command will attempt to verify. Confirm that the command exits with a zero status code.

Impact

Users who rely exclusively on the exit status code of gh attestation verify may incorrectly verify an attestation when the attestation's predicate type does not match the specified predicate type in the command.

CVE-2025-25204 has a CVSS score of 6.3 (Medium). The vector is network-reachable, low privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (2.67.0); upgrading removes the vulnerable code path.

Affected versions

github.com/cli/cli/v2 (>= 2.49.0, < 2.67.0)

Security releases

github.com/cli/cli/v2 → 2.67.0 (go)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

See it in your environment

Remediation advice

Upgrade github.com/cli/cli/v2 to 2.67.0 or later to resolve this vulnerability.

Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.

Frequently Asked Questions

  1. What is CVE-2025-25204? CVE-2025-25204 is a medium-severity security vulnerability in github.com/cli/cli/v2 (go), affecting versions >= 2.49.0, < 2.67.0. It is fixed in 2.67.0.
  2. How severe is CVE-2025-25204? CVE-2025-25204 has a CVSS score of 6.3 (Medium). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which versions of github.com/cli/cli/v2 are affected by CVE-2025-25204? github.com/cli/cli/v2 (go) versions >= 2.49.0, < 2.67.0 is affected.
  4. Is there a fix for CVE-2025-25204? Yes. CVE-2025-25204 is fixed in 2.67.0. Upgrade to this version or later.
  5. Is CVE-2025-25204 exploitable, and should I be worried? Whether CVE-2025-25204 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether CVE-2025-25204 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix CVE-2025-25204? Upgrade github.com/cli/cli/v2 to 2.67.0 or later.

Other vulnerabilities in github.com/cli/cli/v2

CVE-2026-45803CVE-2025-25204CVE-2024-54132CVE-2024-53858CVE-2024-52308

Stop the waste.
Protect your environment with Kodem.