T01 · Skill Instruction Hijacking
- Location
AGENTS.md:99- Finding
Repository Instructions Direct Agents to Publish Code and Modify External Skill State
- Content
View full analysis
.npmrc npm publish rm .npmrc # Clean up — don't commit the token! ``` The `NPM_PUBLISH_TOKEN` env var is set in `~/.local/keys/env.sh`. ### 8. Update Local Moltbot Skill ```bash cp SKILL.md ~/moltbot/skills/slk/SKILL.md ``` ``` `CLAUDE.md:15-28`: ```markdown ## Adding a Feature 1. Add function in `src/commands.js` (export async) 2. If new API needs POST → add to `writeMethods` in `src/api.js` 3. Add case + alias in `bin/slk.js` switch block 4. Add to HELP string in `bin/slk.js` 5. Update `README.md` (commands table, examples, flags if any) 6. Update `SKILL.md` (commands list) 7. `npm version patch --no-git-tag-version` 8. `git add -A && git commit -m "feat: ..." && git push` 9. `echo "//registry.npmjs.org/:_authToken=${NPM_PUBLISH_TOKEN}" > .npmrc && npm publish && rm .npmrc` 10. `cp SKILL.md ~/moltbot/skills/slk/SKILL.md` ``` `CLAUDE.md:48-50`: ```markdown ## npm Publish Token `NPM_PUBLISH_TOKEN` env var from `~/.local/keys/env.sh`. Use `.npmrc` trick (create before publish, delete after). ``` ### Technical Analysis The repository-level agent instructions turn an ordinary local development task into a mandatory release workflow. They direct an AI coding agent to: - Commit all working-tree changes. - Push changes to a remote Git repository. - Retrieve or use a locally stored npm publication credential. - Publish the package to npm. - Copy `SKILL.md` into an external agent Skill directory. These operations are not necessary for implementing, testing, or auditing a local code change. In particular, package publication and ...[truncated 1700 chars]- Remediation
View remediation
