Learn by Directing AI
Unit 7

Remediation with Risk Assessment

Step 1: Categorize findings by remediation approach

Not every finding has the same kind of fix. Review the confirmed vulnerabilities and sort them into three categories.

Straightforward fixes -- the SQL injection in the export tracker can be patched with parameterized queries. The XSS in the member portal can be fixed with output encoding. The fermentation API needs authentication. These are the cooperative's own code, and the fixes are well-understood.

Risky fixes -- the payment processor's vulnerable dependency can be updated, but updating a dependency in a system that processes payments during export cycles might break something. The fix introduces its own risk.

Unfixable in this engagement -- the shipping API transmits buyer pricing in URL parameters. That is the third party's system. The cooperative cannot change it. They can only manage their side of the exposure.

Categorize all confirmed findings by remediation approach: straightforward fix, risky fix requiring impact assessment, or requires compensating control. For each finding, note what the fix involves and what might break.

Step 2: Assess remediation risk for complex fixes

For the risky fixes, assess what might break. The payment processor depends on PyYAML -- updating the dependency to fix the known CVE might change the YAML parsing behavior that the payment processing code relies on. What other systems consume the payment processor's output? Does the export tracker depend on payment confirmations during shipment week?

For each risky remediation, perform a risk assessment. Identify: what the fix changes, what downstream systems depend on the vulnerable component, what could break, and what the impact would be if the fix fails during a critical business period. Compare the risk of the vulnerability against the risk of the fix.

AI commonly patches dependencies to the latest version without checking compatibility. If you direct AI to "fix the vulnerable dependency," it will update PyYAML to the latest version. That may fix the CVE. It may also change the YAML loading behavior that the payment processing code depends on. Ask AI about the dependency chain, but verify the compatibility yourself.

Step 3: Design compensating controls

For findings that cannot be fully fixed during this engagement, design compensating controls.

The shipping API pricing exposure is the clearest case. The cooperative cannot change the third party's API. But they can:

  • Rotate API keys on a regular schedule
  • Log all requests to the shipping API and monitor for unusual patterns
  • Alert on pricing queries that do not correspond to active shipments
  • Limit which systems can reach the shipping API
Design compensating controls for the shipping API pricing exposure. Document: what the control does, what risk it mitigates, what it does not cover, and what the recommended next steps are (contacting the shipping provider to negotiate an API change).

Share the shipping API finding with Andres. Explain that buyer pricing is exposed through the third-party integration. He will understand the business impact immediately -- "If someone sees what we charge Portland versus Tokyo, it could destroy years of pricing relationships." Explain what a compensating control is in plain terms: a safety net while you work on the real fix. Andres will ask whether they should talk to the shipping company -- that is exactly the right next step.

Step 4: Write rollback procedures

Every risky remediation needs a way back. If the dependency update breaks the payment processor, the cooperative needs to undo the change before the next export cycle.

For each risky remediation, write a rollback procedure. Include: what to check after the fix is applied (smoke tests), what symptoms indicate the fix broke something, exact steps to revert the change, and how long the rollback takes. The rollback should be executable by the Caracas developer who may not understand the security context.

AI does not generate rollback procedures unless explicitly asked. If you direct AI to "implement the fix," you get the fix. The rollback is your responsibility to request. This is a professional discipline -- a fix without a rollback plan cannot be safely deployed in a production system.

This is new territory. Previous projects had straightforward remediations -- fix the vulnerability, verify the fix, move on. Remediation risk assessment, compensating controls, and rollback procedures are professional practices that emerge when the systems are real enough that breaking them matters. If you are not sure how to assess the risk of a specific fix, that uncertainty is a directing opportunity. Ask Claude to help you think through what could go wrong -- but verify the analysis against what you know about the cooperative's systems.

Step 5: Prioritize by business risk

Build the final remediation plan. The priority order should reflect both vulnerability severity and remediation risk.

A critical vulnerability with a safe, straightforward fix goes first. A critical vulnerability with a risky fix that could break the export tracker during shipment week goes later -- after the safe fixes are in place and tested. A medium-severity finding with a trivial fix might be higher priority than a high-severity finding that requires the Caracas developer and a two-week implementation.

Create the prioritized remediation plan. For each finding, show: vulnerability severity, remediation risk, priority rank, remediation approach (fix, compensating control, or recommendation), and timeline. The priority order should visibly differ from a simple severity ranking -- explain why.

The priority order tells a story. It shows the Portland buyer that the cooperative is not just aware of the vulnerabilities but has a plan that accounts for the reality of fixing things in a working system with eight staff and a remote developer.

✓ Check

Check: Remediation risk assessed, compensating control documented, rollback procedure written, prioritisation reflects both severity and risk. At least 1 remediation includes risk assessment, at least 1 compensating control for unfixable finding, at least 1 rollback procedure, priority order accounts for fix risk.