Skip to content

Commit 02c276c

Browse files
committed
Add doc for the new feature.
1 parent 9bb28cd commit 02c276c

File tree

4 files changed

+45
-3
lines changed

4 files changed

+45
-3
lines changed

docs/imagecustomizer/api/configuration/injectFilesConfig.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,12 @@ injectFiles:
4242
destination: /EFI/systemd/systemd-bootx64.efi
4343
source: ./systemd-bootx64.signed.efi
4444
unsignedSource: ./systemd-bootx64.efi
45+
- partition:
46+
idType: part-uuid
47+
id: 5c0a7f80-0f9f-48f6-8bb1-d622022aaf24
48+
destination: /root.hash.sig
49+
source: ./root.hash.sig
50+
unsignedSource: ./root.hash
4551
previewFeatures:
4652
- inject-files
4753
```

docs/imagecustomizer/api/configuration/output.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ output:
3939
- ukis
4040
- shim
4141
- systemd-boot
42+
- verity-hash
4243
path: ./output
4344
previewFeatures:
4445
- output-artifacts

docs/imagecustomizer/api/configuration/outputArtifacts.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ You must enable this feature by specifying `output-artifacts` in the
1010
[previewFeatures](./config.md#previewfeatures-string) API.
1111

1212
Specifies the configuration for the output directory containing the generated
13-
artifacts, including UKI PE images, shim and systemd-boot.
13+
artifacts, including UKI PE images, shim, systemd-boot, and Verity hash files.
1414

15-
After Prism outputs the selected artifacts, it will also generate a helper
15+
After Image Customizer outputs the selected artifacts, it will also generate a helper
1616
configuration file named `inject-files.yaml` under the same directory of output
1717
artifacts. This file can later be used to inject signed artifacts back into an
1818
image. For more details, see the [`injectFilesConfig`](./injectFilesConfig.md)
@@ -27,6 +27,7 @@ output:
2727
- ukis
2828
- shim
2929
- systemd-boot
30+
- verity-hash
3031
path: ./output
3132
previewFeatures:
3233
- output-artifacts
@@ -38,7 +39,7 @@ Added in v0.14.
3839
3940
Required.
4041
41-
Specifies the directory path where Prism will output the selected artifacts.
42+
Specifies the directory path where Image Customizer will output the selected artifacts.
4243
4344
Added in v0.14.
4445
@@ -53,6 +54,7 @@ Supported values:
5354
- `ukis` – UKI PE images (`vmlinuz-<version>.efi`).
5455
- `shim` – Bootloader shim executable (`boot<arch>.efi`).
5556
- `systemd-boot` – Systemd-boot executable (`systemd-boot<arch>.efi`).
57+
- `verity-hash` – Verity hash files associated with dm-verity protected partitions.
5658

5759
The `output.artifacts` field must be used with the `output-artifacts` enabled in `previewFeatures`.
5860

@@ -61,4 +63,10 @@ These artifacts are generated in an unsigned format and must be signed externall
6163
Supported architectures for shim and systemd-boot include x64 and arm64,
6264
reflected in the `<arch>` portion of the filenames.
6365

66+
The `verity-hash` artifact will only be output if the corresponding Verity entry
67+
defines a `hashSignaturePath`. If the `hashSignaturePath` is not configured,
68+
Image Customizer will skip generating the hash file for that Verity device. For
69+
more details, see the [`verity`](./verity.md) documentation.
70+
6471
Added in v0.14.
72+
`verity-hash` added in v0.16.

docs/imagecustomizer/api/configuration/verity.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,3 +250,30 @@ Supported values:
250250
Default value: `io-error`.
251251

252252
Added in v0.7.
253+
254+
## hashSignaturePath [string]
255+
256+
Optional.
257+
258+
Specifies the path where the signed verity hash file should be injected into the
259+
image. This path is typically used by the `systemd-veritysetup` module to verify
260+
the verity hash against a signature at boot time.
261+
262+
- This path **must be located under the boot partition** for the current
263+
version. For example, if the boot partition is mounted at `/boot`, then
264+
`hashSignaturePath: /boot/root.hash.sig` will result in a destination of
265+
`/root.hash.sig` relative to the boot partition during injection.
266+
267+
- When this field is specified, Prism will output the corresponding unsigned
268+
hash file (`verity-hash`) as an artifact if the
269+
[`output.artifacts`](./outputArtifacts.md) API is configured.
270+
271+
- The generated `inject-files.yaml` will include an entry to inject the signed
272+
hash file to the specified path inside the boot partition.
273+
274+
If `hashSignaturePath` is not configured for a given Verity entry, the verity
275+
hash file will not be output even if `verity-hash` is listed in the
276+
`output.artifacts.items`. Only Verity entries with `hashSignaturePath` defined
277+
will produce a `verity-hash` artifact.
278+
279+
Added in v0.16.

0 commit comments

Comments
 (0)