Section 1.36

Assumption versus guarantee

Definition

An assumption is a condition that an argument about a system takes as true without establishing it. A guarantee is the property the argument establishes; it holds only when all the argument’s assumptions hold, so every guarantee has the form “if these assumptions hold, then this property holds”. The difference that matters is the source of support: a guarantee is earned inside the argument, by a mechanism or a proof, while each assumption needs support from outside it or must be stated as a limit of the claim.

The idea

A design document says: “the device keys remain secret”. Three different things may stand behind that sentence. A mechanism may enforce it: the keys live in a secure element §5.38, a separate chip that never releases them. Someone may have measured it: a debugger, a tool that reads a chip’s memory through a hardware port, tried to read the keys from one device in one configuration and got an error. Or it may simply be assumed, because the authors decided that attackers with physical access were outside their scope. A reader cannot tell which. If it is the third, and the devices are installed where anyone can open them, every guarantee built on secret keys, such as “only the server can issue commands”, silently stops applying.

A building is a fair picture. The guarantee is the building, and the assumptions are the ground it stands on. An inspector who checks the building’s design does not survey the ground; that is a separate job, and a perfect design on bad ground still falls. The picture stops in two places. An assumption can be turned into a guarantee by adding a mechanism and an argument for it, which makes that piece of ground part of the building, with new ground of its own underneath. And a measurement of the ground supports the assumption only at the places measured.

How it works

Write each claim so that its assumptions stay visible.

  1. State the guarantee precisely, including the attacker it concerns, as the threat model §1.2, the written description of what an attacker can do, defines that attacker.

  2. List every assumption the argument uses, including those about the attacker, the hardware, the compiler and the environment.

  3. Give each assumption a status.

    • Enforced: a named mechanism makes the assumption true in every execution that the model covers, and there is evidence that the mechanism is present, enabled and working. The assumption has become the guarantee of a smaller argument, which has assumptions of its own.

    • Measured: a test or measurement supports the assumption, but only for the device, configuration, inputs and attack attempts that were tried.

    • Assumed: accepted without support, usually as a decision about what the claim covers.

  4. Carry forward every assumption that is not enforced into the final statement of the guarantee.

  5. Check for circularity. No assumption may restate the guarantee. Assuming “no attacker can get a command accepted” in order to conclude “only the server can issue commands” proves nothing.

A measurement supports an assumption without proving it. Observing that a debugger cannot read the key in one configuration does not show that no physical attack can read it. Reading the source code and finding no line that prints the key does not show that no copy of the key exists elsewhere in memory. A guarantee must not quietly turn such limited observations into universal statements.

Worked example

A device accepts a command only if it carries a valid 128-bit tag from a MAC (message authentication code §5.7), a function that computes a short value from a secret key and the message. The guarantee: an attacker on the network gets a forged command accepted only with a tiny probability. The argument uses five assumptions.

Under these assumptions, take an attacker who makes 10610^{6} attempts per second for one year. One year is 365×24×3600=31,536,000365 \times 24 \times 3600 = 31{,}536{,}000 seconds, so the attacker makes 106×31,536,000≈3.15×101310^{6} \times 31{,}536{,}000 \approx 3.15 \times 10^{13} attempts. The probability that any attempt succeeds is at most 3.15×1013×2−128≈3.15×1013×2.94×10−39≈9.3×10−263.15 \times 10^{13} \times 2^{-128} \approx 3.15 \times 10^{13} \times 2.94 \times 10^{-39} \approx 9.3 \times 10^{-26}. That bound is the guarantee.

Now give each assumption its status. A2A_2 is a standard cryptographic assumption, supported by years of public analysis of the algorithm §14.1. A3A_3 and A4A_4 are enforced by the device’s code and can be supported by inspection and tests. A1A_1 depends on the hardware: if the key sits in readable flash memory §6.6 and the chip’s debug port, a hardware connection through which a debugger reads memory, is open, anyone who holds a device can read the key, and A5A_5 does not describe that attacker. That attacker computes a valid tag on the first attempt, with probability 1. The MAC is not broken, and the arithmetic above is still correct; it no longer applies, because A1A_1 and A5A_5 are false for that attacker.

