@@ -994,60 +994,60 @@ repo](https://github.com/theupdateframework/specification/issues).
994
994
995
995
## ** 5. Detailed Workflows**
996
996
997
- * ** 5.1. The client application**
997
+ ** The client application**
998
998
999
999
0. **Load the trusted root metadata file.** We assume that a good, trusted
1000
- copy of this file was shipped with the package manager / software updater
1001
- using an out-of-band process.
1002
-
1003
- 0.1. Note that the expiration of the trusted root metadata file does not
1004
- matter, because we will attempt to update it in the next step.
1000
+ copy of this file was shipped with the package manager or software updater
1001
+ using an out-of-band process. Note that the expiration of the trusted root
1002
+ metadata file does not matter, because we will attempt to update it in the
1003
+ next step.
1005
1004
1006
1005
1. **Update the root metadata file.** Since it may now be signed using
1007
1006
entirely different keys, the client must somehow be able to establish a
1008
1007
trusted line of continuity to the latest set of keys (see Section 6.1). To
1009
1008
do so, the client MUST download intermediate root metadata files, until the
1010
1009
latest available one is reached.
1011
1010
1012
- 1.1. Let N denote the version number of the trusted root metadata file.
1013
-
1014
- 1.2. ** Try downloading version N+1 of the root metadata file** , up to some
1015
- X number of bytes (because the size is unknown). The value for X is set by
1016
- the authors of the application using TUF. For example, X may be tens of
1017
- kilobytes. The filename used to download the root metadata file is of the
1018
- fixed form VERSION_NUMBER.FILENAME.EXT (e.g., 42.root.json). If this file
1019
- is not available, then go to step 1.8.
1020
-
1021
- 1.3. ** Check signatures.** Version N+1 of the root metadata file MUST have
1022
- been signed by: (1) a threshold of keys specified in the trusted root
1023
- metadata file (version N), and (2) a threshold of keys specified in the
1024
- new root metadata file being validated (version N+1).
1025
-
1026
- 1.4. ** Check for a rollback attack.** The version number of the trusted
1027
- root metadata file (version N) must be less than or equal to the version
1028
- number of the new root metadata file (version N+1). Effectively, this means
1029
- checking that the version number signed in the new root metadata file is
1030
- indeed N+1.
1031
-
1032
- 1.5. Note that the expiration of the new (intermediate) root metadata
1033
- file does not matter yet, because we will check for it in step 1.8.
1034
-
1035
- 1.6. Set the trusted root metadata file to the new root metadata file.
1036
-
1037
- 1.7. Repeat steps 1.1 to 1.7.
1038
-
1039
- 1.8. ** Check for a freeze attack.** The latest known time should be lower
1040
- than the expiration timestamp in the trusted root metadata file.
1041
-
1042
- 1.9. ** If the timestamp and / or snapshot keys have been rotated, then
1043
- delete the trusted timestamp and snapshot metadata files.** This is done
1044
- in order to recover from fast-forward attacks after the repository has been
1045
- compromised and recovered. A _ fast-forward attack_ happens when attackers
1046
- arbitrarily increase the version numbers of: (1) the timestamp metadata,
1047
- (2) the snapshot metadata, and / or (3) the targets, or a delegated
1048
- targets, metadata file in the snapshot metadata. Please see [ the Mercury
1049
- paper] ( https://ssl.engineering.nyu.edu/papers/kuppusamy-mercury-usenix-2017.pdf )
1050
- for more details.
1011
+ 1.1. Let N denote the version number of the trusted root metadata file.
1012
+
1013
+ 1.2. **Try downloading version N+1 of the root metadata file**, up to
1014
+ some X number of bytes (because the size is unknown). The value for X is
1015
+ set by the authors of the application using TUF. For example, X may be
1016
+ tens of kilobytes. The filename used to download the root metadata file
1017
+ is of the fixed form VERSION_NUMBER.FILENAME.EXT (e.g., 42.root.json). If
1018
+ this file is not available, then go to step 1.8.
1019
+
1020
+ 1.3. **Check signatures.** Version N+1 of the root metadata file MUST
1021
+ have been signed by: (1) a threshold of keys specified in the trusted
1022
+ root metadata file (version N), and (2) a threshold of keys specified in
1023
+ the new root metadata file being validated (version N+1).
1024
+
1025
+ 1.4. **Check for a rollback attack.** The version number of the trusted
1026
+ root metadata file (version N) must be less than or equal to the version
1027
+ number of the new root metadata file (version N+1). Effectively, this
1028
+ means checking that the version number signed in the new root metadata
1029
+ file is indeed N+1.
1030
+
1031
+ 1.5. Note that the expiration of the new (intermediate) root metadata
1032
+ file does not matter yet, because we will check for it in step 1.8.
1033
+
1034
+ 1.6. Set the trusted root metadata file to the new root metadata file.
1035
+
1036
+ 1.7. Repeat steps 1.1 to 1.7.
1037
+
1038
+ 1.8. **Check for a freeze attack.** The latest known time should be lower
1039
+ than the expiration timestamp in the trusted root metadata file.
1040
+
1041
+ 1.9. **If the timestamp and / or snapshot keys have been rotated, then
1042
+ delete the trusted timestamp and snapshot metadata files.** This is done
1043
+ in order to recover from fast-forward attacks after the repository has
1044
+ been compromised and recovered. A _fast-forward attack_ happens when
1045
+ attackers arbitrarily increase the version numbers of: (1) the timestamp
1046
+ metadata, (2) the snapshot metadata, and / or (3) the targets, or a
1047
+ delegated targets, metadata file in the snapshot metadata. Please see
1048
+ [the Mercury
1049
+ paper](https://ssl.engineering.nyu.edu/papers/kuppusamy-mercury-usenix-2017.pdf)
1050
+ for more details.
1051
1051
1052
1052
2. **Download the timestamp metadata file**, up to Y number of bytes
1053
1053
(because the size is unknown.) The value for Y is set by the authors of the
0 commit comments