agentleFS
awarexoneawarexone/AXguard/security-remediation/SKILL.md

security-remediation

Skill18 starsChanged 3 months agoMITView on GitHub

Apply minimal defensive patches for confirmed findings and verify with re-audit — post-triage only.

  • Pipes a download into a shell

2 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 4 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈4

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    After /axguard-triage (or equivalent) produced a Keep list

    line 37
  2. Very specific:

    When the user asks to patch AXguard-confirmed bugs

    line 38
  3. Distinctive:

    Add or adjust tests that treat malicious strings as data, not as instructions to exploit third parties.

    line 66
  4. Distinctive:

    Do not “fix” by:

    line 79
  5. Distinctive:

    Update report with fixed vs open counts.

    line 104
  6. Distinctive:

    No exploit procedures included.

    line 125

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Security Remediation

Purpose

Drive confirmed-finding fixes: minimal diffs, critical first, then prove the issue is gone via re-scan and targeted review. Complements orchestration skill axguard-remediate / /axguard-fix.

When to Use

  • After /axguard-triage (or equivalent) produced a Keep list
  • When the user asks to patch AXguard-confirmed bugs
  • Hotfix for secrets, RCE sinks, auth bypass

When Not to Use

  • Fixing untriaged scanner noise (triage first)
  • Adding exploit PoCs “to demonstrate” the bug
  • Broad refactors unrelated to the confirmed sink

Security Concepts

Remediation closes the missing control on a validated source→sink path: parameterize, authorize, allowlist, remove secret, disable debug, constrain agent tools. Prefer the smallest change that removes exploitability without inventing new surfaces.

Threat Model

Bad remediation risks:

  1. Cosmetic fixes that leave the sink reachable.
  2. New bugs from rushed patches (e.g. broken auth checks).
  3. Secret “removed” from file but not rotated / still in git history.

Analysis Workflow

  1. Input: Keep list from security-triage / axguard-triage with locations and confidence.
  2. Order: critical → high → medium; secrets and RCE first.
  3. For each item, open the domain skill (e.g. sql-injection, secrets-detection, ai-agent-security) and apply its Remediation guidance.
  4. Patch minimally: bind parameters, add authZ, allowlist hosts, load secrets from a manager, remove shell=True, pin deps, etc.
  5. For secrets: rotate at provider first, then remove from tree/history as needed; never paste live secrets into chat.
  6. Add or adjust tests that treat malicious strings as data, not as instructions to exploit third parties.
  7. Re-run axguard audit / relevant /axguard-* command; record delta (fixed / remaining / new).
  8. Hand residual issues back to triage or /axguard-report.

Evidence Requirements

  • Finding ID + pre-fix evidence pointer
  • Patch locations (files)
  • Post-fix scan result
  • For secrets: rotation confirmation (without secret values)

False Positive Controls

Do not “fix” by:

  • Deleting the rule or blanketing # nosec without justifying safety
  • Moving vulnerable code to an unscanned path
  • Marking resolved while the sink remains

Remediation

Pattern catalog (defensive):

ClassPrefer
SQLiBound parameters; allowlist identifiers
SSRFAllowlist hosts; block link-local/metadata
SecretsRotate + env/secret manager
XSSContext-aware encoding / safe APIs
Agent/MCPTyped tools; no exec of model text
SupplyPin + verify; drop curl|sh
DebugForce safe prod defaults

Verification

  1. axguard audit clean for that rule id (or explained residual).
  2. Manual confirmation the data flow no longer reaches an unsafe sink.
  3. Regression tests green.
  4. Update report with fixed vs open counts.

Related Skills

Orchestration: axguard-remediate, axguard-triage, axguard-audit, axguard-report.
Domain skills supply per-class fix patterns.

Framework Mapping

Operational skill — inherit CWE/OWASP IDs from the finding’s domain skill when reporting.

References

Research Provenance

Primary: AXGuard remediate/fix orchestration and domain skill remediations (2026-09-15).
Secondary: OWASP CheatSheetSeries methodology themes (CC-BY-SA-4.0; no sheet dumps).
No exploit procedures included.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.