Lesson 4: Make changes you can explain
You will be able to: review a change for common security defects, and identify the evidence that shows the change followed the process.
About 4 min
Change management means changes are authorized, designed, developed, tested, approved, and deployed in a controlled way, so the organization can show what changed, who approved it, and why. For most teams the pull request is where this happens: a reviewer other than the author, required checks, and a deployment record that ties back to the merge.
Source: AICPA Trust Services Criteria, CC8.1(opens in a new tab)
Secure development builds on the same workflow: secure design, code review that looks for security defects, automated tests, dependency and vulnerability scanning, and secret scanning.
- Vulnerabilities are fixed within timeframes the organization sets according to risk. Frameworks generally require a defined, risk-based process; they do not set one universal deadline.
- Exceptions happen. When a requirement cannot be met on time, record a time-bound exception that an accountable owner approves, with compensating controls and a remediation date.
- Emergency changes can use an expedited path, but still need approval and a review after the fact.
Exercise 1 of 2: Review the pull request
A teammate opened a pull request that adds an invoice endpoint to Brightwell’s billing service. Each customer account should only ever see its own invoices.
Flag each added line that contains a defect and choose the type of defect. Then choose fixes and the evidence that would show this change followed the process.
- 1
import { Router } from "express"; - 2
import { db } from "../db"; - 3
import { logger } from "../logger"; - 4
import { requireAuth } from "../auth"; - 5
const LEDGER_API_KEY = "lk_live_7f3a9c2e41b8d6f05a1e";- 7
- 8
export const invoices = Router(); - 9
invoices.get("/invoices/:id", requireAuth, async (req, res) => {logger.info("invoice request", { user: req.user, headers: req.headers });const invoice = await db.invoices.findById(req.params.id);if (!invoice) return res.status(404).end();const ledger = await fetch(`https://ledger.example/v1/balances/${invoice.accountId}`, {headers: { Authorization: `Bearer ${LEDGER_API_KEY}` },});res.json({ id: invoice.id, total: invoice.total, balance: (await ledger.json()).balance });});
Select a line number to flag it, then choose the type of defect. Unflagged lines count as “no defect.”
Apply it 2 of 2: A fix you cannot ship this week
A critical vulnerability is published for a library you use. A patched version exists, but upgrading breaks a feature you cannot fix before your organization’s remediation deadline.
What is the compliant path?
Key points
- Every production change should be explainable: who changed it, who approved it, how it was tested, when it shipped.
- In review, look for secrets in code, sensitive data in logs, and missing authorization checks.
- Authentication says who the caller is. Authorization says whether they may do this. Check both on the server.
- When you cannot meet a deadline, get a time-bound, approved exception with compensating controls. Never hide the finding.