Read the docs
TI-2024-36051 Aliases CVE-2024-53858GHSA-jwcm-9g39-pmcw

Recursive repository cloning can leak authentication tokens to non-GitHub submodule hosts in the gh cli

Priority LOW 31CWE-200Published · Updated

Key facts

Attack vector
Local
Privileges required
None
User interaction
Required
Attack complexity
High
Impact type
Information disclosure
Confidentiality · integrity · availability
High · High · Low
Fix status
Fixed

Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-200.

Summary

The gh cli is GitHub’s official command line tool. A security vulnerability has been identified in the GitHub CLI that could leak authentication tokens when cloning repositories containing `git` submodules hosted outside of GitHub.com and ghe.com. This vulnerability stems from several `gh` commands used to clone a repository with submodules from a non-GitHub host including `gh repo clone`, `gh repo fork`, and `gh pr checkout`. These GitHub CLI commands invoke git with instructions to retrieve authentication tokens using the `credential.helper` configuration variable for any host encountered. Prior to version `2.63.0`, hosts other than GitHub.com and ghe.com are treated as GitHub Enterprise Server hosts and have tokens sourced from the following environment variables before falling back to host-specific tokens stored within system-specific secured storage: 1. `GITHUB_ENTERPRISE_TOKEN`, 2. `GH_ENTERPRISE_TOKEN` and 3. `GITHUB_TOKEN` when the `CODESPACES` environment variable is set. The result being `git` sending authentication tokens when cloning submodules. In version `2.63.0`, these GitHub CLI commands will limit the hosts for which `gh` acts as a credential helper to source authentication tokens. Additionally, `GITHUB_TOKEN` will only be used for GitHub.com and ghe.com. Users are advised to upgrade. Additionally users are advised to revoke authentication tokens used with the GitHub CLI and to review their personal security log and any relevant audit logs for actions associated with their account or enterprise

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.00279 20th percentileScored 2026-11-07
Fix Fixed cli (cli): 2.63.0github.com/cli/cli/v2 (Go): 2.63.0

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
No
Technical impact
Total

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
cliclibefore 2.63.02.63.0Patch availableCNA
—github.com/cli/cli/v2 (Go)before 2.63.02.63.0Patch availableGHSA-jwcm-9g39-pmcw
  • cli Vendorcli Affected before 2.63.0 Fixed in 2.63.0 Patch available CNA
  • github.com/cli/cli/v2 (Go) Vendor— Affected before 2.63.0 Fixed in 2.63.0 Patch available GHSA-jwcm-9g39-pmcw

CPE names CISA-ADP · 1

CPEVersionsRoleVendor
cpe:2.3:a:github:cli:-:*:*:*:*:*:*:*not specified by CISA-ADP—GitHub
  • cpe:2.3:a:github:cli:-:*:*:*:*:*:*:* Versions not specified by CISA-ADP — ·GitHub

Remediation

  • Fix · CNA cli (cli) Fixed in 2.63.0
  • Fix · GHSA-jwcm-9g39-pmcw github.com/cli/cli/v2 (Go) Fixed in 2.63.0 Advisory →

Vendor assessments

Red Hat

Red Hat's page for this CVE →

Not affected: 1 product
  • Red Hat

Timeline

  1. 2026-10-02 Threatist record created from CVE-2024-53858
  2. 2026-10-03 Alias added: GHSA-jwcm-9g39-pmcw

References

  • TI-2025-18873 `gh attestation verify` returns incorrect exit code during verification if no attestations are present CVSS 3.1MEDIUM 6.3
  • TI-2026-33538 gh: GitHub Actions log output in `gh run view` allows terminal escape sequence injection CVSS 3.1LOW 3.5
  • TI-2024-34983 Connecting to a malicious Codespaces via GH CLI could allow command execution on the user's computer CVSS 3.1CRITICAL 9.6
  • TI-2026-35862 GitHub CLI tokens leak via `gh attestation` commands CVSS 3.1CRITICAL 9.1
  • TI-2024-36052 go-gh `auth.TokenForHost` violates GitHub host security boundary within a codespace CVSS 3.1HIGH 7.5
  • TI-2024-36248 GitHub CLI allows downloading malicious GitHub Actions workflow artifact to result in path traversal vulnerability CVSS 4.0MEDIUM 6.3
See all 13 →

Sources