Skip to content

Commit

Permalink
Make it possible to report headers of which LUKSes to be unlocked via…
Browse files Browse the repository at this point in the history
… TPM change.
  • Loading branch information
root-hardenedvault committed Jan 20, 2022
1 parent b4b0bc4 commit ed1c23a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions initrd/bin/kexec-insert-key
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ tpm extend -ix 4 -ic generic \

# Check to continue
if [ "$unseal_failed" = "y" ]; then
diff "$(dirname $INITRD)/kexec_lukshdr_hash.txt" /tmp/luksDump.txt \
&& echo "Headers of LUKSes to be unlocked via TPM do not change."
confirm_boot="n"
read \
-n 1 \
Expand Down
3 changes: 3 additions & 0 deletions initrd/bin/kexec-seal-key
Original file line number Diff line number Diff line change
Expand Up @@ -152,3 +152,6 @@ fi

shred -n 10 -z -u "$TPM_SEALED" 2> /dev/null \
|| warn "Failed to delete the sealed secret - continuing"

cp /tmp/luksDump.txt "$paramsdir/kexec_lukshdr_hash.txt" \
|| warn "Failed to have hashes of LUKS header - continuing"

0 comments on commit ed1c23a

Please sign in to comment.