dissect: wrap verity settings in new VeritySettings structure

System Internals / systemd - Lennart Poettering [poettering.net] - 17 September 2020 11:36 UTC

Just some refactoring: let's place the various verity related parameters in a common structure, and pass that around instead of the individual parameters.

Also, let's load the PKCS#7 signature data when finding metadata right-away, instead of delaying this until we need it. In all cases we call this there's not much time difference between the metdata finding and the loading, hence this simplifies things and makes sure root hash data and its signature is now always acquired together.

89e62e0bd3 dissect: wrap verity settings in new VeritySettings structure
src/core/namespace.c | 169 ++++++++++-----
src/dissect/dissect.c | 103 ++++-----
src/gpt-auto-generator/gpt-auto-generator.c | 2 +-
src/nspawn/nspawn.c | 87 ++++----
src/portable/portable.c | 2 +-
src/shared/dissect-image.c | 315 ++++++++++++++--------------
src/shared/dissect-image.h | 26 ++-
src/shared/machine-image.c | 2 +-
8 files changed, 386 insertions(+), 320 deletions(-)

Upstream: github.com


  • Share