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
Evidence (1) — ⭐ canonical anchor
Interpretation history
2026-11-04T14:27:36Z
audience grounding: medium — 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.
Decision trace
- 11-19 02:20expireexpired deterministically: single-evidence seed quiet 14 days (lifecycle)
- 11-08 00:25review_screenThe comment speculates that the token is a convenience feature and repeats a personal observation about GitHub access limits; it adds no evidence about Claude Code’s startup behavior or its rationale.
- 11-08 00:25review_screenjev screen borderline (noul=0.34) — luna review
- 11-05 01:30attention_candidatecreate
- 11-05 01:27groundA 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
- 11-05 01:27createThe report describes a specific, testable credential-access behavior, but has no corroboration in the supplied evidence.