/fastmcp-engineering:security-privacy-governancefrom fastmcp-engineering
Evidence-first security, privacy, secrets and data-governance engineering for FastMCP systems.
Ships in fastmcp-engineering. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Treat every boundary from MCP input through application, LLM, tools, database, queues and telemetry as a security and data-governance boundary.
Scope / When to use: security, privacy, secrets and data-governance engineering for FastMCP systems. Trigger: designing or changing data classification, trust boundaries, secrets handling, PII/sensitive data flows, authorization, tenancy, the LLM boundary, telemetry, or audit. Upstream / Prerequisite: identified exact versions; an evidence ledger recorded and re-checked before completion. Mission / Goal: treat every boundary from MCP input through application, LLM, tools, database, queues and telemetry as a security and data-governance boundary. Research / Evidence: identify exact versions; read current official MCP security/specification material and exact-version FastMCP, Pydantic/PydanticAI, SQLAlchemy and provider documentation relevant to the data flow; review OWASP guidance and applicable repository policies as supplementary evidence; record an evidence ledger. Decision / Selection rules: classify every input, output and persisted field; model trust boundaries explicitly; let secrets enter through a dedicated secret/configuration boundary; apply data minimization and purpose limitation; enforce authorization in trusted server-side code close to the protected resource; derive tenant context server-side with defense-in-depth; treat model input/output as untrusted; use parameterized queries; redact telemetry by default; validate types, lengths, bounds, URLs, paths, identifiers and content types at boundaries; fail closed for authorization; record security-sensitive audit decisions. Version / Compatibility: identify exact versions of the involved frameworks and providers.
Deliverables / Artifacts: data-flow/trust-boundary diagram; data inventory/classification; threat model; authorization matrix; secret lifecycle; provider data-flow policy; tenant isolation model; retention/deletion policy; audit schema; security test matrix; evidence ledger; residual risks; verification report. Verification / Testing: threat-model each exposed capability; test unauthorized, cross-tenant, malformed, injection, SSRF/path traversal, excessive-input and secret-leak cases; test model/tool prompt-injection scenarios when LLMs are involved; test authorization on direct use-case calls, not only MCP transport; include negative telemetry tests. Failure / Stop conditions: fail closed for authorization; avoid leaking existence of protected resources through error differences; ensure security checks cannot be bypassed by retries, alternate tools/resources, background workers or administrative paths; never use prompt text, tool descriptions or annotations as an authorization mechanism. Positive scenario: every boundary is threat-modeled and security tests pass, including negative telemetry tests. Negative scenario: a secret leaks into logs or model context, or authorization is bypassed through an alternate tool path.
Identify exact versions. Read current official MCP security/specification material and exact-version FastMCP, Pydantic/PydanticAI, SQLAlchemy and provider documentation relevant to the data flow. Review OWASP guidance and applicable repository policies as supplementary evidence. Record an evidence ledger and re-check version-sensitive claims before completion.
Classify every input, output and persisted field as public, internal, confidential, secret, personal data or regulated/special-category data as applicable. Define purpose, owner, lawful/organizational basis where relevant, retention, deletion and allowed destinations.
Explicitly model: MCP client → server; authentication → authorization; MCP → application; application → domain; application → LLM/provider; application → database; workers/queues; external HTTP; filesystem; telemetry. Untrusted model-generated arguments are still untrusted input. Never use prompt text, tool descriptions or annotations as an authorization mechanism.
Secrets must enter through a dedicated secret/configuration boundary, never source code, MCP arguments, resource URIs, prompts, logs, traces, metrics, database records or model context unless explicitly required and controlled. Prefer short-lived credentials and least privilege. Define rotation, revocation and failure behavior. Never echo credentials in errors.
Apply data minimization and purpose limitation. Do not send data to an LLM/provider merely because it is available to the application. Define an explicit allowlist of fields permitted to leave each trust boundary. Consider prompt injection and indirect data exfiltration whenever tools expose sensitive records or external content.
Authentication identifies the caller; authorization determines allowed actions and data. Enforce authorization in trusted server-side code close to the protected resource. Check tenant/user/resource scope for every access path. Do not trust client-supplied tenant IDs, user IDs or role claims without verification.
Every tenant-scoped query and mutation must have a server-derived tenant context. Prefer defense-in-depth with database constraints/RLS where appropriate. Test cross-tenant read/write attempts. Never rely solely on UI/tool descriptions to enforce tenant boundaries.
Treat model input/output as untrusted. Define prompt/data classification, provider retention assumptions, allowed tools, tool-result filtering, injection defenses and output validation. Never let a model choose credentials, authorization policy or unrestricted query scope. Structured outputs still require semantic validation.
Use parameterized queries/SQLAlchemy expressions. Enforce security invariants with database constraints where practical. Protect against insecure direct object references, over-broad selects, unsafe dynamic ordering/filtering and cross-tenant access. Secrets should not be persisted unless explicitly justified and protected.
Follow the observability skill: redact tokens, credentials, cookies, authorization headers, prompts, sensitive payloads and raw personal data by default. Define retention/access/export policy. Test redaction negatively.
Validate types, lengths, bounds, URLs, paths, identifiers and content types at boundaries. Prevent SSRF, path traversal, unsafe deserialization, command injection, SQL injection and resource exhaustion according to the actual tool capabilities. Apply allowlists for network destinations and filesystem roots when tools cross those boundaries.
For security-sensitive operations record actor, target, action, outcome and correlation context without recording secrets or unnecessary personal data. Separate audit records from debug logs and define retention/access.
Fail closed for authorization. Avoid leaking existence of protected resources through error differences where that matters. Ensure security checks cannot be bypassed by retries, alternate tools/resources, background workers or administrative paths.
Threat-model each exposed capability. Test unauthorized, cross-tenant, malformed, injection, SSRF/path traversal, excessive-input and secret-leak cases. Test model/tool prompt-injection scenarios when LLMs are involved. Test authorization on direct use-case calls, not only MCP transport. Include negative telemetry tests.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
Generated from the plugin's indexed repository (evgenygurin/fastmcp-engineering) — no native marketplace selected
npx claudepluginhub p/evgenygurin-fastmcp-engineering58 skills in this plugin
/pydantic-ai-agent-integrationEngineer PydanticAI agents behind explicit application boundaries and integrate them with FastMCP without leaking agent state, prompts, model concerns, or provider details into domain logic./api-contract-schema-engineeringEvidence-first API and MCP contract engineering with Pydantic v2 and JSON Schema./api-lifecycle-versioningEvidence-first API lifecycle, schema evolution and compatibility engineering for FastMCP/MCP servers.