gui-init: warn the user when sealing measurements through TOTP/HOTP requires TPM reset

This commit is contained in:
Thierry Laurion 2023-01-19 14:58:21 -05:00
parent f2ba6679ca
commit e00280e663
No known key found for this signature in database
GPG Key ID: E7B4A71658E36A93

View File

@ -149,7 +149,7 @@ prompt_update_checksums()
generate_totp_htop()
{
echo "Scan the QR code to add the new TOTP secret"
/bin/seal-totp "$BOARD_NAME"
if /bin/seal-totp "$BOARD_NAME"; then
if [ -x /bin/hotp_verification ]; then
echo "Once you have scanned the QR code, hit Enter to configure your HOTP USB Security Dongle (e.g. Librem Key or Nitrokey)"
read
@ -160,6 +160,9 @@ generate_totp_htop()
fi
# clear screen
printf "\033c"
else
warn "Sealing of measurements inside of TPM failed. You might want to take ownership of TPM by resetting it."
fi
}
update_totp()