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 skills add terrene-foundation/kailash-coc-claude-py --skill 18-security-patternsgit clone --depth 1 https://github.com/terrene-foundation/kailash-coc-claude-pyWrote 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/terrene-foundation/kailash-coc-claude-py/18-security-patterns)<a href="https://agentmods.dev/skills/terrene-foundation/kailash-coc-claude-py/18-security-patterns"><img src="https://agentmods.dev/badge/skills/terrene-foundation/kailash-coc-claude-py/18-security-patterns/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/terrene-foundation/kailash-coc-claude-py/18-security-patterns"><img src="https://agentmods.dev/badge/skills/terrene-foundation/kailash-coc-claude-py/18-security-patterns.svg" alt="Reviewed on agentmods" width="80" 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.1 | $0.00028 | $0.01281 |
| Opus 5 | $0.00014 | $0.00641 |
| Sonnet 5 | $0.00006 | $0.00256 |
| Haiku 4.5 | $0.00003 | $0.00128 |
Grade A, and why
security-patterns scanned grade A with 0 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 8d 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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 161 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Security Patterns - Kailash SDK
Mandatory security patterns for all Kailash SDK development. These patterns prevent common vulnerabilities and ensure secure application development.
Overview
Security patterns cover:
- Secret management (no hardcoded credentials)
- Input validation (prevent injection attacks)
- Authentication and authorization
- OWASP Top 10 prevention
- Secure API design
- Environment variable handling
Critical Rules
1. NEVER Hardcode Secrets
# ❌ WRONG - Hardcoded credentials
api_key = "sk-1234567890abcdef"
db_password = "mypassword123"
# ✅ CORRECT - Environment variables
import os
api_key = os.environ["API_KEY"]
db_password = os.environ["DATABASE_PASSWORD"]
2. Validate All User Inputs
# ❌ WRONG - No validation
def process_user_input(user_data):
return db.execute(f"SELECT * FROM users WHERE id = {user_data}")
# ✅ CORRECT - Parameterized queries (via DataFlow)
workflow.add_node("User_Read", "read_user", {
"id": validated_user_id # DataFlow handles parameterization
})
3. Use HTTPS for API Calls
# ❌ WRONG - HTTP in production
workflow.add_node("HTTPRequestNode", "api", {
"url": "http://api.example.com/data" # Insecure!
})
# ✅ CORRECT - HTTPS always
workflow.add_node("HTTPRequestNode", "api", {
"url": "https://api.example.com/data"
})
Reference Documentation
Each entry below is a depth file that ships alongside this skill. Regenerated
from the directory contents — the previous index listed eight security-*.md
files that exist nowhere in the corpus, so every lookup dead-ended.
Credentials & Secrets
- credential-decode-helpers - One shared userinfo decoder; null-byte rejection after percent-decoding
- credential-url-handling - Canonical connection-string credential pipeline (py)
Input Handling & Injection
- sanitizer-contract - Display hygiene: token-replace sentinels, type-confusion raises
- path-containment - Resolve and normalize both candidate and root before the trust decision
What ships with it
11 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- credential-decode-helpers.md 2.4 KB
- credential-url-handling.md 3.7 KB
- dataflow-rls-posture.md 6.5 KB
- docker-disclosure-scrub.md 8.0 KB
- frontmatter-directive-trust-surface.md 7.7 KB
- multi-site-kwarg-plumbing.md 1.9 KB
- path-containment.md 11 KB
- rls-security-definer-preauth-carveout.md 34 KB
- sanitizer-contract.md 2.8 KB
- secure-defaults-and-approver-identity.md 5.7 KB
- security-attack-chains.md 5.0 KB
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.
- 8d ago First seen · 161 lines · 28 tokens per session scan A afc0134cff58
security-patterns is a skill published in the GitHub repository terrene-foundation/kailash-coc-claude-py (12 stars, last pushed 24d ago), licensed Apache-2.0. It adds 28 tokens to every session and 1,281 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other skills, from other repositories
systematic-debugging
Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.
local-ai-agents
Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…
next-cache-components-adoption
Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…
chat-pet-sprite-creation
Use when creating or changing VS Code chat pet sprite art, sprite sheets, state animations, eye treatments, Stable/Insiders variants, or pet transitions under src/vs/workbench/contrib/chat/browser/widget/media/chatPet.
cpu-profile-analysis
Analyze V8/Chrome CPU profiles (.cpuprofile) and DevTools trace files (Trace-.json). Use when: profiling performance, investigating slow functions, comparing code paths, finding bottlenecks, analyzing timeToRequest, understanding call trees from sampling profiler data, analyzing layout/paint/rendering, investigating…
insight-error-page
Write or audit an insight-kind error page for the Next.js dev overlay. Use when creating a new errors/ .mdx page, auditing an existing one, or checking that a page matches the framework fix cards. Covers page structure, title alignment, FixCard cards with Copy prompt button, code snippets, terminology verification…