plugins/ruflo-aidefence/docs/adrs/0001-aidefence-contract.md
ruflo-aidefence documents the AIDefence MCP family (aidefence_scan, _analyze, _stats, _learn, _is_safe, _has_pii) — 6 tools at v3/@claude-flow/cli/src/mcp-tools/security-tools.ts:108, 191, 277, 329, 424, 479. Plugin is at v0.2.0 with full surface coverage and a "Defence-in-depth pairing" block already documenting the host-level hardening (loader-hijack denylist, file mode 0600, encryption-at-rest opt-in).
Gaps observed against the pattern from ruflo-ruvector / ruflo-agentdb / ruflo-browser / ruflo-intelligence / ruflo-adr ADRs:
security-patterns namespace. The agent writes there without referencing ruflo-agentdb ADR-0001's namespace convention.ruflo-aidefence should canonicalize this 3-gate pattern so other plugins consume it the same way.docs/adrs/0001-aidefence-contract.md. Cross-links the five sibling ADRs.
Append three sections, retain existing content:
@claude-flow/cli v3.6.security-patterns as the canonical namespace this plugin owns; defer to ruflo-agentdb ADR-0001 §"Namespace convention".ruflo-browser ADR-0001 §4 already uses. Three gates, every consumer plugin handling untrusted content should apply them in this order:
aidefence_has_pii) — before any AgentDB / memory_store writeaidefence_scan) — for cookies, tokens, high-entropy blobs; vault rather than embedaidefence_is_safe) — for any extracted content flowing back to an LLMplugin.json keeps 0.2.0 (already at the cadence). Description retained. Keywords add prompt-injection, defense-in-depth, mcp.
scripts/smoke.sh)10 checks:
0.2.0 with the new keywords.aidefence_* MCP tools referenced in plugin docs.transfer_detect-pii is also referenced (used by pii-detect skill).ruflo-agentdb ADR-0001 namespace convention.Proposed.safety-scan, pii-detect) have valid frontmatter (name + description + allowed-tools).Positive:
security-patterns namespace is now declared.Negative:
ruflo-browser) embeds the 3-gate pattern in its own ADR §4. Updating it to defer here is a separate, mechanical task (the gates remain identical; only the canonical home changes).Neutral:
bash plugins/ruflo-aidefence/scripts/smoke.sh
# Expected: "10 passed, 0 failed"
plugins/ruflo-ruvector/docs/adrs/0001-pin-ruvector-0.2.25.mdplugins/ruflo-agentdb/docs/adrs/0001-agentdb-optimization.md — namespace conventionplugins/ruflo-browser/docs/adrs/0001-browser-skills-architecture.md — §4 codifies the 3-gate pattern this ADR canonicalizesplugins/ruflo-intelligence/docs/adrs/0001-intelligence-surface-completeness.mdplugins/ruflo-adr/docs/adrs/0001-adr-plugin-pattern.mdv3/@claude-flow/cli/src/mcp-tools/security-tools.ts — 6 aidefence_* tool definitions