1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-23 02:04:32 +03:00

dissect: fix root hash signature autodiscovery

The root hash signature is auto discovered only if the root hash was specified
manually. Ensure that an auto discovered root hash is also enough.
This commit is contained in:
Luca Boccassi 2021-01-10 15:06:04 +00:00 committed by Lennart Poettering
parent 91737e1453
commit 90f989861e

View File

@ -2123,7 +2123,7 @@ int verity_settings_load(
}
}
if (verity->root_hash && !verity->root_hash_sig) {
if ((root_hash || verity->root_hash) && !verity->root_hash_sig) {
if (root_hash_sig_path) {
r = read_full_file(root_hash_sig_path, (char**) &root_hash_sig, &root_hash_sig_size);
if (r < 0 && r != -ENOENT)