--- name: security-remediation description: Plan, apply, and verify approved fixes for established web application security findings, including regression tests and rollback evidence. --- # Remediation and verification Read the installed sibling `../web-security-audit/SKILL.md` for boundaries, evidence, and stopping rules. Apply this specialist workflow to the requested scope. For repository-specific context, use the template at `../web-security-audit/assets/context.md`. Reconcile existing context with current code and continue with available repository evidence if no context exists. Select issue IDs and establish baseline evidence. Check whether the workspace already contains a patch and whether the evidence still applies to the target revision. For each issue write the policy invariant, patch boundary, affected callers, data compatibility, rollout and rollback needs, and criteria for verified-fixed. Read the core remediation guide and the relevant specialist. Obtain approval for high-impact changes. Prefer a focused patch at the boundary that actually controls the data or operation. Inspect sibling paths and shared callers. Keep proposed changes distinguishable from applied changes and protect unrelated local work. Exercise positive and negative control decisions through normal local test entry points with synthetic inputs and stubbed side effects. Inspect the final diff for new authorization gaps or sensitive emissions. Capture exact revision, test, result, and limits. Return rejected or deferred fixes and reasons. Update the ledger where authorized, preserving IDs and evidence. If the fix changes durable state, assess existing records, stale caches, issued credentials, and queued work for separate cleanup needs. Capture forward recovery options when rollback could restore insecure state or conflict with a migration. Define the evidence that would support closing the finding after rollout and who owns that decision. For changes tied to explicit acceptance requirements, use the product security acceptance checks in `threat-modeling` when installed. ## Finding closure record For each issue record the baseline revision and failed invariant, changed boundary, resulting revision, positive and denial observations, side-effect assertions, and unresolved rollout checks. State who owns any migration or cleanup. Carry the original finding ID forward when the policy is shared or the issue reappears. Return revision-relative evidence and coverage gaps using the report template at `../web-security-audit/assets/report.md`. If a patch changes a shared guard, sample one sibling caller that must retain access and one that must remain denied. Date the verification and distinguish patch behavior from any rollout evidence required to close the finding. Read [the enterprise review guide](references/enterprise-review.md) when a fix changes shared policy, durable state, or a production release gate.