Try each exercise first, then open its model answer.
Records a stranger can verify · Workbook
Three exercises, one for each thing this module teaches. Big Widget Company and everything it does here are made up. Do not use real names, customers, keys or records from your own work. Write short answers. "I don't know yet" is an honest answer if you also say who you would ask.
Exercise 1 (400.8-a)
The model says so. Big Widget's made-up stock-control system reports that a parts store in its Ohio plant is 40 units short of a costly part, three months running. The store's supervisor, Dana, is the only person with a key. A manager writes: "The system shows the parts are missing, and only Dana could have taken them. Start a disciplinary case." You also know three things:
- The stock table is fed by a nightly job that the data team can re-run and edit by hand.
- The system's issue log has an open ticket: some transfers between plants are counted twice.
- Nobody has counted the shelves by hand.
- Using the three questions from the lesson, write one thing that must be checked before any action against Dana.
- Which finding from the Horizon judgments would you quote to the manager, and why does it fit?
- Dana asks to see what the company knows about faults in the system. Should she get the issue log? Say why, using Horizon.
- The manager replies: "So you're saying computer records are useless as evidence?" Answer in one or two sentences.
- While the checks are being done, what should the gate's answer be: go ahead, only this far, wait for a person, or no? Who should be able to end it, and what happens if one check cannot be done?
Model answer
- The three questions:
- Other proof? Count the shelves by hand, and check delivery notes and transfer paperwork. Those do not come from the same system.
- Who could change the record, and could we tell? The data team can re-run and edit the nightly job. Has the stock table been edited since the shortages appeared, and is there a record of who did it? In Horizon, Fujitsu could change branch data without the person running the branch knowing, and an injected entry would look as though that person had done it.
- Known problems? The double-counted transfers ticket could explain an apparent shortage. It must be checked against these months, and shown to whoever decides.
- A good answer quotes the Court of Appeal (2021): "If the Horizon data was not reliable, there was no basis for the prosecution." It fits because here, too, the only evidence is the system's own number. The court also said the Post Office treated "a shortfall shown by an unreliable accounting system as an incontrovertible loss", and in effect asked the accused to disprove it. "Only Dana could have taken them" does the same thing.
- Yes. In Horizon, Fujitsu's bug records (PEAKs and KELs) existed, but, so far as the court knew, they were not disclosed in any of the 42 prosecutions before it. A person cannot challenge a record if they are not shown what is known to be wrong with it.
- No. In the three Horizon appeals where the case did not rest on Horizon data, the convictions stood. The point is that a computer record has to be shown to be reliable, and open to challenge, before anyone relies on it against a person.
- Wait for a person (hold), not no. What waits is the proposed disciplinary case, not Dana's ordinary work and pay: nothing is decided against her yet. A named role, such as the plant's operations manager (made up), is the only one who can end the hold or escalate it. If a check cannot be done, the honest answer is "not checked", and the case does not go ahead on the system's number alone; a hold is not a back door to the action. Anything done to Dana in the meantime, such as suspending her, would itself be an adverse action: a separate decision by a person, with a written reason, a time limit and a way for her to challenge it. "No" is not right either: dropping the matter for good would ignore a possible real loss before anyone has checked.
Exercise 2 (400.8-b)
What your check proves. Big Widget's made-up warranty system writes one record per decision. Each record is written in one fixed form, includes the fingerprint (hash) of the record before it, and every night the system signs a checkpoint: "so far there are n records, and the last fingerprint is h." Questions 1 to 5 use this module's rules: records are numbered from 1, so the checkpoint's n is a count. Question 6 is about the course's practice kit, which has its own rules.
An auditor, Priya, receives a bundle with 2,500 records. Every link in the chain matches, and the last checkpoint's signature checks out against the public key inside the bundle.
- Why must every record be written in one fixed form before it is hashed and signed?
- Before she signs anything, Priya needs two things that do not come inside the bundle. Name them, and say where she could get each one.
- Priya gets both. The key matches, but her separately received checkpoint says 2,560 records, with a different last fingerprint. What does she conclude, and why could the bundle alone never have shown it?
- A colleague says: "Next time, just compare the record count. If the count matches and the seal is signed by the pinned key, that's enough." Why is it not enough? And what else must the bundle carry for the check to pass?
- Later the full bundle of 2,560 records arrives, and the check passes against the pinned key and the expected checkpoint. Sort these claims into proved and not proved:
- a. Records 1 to 2,560 are unchanged since they were signed.
- b. The refund amounts in the records are correct.
- c. The records were signed by whoever holds the secret key that matches the pinned public key.
- d. No record after the last checkpoint was left out.
- e. No record up to the checkpoint was removed, added or reordered.
- f. The warranty decisions were the right ones.
- g. Nothing went wrong in the system before each record was signed.
- Priya practises on the course's offline kit (
apps/sandbox400/). Its made-up project bundle's trust file says the expected checkpoint is "seq 41", and the kit's records start at seq 0. How many records does that checkpoint cover? If the kit prints "ACCEPT", has she run this module's check, and can she sign off on that alone? (No code needed: the prepared outputprepared/400P-b-verify-bundle.txtshows the result.)
Model answer
- A hash or a signature is computed over exact bytes, not meaning. The same record with its fields in a different order, or different spacing, gives different bytes, so an honest record could fail its check. RFC 8785 (JCS) sets out one fixed way to write JSON for this reason.
- A pinned public key: a copy of the signer's key received some other way, such as the fingerprint the security team registered when the key was made, kept in Priya's own records, or a list the owner published.
- An expected checkpoint: the record count and last fingerprint, received through her own channel, such as the nightly checkpoint the system sends to the audit team's mailbox.
- A pinned public key: a copy of the signer's key received some other way, such as the fingerprint the security team registered when the key was made, kept in Priya's own records, or a list the owner published.
- Sixty records are missing from the end. The 2,500 that remain still chain correctly, and whoever cut them could sign a new checkpoint for 2,500. Only a checkpoint received from somewhere the cutter could not touch shows the gap. Priya should say so, and nobody should rely on the affected records until the reason is found. She records the check as failed and does not guess what the missing records said.
- The owner holds the real key, so they could sign a different history of the same length: the count matches and the seal verifies, and only the last fingerprint (head hash) differs. So Priya compares both parts of her separately received checkpoint, the count and the head hash. And the bundle must carry a checkpoint for exactly that count and head, whose signature actually verifies under the pinned key, and the chain, recomputed from the start, must reach that head at that count. A key that merely matches is not a verified signature, and an older seal for fewer records does not cover the rest. No matching signed checkpoint, no pass.
- Proved: a, c, e. Not proved: b (a correct signature on a wrong number is still a wrong number), d (records after the last checkpoint, or never logged, are not covered), f (no integrity check shows a decision was right) and g (a signature proves nothing about what happened before signing: a bug, or an entry injected before signing, is signed along with everything else and verifies, as Horizon shows).
- 42 records, seq 0 to 41: the kit's checkpoint names the seq of the last record it covers, not a count. No, an ACCEPT there is not this module's check. The kit asks the same questions (pinned key, intact chain, a signed checkpoint matching the separately received seq and head), but its
VERIFY.mdstates a different construction: it signs every record, starts the chain from 64 zeros and hashes records its own way, so its fingerprints differ from ones made with this module's rules. Like this module's check, it rejects a bundle with no signed checkpoint or only an older one. And no sign-off on that alone: the kit's keys are public course test keys, so a pass shows how the check works, not who signed, and a person still writes and signs the bounded statement.
Exercise 3 (400.8-c)
Pack the box. You are packing the evidence bundle for Big Widget's made-up warranty model, for an outside auditor who has never seen the system and will check it offline. The draft folder holds:
- The record chain
- The signed nightly checkpoints
- The public key, and a note on where the security team publishes its fingerprint
policy-v7.yaml- The hash of
policy-v7.yaml - A crosswalk: each requirement the system must meet, linked to the records and files that show it was met, with what each entry was checked against and when
- VERIFY.md
- The known-issues log, with dealers' and staff names in it
- 50 chat transcripts between staff and the model, "so the auditor sees real use"
- A list of the 20 dealers whose claims were refused, with their contact details
For each item, write keep, remove or fix, with a one-line reason. Then:
- The bundle still needs a signed list of contents (the manifest). When do you make it, what does it list, and how is it signed?
- A colleague proposes that each receipt name the approver by staff number, "since that isn't a name". What should a receipt name instead, and what can the auditor then not tell from the bundle?
- Write one sentence for the final page of VERIFY.md that the auditor could sign, and one sentence it must never say.
Model answer
- Keep 1 and 2. The records themselves, in a form that shows tampering, and the checkpoints to check them against.
- Keep 3. The key checks signatures; the note tells the stranger how to pin a trusted copy from outside the bundle.
- Keep 4 and 5. Each record names the hash of the policy it refers to, so the auditor can confirm which version of the rules each record names, and that the file in the bundle is it. A matching hash does not show the system actually applied that policy; that needs separate evidence, such as an independent test of the gate against the policy.
- Keep 6. The crosswalk links each requirement to its evidence, dated, so the auditor can see what was checked against what.
- Keep 7. VERIFY.md lets the auditor check everything offline, with nothing from you but the bundle.
- Fix 8. Keep the known-issues log, because the auditor needs to know what you knew was wrong (in Horizon, the bug records existed but were not disclosed). Remove the names first: the bundle must never contain personal data.
- Remove 9. Transcripts are prompts and outputs. They can hold customer details and trade secrets, and they add nothing the auditor can verify. The auditor needs the right evidence, not the most.
- Remove 10. Personal data. The bundle travels to a stranger.
The manifest. Make it last, after every other file is final (so after removing 9 and 10, and after fixing 8). MANIFEST.json lists every other file and its hash; it does not list itself or its signature. Sign it with a packaging key, put the signature in a separate file (MANIFEST.sig), and pin the packaging key from outside the bundle, like the log key. It proves only that the bundle has not changed since packaging. Removing 9 and 10 does not change the record chain or its checkpoints, because those files were never in the log; only the manifest is rebuilt and signed again.
The approver. The receipt names the role, such as "warranty operations lead", and the id of the gate's key. A staff number that can be traced back to a person is personal data, so it is not a way round the rule. Which person held the role that day stays in the company's own access-controlled records. From the bundle alone, the auditor can tell that an approval by that role was recorded, but not which person approved, or that the approval really happened.
A good closing sentence is bounded to what was checked, for example: "Entries 1 to [n] are unchanged since signing by the key with fingerprint F, as checked on [date] against a key and checkpoint received from [channel]." A person writes and signs it; a script that prints "pass" is not a sign-off. It must never say "the system is compliant" or "the decisions were correct": no check on the records proves that.