44 of the 48 `plugins/*/.claude-plugin/plugin.json` manifests had no `repository`, while the four that do already point at the repo URL their `homepage` names. The field is what the directory listing and `npm view` read, and its absence is invisible until something reads it. Add it to the 44 that lack it, then make `scripts/audit-plugin-manifest.mjs` enforce it so the next plugin cannot ship without one: - check 6 in the script header, the violation in `auditManifest`, and the clean-run summary line. A manifest may carry the repository as a string or as an object's `url`; anything else is reported as missing, and a value that is not an http(s) URL is reported separately. - the required-field lists in `create-plugin` and `validate-plugin` skills, so a scaffolded plugin passes the gate it is told to satisfy. Verified with the repo's own gates: - `node scripts/audit-plugin-manifest.mjs` scans 48 manifests, clean. - removing the field from one manifest reports `repository field: missing or empty` and exits 1; setting it to `ruvnet/ruflo` reports `repository is a URL` and exits 1; restoring it exits 0. - `node scripts/check-plugin-manifests.mjs` is unchanged by this diff (its two nested-manifest findings belong to `ruflo-ai-team/directory` and `ruflo-x-gateway/directory`, which this change does not touch). - `node scripts/audit-plugin-secrets.mjs` clean, 48 manifests. No plugin version is bumped: the installed artifact's behaviour does not change and no user-visible surface reads the field from an installed copy, so there is nothing for a version bump to deliver. The `Plugin version bump` workflow will flag the 44 manifests it sees as shipped files, and this PR needs the `skip-plugin-version-check` label rather than 44 unrelated version bumps that would collide with each plugin's own release cadence. Closes #4774
ruflo-security-audit
Security review, dependency scanning, policy gates, and CVE monitoring.
Install
/plugin marketplace add ruvnet/ruflo
/plugin install ruflo-security-audit@ruflo
What's Included
- Security Scanning: Deep scan with
security scan --depth deep(valid: quick, standard, deep) - CVE Monitoring: Automated CVE detection and remediation guidance
- Input Validation: Zod-based validation at system boundaries via
@claude-flow/security - Path Security: Traversal prevention and safe executor for command injection protection
- Policy Gates: Configurable security policies for CI/CD pipelines
- Threat Modeling: Automated threat analysis and risk assessment
Patterns to scan for (audit_1776853149979 follow-up)
The 3.6.25 release closed a class of shell-injection bugs. When auditing downstream code, the scanner should flag these patterns:
execSync(string)with template-literal args — replace withexecFileSync(cmd, argv, { shell: false }). Closed sites:github-safe.js,statusline.js/cjs(git calls),mcp-tools/github-tools.ts(gh pr/issue/run),update/executor.ts(npm install).- Numeric MCP inputs cast as
number— TypeScript casts don't run at runtime. AprNumber: "1; rm -rf /"slips through. Mitigate viatoPositiveInt(value)(seesrc/mcp-tools/github-tools.ts). - Untrusted package specs flowing into
npm install— gate viaisSafePackageSpec(pkg, version)regex check (seesrc/update/executor.ts). Defense-in-depth even withexecFileSync. - Loader-hijack env vars (
LD_PRELOAD,NODE_OPTIONS,DYLD_*) flowing into a child process env — gate viavalidateEnv()(seesrc/mcp-tools/validate-input.ts). - Plaintext secrets at rest in
.claude-flow/sessions/,.claude-flow/terminals/store.json,.swarm/memory.db— paired with ADR-096 opt-in encryption (CLAUDE_FLOW_ENCRYPT_AT_REST=1). Confirm gate state viaruflo doctor -c encryption. - MCP stdin DoS — un-newlined input piped into the MCP server. The host caps the buffer at 10MB by default; downstream MCP wrappers should enforce equivalent limits.
A ruflo verify round-trip confirms 55 witnesses (27 regression-fix + 28 per-source-file capability) match the signed manifest byte-for-byte.
Requires
ruflo-coreplugin (provides MCP server)
Compatibility
- CLI: pinned to
@claude-flow/cliv3.6 major+minor. - Verification:
bash plugins/ruflo-security-audit/scripts/smoke.shis the contract.
AIDefence integration
This plugin's static scanning (CVE / dependency / shell-injection patterns) complements the runtime gates owned by ruflo-aidefence ADR-0001:
| Layer | Owner | What it catches |
|---|---|---|
| Static analysis (this plugin) | ruflo-security-audit |
Shell-injection patterns, dependency CVEs, plaintext secrets at rest, loader-hijack env vars |
| Runtime gates (3-gate pattern) | ruflo-aidefence ADR-0001 |
PII pre-storage gate, sanitization gate, prompt-injection gate |
The two layers are complementary: static analysis finds the patterns; the 3-gate runtime catches what slipped through.
Namespace coordination
This plugin owns the security-findings AgentDB namespace (kebab-case, follows the convention from ruflo-agentdb ADR-0001 §"Namespace convention"). Reserved namespaces (pattern, claude-memories, default) MUST NOT be shadowed.
security-findings indexes scan results by file + commit + severity. Accessed via memory_* (namespace-routed).
Verification
bash plugins/ruflo-security-audit/scripts/smoke.sh
# Expected: "10 passed, 0 failed"
Architecture Decisions
As a mod
This plugin also loads as a function-hook mod (ADR-445 pattern, hooks/hooks.json → register.ts). No network, no process spawn, no model call.
- Guard (default on, tighten-only). It refuses to store an audit finding that quotes a live secret in a
security*,audit*,cve*,vuln*,findings*orsecaudit*memory namespace (memory_store,agentdb_hierarchical-store,agentdb_pattern-store). The refusal never repeats the secret. - Status file.
.claude-flow/secaudit-mod/status.json({version: 1, updatedMs, guard, checked, blocked, seen}), written at session start and when a counter changes. /secaudit-modanswers locally:status,scan <text>,namespaces. (The plugin's own commands are prompt commands, which a hook cannot answer, so the mod has its own name.)- Option.
guard(on|off, defaulton) in the plugin'suserConfig.
Test it: claude plugin validate plugins/ruflo-security-audit, claude plugin test plugins/ruflo-security-audit, bash plugins/ruflo-security-audit/scripts/smoke.sh.