2026-11-26 15:51 UTC

Report: Claude Code queries GitHub token at startup

state: expiredheat: mediumuncertainty: mediumrelevance: mediumclaude-code github-token credential-securityAnthropic

What is this?

A Hacker News user reports that Claude Code runs `gh auth token --hostname github.com` at startup, causing repeated 1Password authorization prompts and exposing the token to the local CLI process. A web result points to an October 10, 2026 issue in Anthropic’s Claude Code GitHub repository requesting that the call be deferred until needed, documented, or made configurable. The supplied search result gives only a snippet, so it does not establish Anthropic’s response, the behavior’s scope, or why the token is queried. The HN author says a wrapper returning a fake token has not broken their use so far; that is one user’s experience, not confirmation of general behavior or impact.

Why it matters

A coding agent that reads a GitHub credential at every launch raises a meaningful least-privilege and user-consent concern, particularly for people using credential managers. The report does not show that the token leaves the machine, is misused, or is exposed to a model; the immediate reported consequence is repeated authorization prompts. If corroborated, deferring credential access until a GitHub-dependent feature needs it could reduce unnecessary credential access and friction.

Current assessment

New evidence beyond the HN post: a web search surfaces an issue in Anthropic’s Claude Code repository dated October 10, 2026, whose snippet asks that `gh auth token` not be called at startup, or be called only when a feature needs a GitHub token (example: a private marketplace), with documentation and an opt-out setting. This supports that the startup behavior has been raised in the project’s issue tracker, but the supplied result does not show issue details, status, an Anthropic explanation, or a fix. The HN report, dated November 5, 2026, says the command runs on every startup and returns a raw token; its author noticed repeated 1Password prompts and says a fake-token wrapper has not broken their use. Neither source establishes which Claude Code versions or configurations are affected, whether the token is used or transmitted, or the rationale. Track for an official response or release note and independent reproduction; do not characterize this evidence as a confirmed leak or exploitation.

Measured heat

no measured readings yet — the hourly heat pass fills this in

How the heat travelled

11-04 13:46⭐ origin directly observedTell HN: Claude Code queries raw GitHub token on startup
z0al on hacker news
—
11-04 13:46amplified on hacker news 👑hn.story.50365442
z0al
peak 6 · 2 comments · 101% of case engagement
11-04 14:23our radar first saw it · +0.6hdiscovery anchor: hn.story.50365442—

Evidence (1) — ⭐ canonical anchor

sourceobjectauthorscorecomments
🟧 hn ⭐Tell HN: Claude Code queries raw GitHub token on startupz0al62

Interpretation history

Decision trace