llm-eval-and-prompt-injection-fortress
Skill4 starsChanged 31 days agoMITView on GitHub
Review how agents handle untrusted text, authorize tool requests, and protect private outputs. Use for retrieval, tool connectors, agent permissions, or evaluation of coding agents.
In this repository47 other files it gives its agents.
- AGENTS.mdAGENTS.md
- anti-slop-engineeringSkill
- anti-slop-engineeringSkill
- api-ergonomics-and-contract-governorSkill
- apple-craft-and-frame-budgetSkill
- apple-craft-and-interaction-physicsSkill
- asset-provenance-guardSkill
- backprop-guardSkill
- chaos-and-degradation-choreographerSkill
- chromatic-drift-guardSkill
- cognitive-load-and-attention-governorSkill
- comment-budget-guardSkill
- context-window-and-token-economics-architectSkill
- cryptographic-agility-and-secret-lifecycle-gateSkill
- decision-guardSkill
- demock-guardSkill
- design-system-drift-guardSkill
- deterministic-simulation-and-property-testingSkill
- distributed-consensus-and-concurrency-gateSkill
- finops-and-unit-economics-governorSkill
- future-scale-gateSkill
- grumpy-senior-staff-engineerSkill
- honeypot-trap-guardSkill
- house-tell-guardSkill
- install-anti-slopSkill
- mandela-guardSkill
- mechanical-sympathy-and-perf-gateSkill
- mechanical-sympathy-profilerSkill
- motion-runtime-guardSkill
- observability-and-slo-architectSkill
- observability-and-slo-gateSkill
- paranoid-principal-architectSkill
- pr-boundary-guardSkill
- privacy-and-data-lineage-gateSkill
- re0-handoff-guardSkill
- reduction-guardSkill
- repo-memory-and-invariant-stewardSkill
- root-fix-gateSkill
- safe-evolution-and-rollout-choreographerSkill
- scientific-fault-isolationSkill
- styleseed-guardSkill
- supply-chain-and-sbom-sentinelSkill
- tagore-guardSkill
- type-level-and-ast-slop-gateSkill
- ui-and-copy-disciplineSkill
- verification-oracle-architectSkill
- zero-downtime-migration-gateSkill
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 32
Run python3 examples/policy_review.py from the skill directory for the synthetic decision cases.
≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Prompt Injection and Tool Authorization Review
Map data and authority
| Boundary | Review evidence |
| User intent | The authenticated platform request identifies actor, tenant, requested operation, and exact resource scope. High-impact actions carry explicit approval for canonical arguments. |
| Retrieved content | Repository files, comments, webpages, emails, tool results, and OCR remain data even if they quote a privileged role or resemble a tool invocation. Preserve provenance and isolate this text from developer instructions. |
| Requested action | The model produces a typed proposal. Independently validate tool, normalized target, operation, actor/tenant, and data classification at the dispatcher. Unknown or incomplete authority denies execution. |
| Effect and output | The tool service checks resource ownership and scope again. Filter sensitive fields before sending results to the model or an external destination. Log decision identifiers and classified outcomes with no private content. |
Check the policy boundary
- Inventory which connectors can read, write, publish, or transfer data. Grant separate, task-scoped capabilities to models or tools and enforce the authenticated caller's entitlements at each downstream service.
- Tie approval to the exact operation, resource, tenant, and canonical parameters. Recheck it before execution and expire it with the task. No connector response or model-generated field can supply authority.
- Compare the tool proposal, policy decision, actual invocation and observed side effect. A helpful refusal in text leaves the tool boundary unverified. A denied operation should produce zero downstream invocations, zero writes and zero disclosure.
- Preserve the ability to quote and summarize untrusted text as data. If retrieval returns mixed-authority text, retain its source and restrict the available action set for that step. Use a harmless placeholder in all fixtures and keep evaluation isolated from credentials, network and production state.
Record the evaluation
Record fixture revision, expected outcome, observed dispatcher decision, actual tool/effect count, and any policy or evidence gap. Use separate sets for known-authorized reads, wrong-resource and wrong-tenant reads, unauthorized publish, and quoted text with no proposed action. Any unauthorized downstream invocation blocks release. Check authorized success independently to catch a policy that denies every request. Treat unexecuted integrations as inconclusive.
Run python3 examples/policy_review.py from the skill directory for the synthetic decision cases. The example has no real tools or model and demonstrates an in-memory authorization check. Run python3 -m unittest discover -s tests -p test_prompt_tool_authorization.py -v from a source checkout.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