Timing claims work the same way. Suppose a handler’s own instructions take at most 1 ms, and the handler makes at most 20 calls to helper functions §2.19, each assumed to return within 50 microseconds, which is 0.05 ms. The guarantee is a total of at most 1+20×0.05=21 + 20 \times 0.05 = 2 ms. If one helper waits 10 ms for a busy radio, the assumption fails for that run. The bound on the handler’s own instructions is still right, but the 2 ms total no longer follows: that run takes at least 10 ms.

Stated precisely

A guarantee is a conditional statement A1∧A2∧…∧An⇒G,A_1 \wedge A_2 \wedge \dots \wedge A_n \Rightarrow G, where A1,…,AnA_1, \dots, A_n are the assumptions, GG is the guaranteed property, ∧\wedge means “and” and ⇒\Rightarrow means “implies”. An argument, whether a proof or a mechanism together with its analysis, establishes the implication, not GG on its own. GG follows for a deployed system only when every AiA_i is true of that system.

If some AiA_i is false, the implication stays true but says nothing about GG: GG may hold or may fail. A counterexample to an assumption therefore does not refute the theorem; it shows that the theorem does not apply to that case. If an assumption A1A_1 is itself established by a second argument B1∧…∧Bm⇒A1B_1 \wedge \dots \wedge B_m \Rightarrow A_1, the two combine into one guarantee whose assumptions are B1,…,Bm,A2,…,AnB_1, \dots, B_m, A_2, \dots, A_n. Combining arguments never removes assumptions; it replaces some of them with others.

For a property such as the secrecy of firmware or of a key, three statuses are possible, each with an exact meaning.

Limits and common mistakes

Having assumptions is not a defect; every useful guarantee has some. The defects are hiding them, choosing ones that are false for the actual deployment, and dropping them when the guarantee is reported.

Phrases such as “under reasonable assumptions” or “given a secure setup” state no assumption. Name each one.

An assumption that restates the desired conclusion makes the argument circular, and the argument then proves nothing.

Passing tests are not a guarantee. If 1,000 tests found no failure, and each test checked the property correctly, the property held in those 1,000 runs. That does not show that it holds for all inputs.

Unstated assumptions do the most damage, because nobody checks them. Common ones: the clock never runs backwards, the compiler keeps the security check, the hardware behaves as its datasheet says, and only one program writes to a given piece of memory.

Fewer and weaker assumptions make a stronger guarantee, because the guarantee then applies in more situations. A result that needs only “the attacker cannot read the key” is stronger than one that also needs “the attacker cannot send messages”.

The threat model is itself a set of assumptions about the attacker. Leaving an attacker out of the model does not make that attacker go away.

Questions answered

Is firmware secrecy a measured fact, an enforced property, or an assumption?

Firmware secrecy is usually an assumption. It is an enforced property only when a named mechanism keeps the firmware, and the keys stored with it, unreadable to the attackers being considered, and there is evidence that this mechanism is present, switched on and working. It is a measured fact only for the exact device, configuration and read attempts that were actually tried. Firmware secrecy here means that an attacker cannot read the program stored on a device, or any secret, such as a key, stored with that program.

The three statuses differ in scope. An assumption, such as “attackers have no physical access to the device”, is accepted without support, and every guarantee that depends on it must state it. An enforced property, such as a chip’s readout protection §16.5, a setting that makes the hardware refuse debugger reads, holds in every execution that the hardware’s documented behavior covers, but it still assumes that the hardware works as documented and that nobody attacks it outside that model, for example by disturbing its supply voltage. A measured fact, such as “a debugger (a tool that reads a chip’s memory through a hardware port) tried to read this device and got an error”, covers only what was tried. A correct report names which of the three applies, says which attackers and interfaces it covers, and keeps every guarantee that rests on secrecy conditional on it: “if the key stays secret, then …”.

Related entries: System model (§1.1), Mechanism versus evidence (§1.37), Security claim scope (§1.45), Threat model (§1.2), Physical versus logical access (§1.32).