dissect/nspawn: add support for dm-verity root hash signature

Since cryptsetup 2.3.0 a new API to verify dm-verity volumes by a
pkcs7 signature, with the public key in the kernel keyring,
is available. Use it if libcryptsetup supports it.
This commit is contained in:
Luca Boccassi
2020-06-25 08:45:21 +01:00
parent 035e8e50d7
commit c2923fdcd7
9 changed files with 176 additions and 26 deletions
+5 -1
View File
@@ -71,7 +71,7 @@ _systemd_nspawn() {
--pivot-root --property --private-users --network-namespace-path --network-ipvlan
--network-veth-extra --network-zone -p --port --system-call-filter --overlay --overlay-ro
--settings --rlimit --hostname --no-new-privileges --oom-score-adjust --cpu-affinity
--resolv-conf --timezone'
--resolv-conf --timezone --root-hash-sig'
)
_init_completion || return
@@ -183,6 +183,10 @@ _systemd_nspawn() {
--timezone)
comps=$( systemd-nspawn --timezone=help 2>/dev/null )
;;
--root-hash-sig)
compopt -o nospace
comps=$( compgen -A file -- "$cur" )
;;
esac
COMPREPLY=( $(compgen -W '$comps' -- "$cur") )
return 0