Skip to content
Tech Atlas, home
Search
Esc
  • All roadmapsBrowse every learning path
  • ExploreFind a technology area
  • ProjectsGuided projects and builds
  • My AtlasYour learning dashboard
Lesson 2 of 6 · Worked example · 20 min · revision 2

Rating Risk with Likelihood and Impact

Build and score a risk register for a small physiotherapy clinic step by step: define likelihood and impact scales, score inherent risk, account for existing controls to get residual risk, rank and choose a treatment, then check one decision with annual loss expectancy.

Contentsand lesson path

What you will learn

  • Estimate and rank the risks to a small system from likelihood, impact and existing controls.

01. The problem

Northfield Physio is a clinic with twelve staff. It has an online booking site run by a hosting company, a cloud application for patient notes, a shared reception mailbox, three reception PCs with a file share, and laptops that therapists take on home visits. The owner has a small budget and asks a simple question: "What should we fix first?"

Answering it is risk assessment. A risk is the possibility that a threat exploits a weakness and harms something of value. Risk has two parts: likelihood, how probable the harmful event is over a period, and impact, how bad it would be. NIST SP 800-30, the US government's guide to risk assessments, uses the same two factors. You will work through the method on the clinic in five steps, with Python (3.10 or newer, standard library only) doing the arithmetic so that you can focus on the judgements.

02. Step 1: write down the scales

Scores are only comparable if everyone means the same thing by "3". So the first step is to write short definitions for each level, with examples that fit the organisation. For the clinic:

  • Likelihood: 1 rare (less than once in ten years), 2 unlikely (once in five to ten years), 3 possible (about once in one to five years), 4 likely (about once a year), 5 almost certain (several times a year).
  • Impact: 1 negligible (minutes of disruption, no personal data), 2 minor (a lost morning of bookings), 3 moderate (a few days of disruption, or personal data of a few patients exposed), 4 major (clinical notes of many patients exposed, regulator notified), 5 severe (the clinic cannot work for weeks, or could close).

Multiplying the two gives a score from 1 to 25. The product is a ranking aid, not a measurement: a 12 is not exactly twice as bad as a 6. Its job is to put the register into a defensible order and to start the right conversation.

03. Step 2: list the risks and score them without controls

A good risk statement names a threat, the thing it harms and the outcome, in one sentence. "Hackers" is not a risk; "a former employee can still sign in to the notes app" is. The CSV below holds six risks for the clinic. The likelihood and impact columns are the inherent scores, meaning the risk as it would be with no specific control in place. The last three columns describe the control the clinic already has, and how many levels it lowers likelihood or impact, which you will use in step 3.

CSV · risks.csv
id,risk,likelihood,impact,control,lower_l,lower_i
R1,Phishing takes over the shared reception mailbox,4,3,MFA on all email,2,0
R2,Ransomware encrypts reception PCs and files,3,5,Offline backup tested monthly,0,2
R3,Booking site goes offline (attack or host failure),3,2,none,0,0
R4,A therapist laptop with patient notes is stolen,3,4,Full-disk encryption,0,3
R5,A former employee can still sign in to the notes app,2,4,none,0,0
R6,Card details are skimmed from the booking page,2,4,Provider-hosted payment page,1,0

Look at how each control acts. MFA makes a successful mailbox takeover much less likely, so it lowers likelihood. A tested backup does nothing to stop ransomware arriving, but it turns weeks of downtime into a day of restoring, so it lowers impact. Full-disk encryption does not stop a thief, but it means the stolen laptop does not expose patient notes: impact falls from 4 to 1. Taking card payments on the payment provider's own page means card data never passes through the clinic's site, which lowers likelihood. R3 and R5 have no control at all.

04. Step 3: compute residual risk and rank

Residual risk is what remains after existing controls are taken into account. Ranking must use residual risk, because the owner's question is about what is exposed today. The script computes both scores, keeps every level between 1 and 5, and ranks by residual score, using inherent score to break ties. The clinic's risk appetite, the level of risk it is willing to live with, is set at 8: anything at or above it needs a treatment decision.

Python · risk.py
"""Score a small risk register: inherent risk, residual risk and ranking."""
import csv

APPETITE = 8  # residual scores at or above this need a treatment decision


def clamp(value: int) -> int:
    return max(1, min(5, value))


rows = list(csv.DictReader(open("risks.csv", encoding="utf-8")))
for r in rows:
    r["inherent"] = int(r["likelihood"]) * int(r["impact"])
    r["res_l"] = clamp(int(r["likelihood"]) - int(r["lower_l"]))
    r["res_i"] = clamp(int(r["impact"]) - int(r["lower_i"]))
    r["residual"] = r["res_l"] * r["res_i"]

by_inherent = sorted(rows, key=lambda r: -r["inherent"])
rank_before = {r["id"]: i + 1 for i, r in enumerate(by_inherent)}

print("rank  id  inherent  residual  was  action")
for i, r in enumerate(sorted(rows, key=lambda r: (-r["residual"], -r["inherent"])), 1):
    action = "treat" if r["residual"] >= APPETITE else "accept and monitor"
    inherent = f"{r['likelihood']}x{r['impact']}={r['inherent']}"
    residual = f"{r['res_l']}x{r['res_i']}={r['residual']}"
    was = f"#{rank_before[r['id']]}"
    print(f"{i:>4}  {r['id']}  {inherent:<8}  {residual:<8}  {was:<4} {action}")
