{"schema":"threatline.record/2","record":{"id":"CVE-2026-64655","aliases":["GHSA-mm27-mwq9-fr5g","GO-2026-6767"],"summary":"GitHub CLI allows attestation verification bypass through unescaped regex metacharacters","details":"### Summary\n\nA security vulnerability has been identified in GitHub CLI that could allow attestation verification bypass when using `gh attestation verify` with `--signer-repo` or `--signer-workflow` flags. GitHub CLI builds the certificate matcher from these flag values without escaping regex metacharacters, so a repository or workflow name is treated as a regular expression rather than a literal string. GitHub permits characters such as  `.`  in organization, repository, and workflow path names, and  `.`  is a regex wildcard, so a malicious actor can create a lookalike name that satisfies a matcher intended for a different, trusted signer.\n\n### Details\n\nGitHub CLI constructs a regular expression from the  `--signer-repo`  and  `--signer-workflow`  values and matches it against the signing certificate's SAN (Subject Alternative Name) during Sigstore attestation verification. The user-supplied value is interpolated into the pattern without escaping regex metacharacters, so any metacharacter permitted in a GitHub path is interpreted as regex syntax instead of a literal character.\n\nThe most practical case is  `.` , which GitHub allows in org/repo names and is a regex wildcard meaning \"any single character.\" For example, an attacker-controlled repository named:\n\n`github/artifact.attestations-workflows`\n\nmatches a verifier configured for the trusted signer:\n\n`github/artifact-attestations-workflows`\n\nbecause the unescaped  `.`  in the constructed pattern matches the  `-`  in the attacker's name (and any other single character at that position). This affected the `--signer-repo` and `--signer-workflow` flags but did not affect the `--repo` and `--owner` flags which include an exact string comparison.\n\nIn `v2.97.0`, the GitHub CLI escapes the user-supplied signer values before they are incorporated into the SAN matcher, so they are matched as literal strings.\n\n### Impact\n\nThe practical impact is limited, exploitation requires the attacker to create a plausible lookalike repository name and produce valid Sigstore attestations from it. This could undermine supply chain verification for CI/CD pipelines or policy gates that use these flags to pin trust to a specific signing workflow. \n\n### Remediation and Mitigation\n\n1. Upgrade `gh` to `v2.97.0` or later, which escapes signer values before matching.\n2. As a workaround, use `--repo` or `--owner` flags instead of `--signer-repo` or `--signer-workflow` where applicable.\n3. Manually inspect the signing certificate SAN in attestation output to confirm the signing workflow origin.","categories":["Libraries & packages"],"product":"github.com/cli/cli/v2","vendor":"cli","ecosystem":"go","affected_ranges":[{"source":"GitHub Advisory Database","source_url":"https://github.com/advisories/GHSA-mm27-mwq9-fr5g","source_modified_at":"2026-10-15T18:08:23Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"go","name":"github.com/cli/cli/v2"},"range":"< 2.97.0"},{"source":"CVE List","source_url":"https://www.cve.org/CVERecord?id=CVE-2026-64655","source_modified_at":"2026-08-08T02:23:17.134Z","fetched_at":"2026-10-23T18:45:31.882637Z","product":"cli","vendor":"cli","versions":[{"version":"< 2.97.0","status":"affected"}],"defaultStatus":null},{"source":"OSV","source_url":"https://osv.dev/vulnerability/GHSA-mm27-mwq9-fr5g","source_modified_at":"2026-10-19T21:41:04.715150068Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"Go","name":"github.com/cli/cli/v2","purl":"pkg:golang/github.com/cli/cli/v2"},"ranges":[{"events":[{"introduced":"0"},{"fixed":"2.97.0"}],"type":"SEMVER"}],"versions":[]}],"fixed_versions":[{"source":"GitHub Advisory Database","source_url":"https://github.com/advisories/GHSA-mm27-mwq9-fr5g","source_modified_at":"2026-10-15T18:08:23Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"go","name":"github.com/cli/cli/v2"},"version":"2.97.0"},{"source":"OSV","source_url":"https://osv.dev/vulnerability/GHSA-mm27-mwq9-fr5g","source_modified_at":"2026-10-19T21:41:04.715150068Z","fetched_at":"2026-10-23T18:42:43.628194Z","package":{"ecosystem":"Go","name":"github.com/cli/cli/v2","purl":"pkg:golang/github.com/cli/cli/v2"},"version":"2.97.0"}],"cvss":2.1,"severity":"Low","kev":{"listed":false},"epss":{"probability":0.00343,"percentile":0.26659,"score_date":"2026-10-23"},"published_at":"2026-08-06T18:41:54.628Z","modified_at":"2026-10-19T21:41:04.715150068Z","provenance":[{"source":"GitHub Advisory Database","url":"https://github.com/advisories/GHSA-mm27-mwq9-fr5g","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-15T18:08:23Z"},{"source":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-64655","fetched_at":"2026-10-23T18:45:31.882637Z","source_modified_at":"2026-08-08T02:23:17.134Z"},{"source":"OSV","url":"https://osv.dev/vulnerability/GHSA-mm27-mwq9-fr5g","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-19T21:41:04.715150068Z"},{"source":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-64655","fetched_at":"2026-10-23T18:42:43.628194Z","source_modified_at":"2026-10-23"}],"sources":["GitHub Advisory Database","CVE List","OSV","EPSS"],"references":[{"source":"CVE List","url":"https://github.com/cli/cli/security/advisories/GHSA-mm27-mwq9-fr5g","tags":["x_refsource_CONFIRM"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-64655","source":"GitHub Advisory Database"},{"source":"CVE List","url":"https://github.com/cli/cli/commit/55dbb4dc6b7edb10b48e3d7fc5bccd32318d1b55","tags":["x_refsource_MISC"]},{"source":"CVE List","url":"https://github.com/cli/cli/releases/tag/v2.97.0","tags":["x_refsource_MISC"]},{"url":"https://github.com/advisories/GHSA-mm27-mwq9-fr5g","source":"GitHub Advisory Database"}],"locations":[],"motoko_assessment":{"status":"requires_architecture_review","automatic_remediation":false},"cve_state":"PUBLISHED","ssvc":{"exploitation":"none","automatable":"yes","technical_impact":"partial","assessed_at":"2026-08-08T02:23:02.313002Z"},"classification":{"method":"product-first software-layer rules","rules_version":"2.1","matched_on":"ecosystem","confidence":"heuristic","reviewed":false},"change_timestamp":"2026-10-19T21:41:04.715150068Z","content_hash":"0e8e3277f1b39e41447cb08eaaa259174f27761542b7b32eecdf657c26a2bba7"}}
