Skip to main content
The github canary adds a fake GitHub Enterprise host to ~/.config/gh/hosts.yml. When the gh CLI is used with this host, it redirects API calls to Snare.

What gets planted

~/.config/gh/hosts.yml

Reliability: Medium

Fires when the gh CLI explicitly targets the fake host (gh api --hostname git.agent-01-internal.io). An agent that extracts the OAuth token and calls api.github.com directly won’t trigger it.