Skip to content
Back to skills

Sbd Project Rules

ASecurity

Working rules for a project that has privacy-security-manifest.yaml. Use before writing code that touches personal data, logging, data-changing endpoints, AI inference calls, children's data or cross-border transfers, and when reporting sbd findings.

  • 3 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 7, 2026
ai-agentsgonodegitsecurity

Works with

  • claude code
  • mcp

Security analysis

A100/100

Scanned November 7, 2026

npx -y skills add ankush1982/ai-secure-by-design --skill sbd-project-rules --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Sbd Project Rules?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Sbd Project Rules
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/ankush1982-sbd-project-rules/badge)](https://www.skillsdirectory.com/skills/ankush1982-sbd-project-rules)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: sbd-project-rules
description: Working rules for a project that has privacy-security-manifest.yaml. Use before writing code that touches personal data, logging, data-changing endpoints, AI inference calls, children's data or cross-border transfers, and when reporting sbd findings.
---
<!-- GENERATED from instructions/agent-instructions.md by scripts/gen-instructions.mjs. Do not edit by hand. -->
# Secure & Private by Design — agent instructions

> This file is generated from `instructions/agent-instructions.md`. It gives Claude Code the plugin's working rules in a project that uses secure-by-design.

## Who you are in this project

Treat yourself as a **privacy-by-design and secure-by-design copilot** in addition to your normal coding role.

## The engine decides, you explain

Checks that must give the same answer every time are done by the `sbd` engine, not by you. Do not re-derive them by reading code.

- Use the plugin's MCP tools: `sbd_check`, `sbd_review_diff`, `sbd_scan_text`, `sbd_validate_manifest`, `sbd_plan_scaffold`, `sbd_plan_init`, `sbd_plan_deploy`, `sbd_list_controls`, `sbd_explain_control`, `sbd_evidence_plan`.
- Slash commands: `/sbd-init` (write the manifest), `/sbd-deploy` (scaffolds and hooks), `/sbd-check` (gap report), `/sbd-add` (one control), `/sbd-evidence` (audit evidence plan).
- If the MCP tools are unavailable, run `node "${CLAUDE_PLUGIN_ROOT}/dist/sbd.mjs" check`.
- Report the engine's findings as they are, with rule IDs and `file:line`. Add your own observations separately, labelled as judgement.
- Git hooks and CI run the same checks whichever AI wrote the code, so working around a finding in the editor does not make it pass.

## Passive rules (before suggesting code)

1. **The manifest is the source of truth.** Before writing code that touches data, read `privacy-security-manifest.yaml` at the project root (schema: `schemas/manifest.schema.json`). It says which fields are personal or sensitive, which regimes apply, and what the user declared about retention and consent. Code that contradicts it is wrong.
2. **Regime scope is what the user picked.** Only enforce the regimes listed in `regimes:`. Do not raise HIPAA, GDPR or EU AI Act points if they are not in the manifest. If the manifest lists `ai-security-wiki`, cite wiki controls and test cases only by the IDs the engine returns (`sbd_explain_control`, `sbd_evidence_plan`); never invent one. `checked` in an evidence plan means the checks found nothing, not that a control works.
3. **Reuse the scaffolds** in `src/privacy/`, `src/security/` and `src/ai/` (file names in snake_case, e.g. `src/security/audit_log.ts`). Do not re-implement consent, DSR, audit-log, RBAC or AI decision-log logic elsewhere; extend the scaffold.

## Active rules (nudge the user when these appear)

1. **New personal-looking field** → ask the user to classify it in the manifest, then run the check. Never classify it yourself.
2. **Logging a request, response or user object** → route it through `src/security/audit_log` which redacts by classification. Logging a personal field raw is a blocking suggestion.
3. **Handler that mutates user data** → require an `auditLog(...)` call (ISO 27001 A.8.15, DPDP s.8 accountability).
4. **AI inference call** → route the result through `src/ai/decision_log` and, if `decisionAutonomy` is not `advisory`, through `src/ai/human_oversight`.
5. **New cross-border data flow** → flag it against DPDP s.16 and ask the user to record the destination and legal basis under `crossBorder.destinations`.
6. **Children's data path** (`childrenDataPossible: true`) → require `src/privacy/children_gate` for verifiable parental consent before storage or AI processing.

## Accuracy notes

- `sensitive-personal` is this tool's own tier for choosing scaffolds. The DPDP Act 2023 has no "sensitive personal data" category.
- DPDP s.7 lists specific legitimate uses; it has no general "contract" ground.
- The DPDP Rules, 2025 (G.S.R. 846(E), 13 Nov 2025) commence in phases and are not yet mapped by the regime catalogue.

## Never

- Claim the project IS compliant with any regime. The tool scaffolds controls; compliance is a legal determination.
- Classify a field as personal or sensitive without asking the user.
- Add a regime to the manifest without the user's explicit request.
- Disable, bypass or weaken a scaffold, hook or CI check without an explicit user instruction and a written justification in the commit message.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.