Terminal
python3 risk.py
Expected output
rank  id  inherent  residual  was  action
   1  R2  3x5=15    3x3=9     #1   treat
   2  R5  2x4=8     2x4=8     #4   treat
   3  R1  4x3=12    2x3=6     #2   accept and monitor
   4  R3  3x2=6     3x2=6     #6   accept and monitor
   5  R6  2x4=8     1x4=4     #5   accept and monitor
   6  R4  3x4=12    3x1=3     #3   accept and monitor

The was column shows how much the order changes. R4, the stolen laptop, was third on inherent score and is now last, because encryption removed most of its impact. R5, the former employee, climbs from fourth to second, purely because nothing controls it. Ranking on inherent scores would have spent the next pound on laptops, which are already well protected, and ignored an open door.

05. Step 4: choose a treatment

For each risk at or above appetite, choose one of four standard treatments:

  • mitigate (also called reduce): add or improve controls;
  • transfer (or share): move part of the impact to someone else, usually through insurance or a contract;
  • avoid: stop the activity that creates the risk;
  • accept: live with it, as a recorded decision by someone with the authority to make it.

R2 stays top even with backups, so the clinic mitigates further: it removes local admin rights from reception PCs and keeps their software patched, which lowers likelihood. R5 is cheap to mitigate with a leaver checklist that removes access on the last working day, and a quarterly review of who can sign in. R1 and R3 sit below appetite and are accepted and monitored, with an owner and a date to look again. Acceptance is a legitimate choice, but only when it is written down; "we never looked at it" is not acceptance.

06. Step 5: check one decision with numbers

Scores order risks; they do not tell you whether a control is worth its price. For that, practitioners use a simple quantitative model. Single loss expectancy (SLE) is the cost of one occurrence. Annual rate of occurrence (ARO) is how many times a year it is expected. Their product is annual loss expectancy (ALE). A control is worth buying on cost alone when the ALE it removes is greater than what it costs each year.

R3, the booking site outage, is below appetite. The clinic estimates each outage costs about £1,800 in missed bookings and staff time, and it has had about three a year. A managed protection and failover service costs £1,200 a year and, judging by the provider's service record, would cut outages to about one every two years. These figures are estimates; the method is only as good as they are.

Python · ale.py
"""Is a managed DDoS and failover service worth buying for risk R3, on cost alone?"""
sle = 1_800          # single loss expectancy per outage: lost bookings, staff time
aro_now = 3.0        # annual rate of occurrence: about three outages a year
aro_after = 0.5      # the provider's service level suggests one outage every two years
cost = 1_200         # annual cost of the service (GBP)

ale_now, ale_after = sle * aro_now, sle * aro_after
saving = ale_now - ale_after
print(f"ALE now:    {ale_now:>7,.0f} GBP/year")
print(f"ALE after:  {ale_after:>7,.0f} GBP/year")
print(f"saving:     {saving:>7,.0f} GBP/year, cost {cost:,} GBP/year")
verdict = "buy" if saving > cost else "do not buy"
print(f"net benefit {saving - cost:>6,.0f} GBP/year -> {verdict}")
Terminal
python3 ale.py
Expected output
ALE now:      5,400 GBP/year
ALE after:      900 GBP/year
saving:       4,500 GBP/year, cost 1,200 GBP/year
net benefit  3,300 GBP/year -> buy

The comparison that matters is the reduction in ALE (£4,500) against the cost (£1,200), not the whole ALE. Here the control pays for itself even though R3 was below appetite, so the clinic buys it. The two methods answer different questions: the qualitative register says where the exposure is, and ALE says whether a particular fix is good value. Some costs, such as harm to patients or reputation, do not fit neatly into SLE; record them next to the number rather than pretending they are zero.

07. Check your understanding

Practice check · 3 questions

Rating risk

Use the clinic's register and the script output.

Q1. In the output, R4 (the stolen laptop) falls from third to last, although its likelihood is still 3. Why?
Q2. Two staff score the likelihood of a mailbox takeover as 2 and 4. What does most to make future scores consistent?
Q3. The clinic was going to offer video sessions through an old, unpatched video tool. Instead of securing it, it decides not to offer video sessions at all. Which treatment is this?
Practice only: not graded, not saved, not evidence.

08. Apply it

The skill's practice task asks for a short risk rating for the organisation in a real advisory. Practise here first: write a risks.csv with five risks for a small system you know, define your scales in two lines each, and run risk.py on it. Pick one control you would like to buy, estimate SLE and ARO with a sentence explaining each number, and run ale.py with your values.

09. Review prompt

Without looking back: define likelihood, impact, inherent risk and residual risk. Name the four treatments with an example of each. Then explain what SLE, ARO and ALE are and what you compare a control's annual cost with.

References

Your progress

Reading state

Sign in to save that you finished reading this lesson.

Sign in to mark reading complete

Prove this skill

8 questions · about 6 minutes · scored automatically. Marking a lesson as read never demonstrates a skill.
Take the skill check