Skip to content

Commit 6f6b031

Browse files
authored
Merge pull request #15 from MarkLodato/requirements
Add "design requirements" section.
2 parents 6be03cf + ffbcecd commit 6f6b031

File tree

1 file changed

+28
-2
lines changed

1 file changed

+28
-2
lines changed

specification.md

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,33 @@ do so in the future.
211211
Verifiers can differentiate between the old and new wrapper format by detecting
212212
the presence of the `payload` field vs `signed` field.
213213

214-
## Motivation
214+
## Design considerations
215+
216+
### Design requirements
217+
218+
The signature scheme:
219+
220+
* MUST reduce the possibility of a client misinterpreting the payload (e.g.
221+
interpreting a JSON message as protobuf)
222+
* MUST support arbitrary payload types (e.g. not just JSON)
223+
* MUST support arbitrary crypto primitives, libraries, and key management
224+
systems (e.g. Tink vs openssl, Google KMS vs Amazon KMS)
225+
* SHOULD avoid depending on canonicalization for security
226+
* SHOULD NOT require unnecessary encoding (e.g. base64)
227+
* SHOULD NOT require the verifier to parse the payload before verifying
228+
229+
The single-message data structure / file format:
230+
231+
* MUST include both message and signature(s)
232+
* NOTE: Detached signatures are supported by having the included message
233+
contain a cryptographic hash of the external data.
234+
* MUST support multiple signatures in one structure / file
235+
* SHOULD discourage users from reading the payload without verifying the
236+
signatures
237+
* SHOULD be easy to parse using common libraries (e.g. JSON)
238+
* SHOULD support a hint indicating what signing key was used
239+
240+
### Motivation
215241

216242
There are two concerns with the current [in-toto]/[TUF] signature wrapper.
217243

@@ -245,7 +271,7 @@ such a vulnerability. The signature scheme should be resilient against these
245271
classes of attacks. See [example attack](hypothetical_signature_attack.ipynb)
246272
for more details.
247273

248-
## Reasoning
274+
### Reasoning
249275

250276
Our goal was to create a signature wrapper that is as simple and foolproof as
251277
possible. Alternatives such as [JWS] are extremely complex and error-prone,

0 commit comments

Comments
 (0)