fable-heal
Skill6 starsChanged 3 months agoMITView on GitHub
Automatically synthesize, apply, and verify security remediations for vulnerabilities identified by fable-redteam. Generates surgical AST and code patches, creates continuous TDD regression test guards, performs atomic workspace mutations with automated rollback circuit breakers, and seals cryptographic healing attestations.
- Reads credentials
In this repository55 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .codex/AGENTS.mdAGENTS.md
- docs/AGENTS.mdAGENTS.md
- skills/fable-tend/AGENTS.mdAGENTS.md
- skills/fable-wise/AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- skills/fable-tend/CLAUDE.mdCLAUDE.md
- skills/fable-tend/site/CLAUDE.mdCLAUDE.md
- skills/fable-wise/CLAUDE.mdCLAUDE.md
- public/llms.txtllms.txt
- get-fableSkill
- typesafe-aiSkill
- get-fableSkill
- get-fableSkill
- fable-architectureSkill
- fable-artifactSkill
- fable-configSkill
- fable-context-thriftSkill
- fable-councilSkill
- fable-coworkSkill
- fable-datavizSkill
- fable-delegateSkill
- fable-discoverSkill
- fable-domainSkill
- fable-ecoSkill
- fable-evalSkill
- fable-executeSkill
- fable-finish-your-turnSkill
- fable-handoffSkill
- fable-judgeSkill
- fable-learningSkill
- fable-loopSkill
- fable-memorySkill
- fable-methodSkill
- fable-native-codeSkill
- fable-outcome-firstSkill
- fable-planSkill
- fable-prove-itSkill
- fable-recoverSkill
- fable-redteamSkill
- fable-releaseSkill
- fable-researchSkill
- fable-reviewSkill
- fable-runSkill
- fable-scope-disciplineSkill
- fable-securitySkill
- fable-simplifySkill
- fable-simulatorSkill
- fable-skill-creatorSkill
- fable-sparkSkill
- fable-tddSkill
- fable-tendSkill
- fable-verifySkill
- fable-wiseSkill
- get-fableSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
16 rules. About 0 are common, 12 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈12
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 50
Before vulnerabilities have been identified or reproduced (use fable-redteam or fable-security).
- Distinctive: line 78
Atomic Application & Guard: If applied, write patches with automated backup.
- Distinctive: line 79
Closed-Loop Verification: If target is accessible, execute verification probes to confirm fix.
- Distinctive: line 83
If syntax check or typecheck fails on a candidate patch, trigger rollback immediately via circuit breaker.
- Distinctive: line 84
Always generate executable TDD regression test suite before sealing remediation.
- Very specific: line 85
Never modify files in dryRun mode.
- Distinctive: line 86
When target endpoint is live and verification is requested, probe target to prove vulnerability closure before completing.
- Distinctive: line 90
Do not apply patches without automated rollback circuit breaker in place.
- Distinctive: line 91
Do not bypass verification tests when closing active security work cards.
- Very specific: line 95
Use native AST patching and regex transformers from src/core/redteam/heal.ts.
- Very specific: line 96
Run Bun test runner (bun test) to execute generated regression test suites.
- Distinctive: line 97
Use native SHA-256 crypto for cryptographic attestation generation.
- Distinctive: line 105
If a candidate patch produces invalid syntax or type errors, immediately rollback changes via the circuit breaker.
- Distinctive: line 106
If regression tests fail, revert applied patches and flag finding for manual developer review.
- Distinctive: line 107
If target server is unavailable during closed-loop verification, mark verification as pending without blocking patch application.
- Distinctive: line 110
All identified vulnerability findings mapped to remediation strategies.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Fable Heal
Automatically synthesize, apply, and verify security fixes for vulnerabilities detected by fable-redteam.
Purpose
Bridge the gap between active vulnerability discovery and verified code remediation. fable-heal translates offensive security findings (SQL injection, BOLA/IDOR, CORS misconfigurations, missing security headers, sensitive file leaks, SSRF, JWT signature bypass, and LLM prompt injections) into concrete, tested, verified code patches with zero regressions.
When to Use
fable-redteamor security audits have identified vulnerabilities that need immediate code remediation.- Automatically generating TDD regression test suites to ensure security flaws stay closed in CI.
- Applying surgical code patches in staging or local branches with atomic rollback protection.
- Verifying whether candidate security patches successfully eliminate attack vectors.
When NOT to Use
- Before vulnerabilities have been identified or reproduced (use
fable-redteamorfable-security). - For general non-security application refactoring (use
fable-simplify). - Direct production patching without human review or staging verification.
Inputs
redteam_findings: Array or file path of structured vulnerability findings fromfable-redteam.target: Target HTTP/HTTPS endpoint or repository workspace.dryRun: When true, previews generated patches and unified diffs without modifying files.autoApply: When true, writes patches directly to matching codebase source files.verify: When true, re-runs attack vectors against the target to prove vulnerability resolution.
Expected Outputs
security_patches: Concrete code replacements with unified diffs.test/security/redteam-healed.test.ts: Executable Bun test suite asserting vulnerability closure..fable/heal-attestation.json: Tamper-evident cryptographic SHA-256 attestation record..fable/LEDGER.md: Updated work cards marked as remediated.
Procedure
- Finding Ingestion: Load findings from
fable-redteam, SARIF reports, or.fable/redteam-findings.json. - Strategy Selection: Map each finding category and CWE to its surgical remediation pattern:
- SQL Injection (CWE-89) -> Parameterized queries.
- IDOR/BOLA (CWE-639) -> Resource ownership verification guard.
- CORS Misconfiguration (CWE-942) -> Strict origin whitelist.
- Missing Security Headers (CWE-1021) -> Content-Security-Policy, HSTS, XFO headers.
- Sensitive Exposures (CWE-200) -> Route denial for
.env,.git, and secrets. - SSRF (CWE-918) -> Outbound URL and IP validation blocking loopback and cloud metadata.
- Patch Synthesis: Generate code transformations and compute unified diffs.
- TDD Test Generation: Emit executable test assertions into
test/security/redteam-healed.test.ts. - Atomic Application & Guard: If applied, write patches with automated backup. On syntax or compilation failure, trigger circuit-breaker rollback.
- Closed-Loop Verification: If target is accessible, execute verification probes to confirm fix.
- Attestation & Ledger Sealing: Record cryptographic SHA-256 seal and mark work cards closed.
Decision Rules
- If syntax check or typecheck fails on a candidate patch, trigger rollback immediately via circuit breaker.
- Always generate executable TDD regression test suite before sealing remediation.
- Never modify files in
dryRunmode; only emit unified diffs and previews. - When target endpoint is live and verification is requested, probe target to prove vulnerability closure before completing.
- Record SHA-256 cryptographic attestation in
.fable/heal-attestation.jsonfor all applied patches.
Constraints
- Do not apply patches without automated rollback circuit breaker in place.
- Do not bypass verification tests when closing active security work cards.
- Patches must be surgical and preserve existing application business logic and comments.
Tool Policy
- Use native AST patching and regex transformers from
src/core/redteam/heal.ts. - Run Bun test runner (
bun test) to execute generated regression test suites. - Use native SHA-256 crypto for cryptographic attestation generation.
Evidence Requirements
- Synthesized patches must provide exact file paths, strategy name, and unified diffs.
- Applied patches require syntax verification and automated regression test generation in
test/security/redteam-healed.test.ts. - Cryptographic healing attestation at
.fable/heal-attestation.jsonverifying integrity of all applied patches.
Failure Handling
- If a candidate patch produces invalid syntax or type errors, immediately rollback changes via the circuit breaker.
- If regression tests fail, revert applied patches and flag finding for manual developer review.
- If target server is unavailable during closed-loop verification, mark verification as pending without blocking patch application.
Completion Criteria
- All identified vulnerability findings mapped to remediation strategies.
- Unified diffs and patches synthesized for vulnerable targets.
- TDD regression test suite generated and passing in
test/security/redteam-healed.test.ts. - Cryptographic attestation recorded in
.fable/heal-attestation.json. - Remediation status recorded in
.fable/LEDGER.md.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

