Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/hezaohezao/poirot/github-authnpx skills add HezaoHezao/poirot --skill github-authgit clone --depth 1 https://github.com/HezaoHezao/poirotWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/hezaohezao/poirot/github-auth)<a href="https://agentmods.dev/skills/hezaohezao/poirot/github-auth"><img src="https://agentmods.dev/badge/skills/hezaohezao/poirot/github-auth.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00017 | $0.01056 |
| Opus 5 | $0.00009 | $0.00528 |
| Sonnet 5 | $0.00003 | $0.00211 |
| Haiku 4.5 | $0.00002 | $0.00106 |
Grade E, and why
github-auth scanned grade E with 3 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Reaches for credential fileshighPrivilege escalation
SSH keys, cloud credentials, git-credentials, .npmrc, /etc/shadow: reading these is how a config file becomes a credential leak.
ssh-keygen -t ed25519 -C "[email protected]" -f ~/.ssh/id_ed25519_github Downloads and executes remote codehighSupply chain
curl | sh runs whatever the server returns today, which is not necessarily what it returned when this was reviewed.
curl -s -H "Authorization: token $GITHUB_TOKEN" https://api.github.com/user | python3 -c "import sys,json; print(json.load(sys.stdin)['login'])" Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
curl -s -H "Authorization: token $GITHUB_TOKEN" https://api.github.com/user | python3 -c "import sys,json; print(json.load(sys.stdin)['login'])" How it starts
The opening of the file, as written. The whole thing — 150 lines — stays where its author put it; the contents beside it link to each section on GitHub.
GitHub Authentication Setup
Sets up authentication so the agent can work with GitHub repositories, PRs, issues, and CI.
Detection Flow
When a user asks to work with GitHub, run this check first:
git --version
gh --version 2>/dev/null || echo "gh not installed"
gh auth status 2>/dev/null || echo "gh not authenticated"
git config --global credential.helper 2>/dev/null || echo "no git credential helper"
Decision tree:
- If
gh auth statusshows authenticated → useghfor everything - If
ghinstalled but not authenticated → use "gh auth" method - If
ghnot installed → use "git-only" method
Method 1: Git-Only (No gh)
HTTPS with Personal Access Token (Recommended)
Step 1: Create a token at https://github.com/settings/tokens (classic)
or https://github.com/settings/personal-access-tokens (fine-grained). Scope:
repo, workflow, read:org.
Step 2: Configure git credential helper:
# Store credentials (plaintext, dev machine only)
git config --global credential.helper store
# Or use a credential cache (timed, more secure)
git config --global credential.helper 'cache --timeout=3600'
Step 3: First push triggers prompt:
# Username: your GitHub username
# Password: paste your token (not your GitHub password)
git push origin main
Step 4 (optional): Set token as env var for API calls:
export GITHUB_TOKEN="ghp_xxxxxxxxxxxx"
# Add to .env for persistence
SSH Keys
# Generate key (if no existing key)
ssh-keygen -t ed25519 -C "[email protected]" -f ~/.ssh/id_ed25519_github
# Start ssh-agent
eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_ed25519_github
# Copy public key
cat ~/.ssh/id_ed25519_github.pub
# Paste at https://github.com/settings/keys
# Test
ssh -T [email protected]
# Set remote to SSH
git remote set-url origin [email protected]:owner/repo.git
Method 2: gh CLI
# Install gh (if not present)
# macOS: brew install gh
# Linux: see https://github.com/cli/cli#installation
# Windows: winget install GitHub.cli
# Authenticate
gh auth login
# Follow prompts: choose HTTPS or SSH, authenticate via browser or token
# Verify
gh auth status
# Use gh for everything
gh repo clone owner/repo
gh pr create
gh issue list
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 150 lines · 17 tokens per session scan E 834a0a867e0c
github-auth is a skill published in the GitHub repository HezaoHezao/poirot (213 stars, last pushed 1mo ago), licensed MIT. It adds 17 tokens to every session and 1,056 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it E with 3 findings (reaches for credential files, downloads and executes remote code, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
commit
Atomic git commit with conventional message. Use when the user says "commit", "save my changes", "commit this", or wants to create a git commit. Stages specific files, writes a conventional commit message with body explaining non-obvious decisions. Never uses git add -A.
python-run
Run and debug Python scripts in the project. Use when the user says "run python", "execute this script", "debug this py file", or wants to run/modify a .py file. Handles dependency checks, linting, execution, and error analysis.
growmos
Use the repository's living knowledge graph (growmos, in .growmos/) as shared memory. Trigger when the user asks about how parts of the codebase relate, why a decision was made, who owns what, what depends on what; when you finish a meaningful piece of development and should record it; when growmos next reports…
StructuredMemoryManager
【每次新对话开始时必须首先调用】预加载用户偏好、习惯、历史决策等高优记忆,确保回复符合用户要求。也用于记录新偏好/习惯、保存任务总结、存储项目决策。.
growmos
Use the repository's living knowledge graph (growmos, in .growmos/) as shared memory. Trigger when the user asks about how parts of the codebase relate, why a decision was made, who owns what, what depends on what; when you finish a meaningful piece of development and should record it; when growmos next reports…
data_analysis
基于已确认数据执行可审计的数学计算和描述统计。.