2023-02-08 21:01:48 +00:00
|
|
|
#!/bin/bash
|
2017-07-03 03:01:04 +00:00
|
|
|
# Boot a USB installation
|
2017-04-29 17:40:34 +00:00
|
|
|
|
|
|
|
. /etc/functions
|
2018-12-06 23:24:28 +00:00
|
|
|
. /tmp/config
|
2017-04-29 17:40:34 +00:00
|
|
|
|
2023-02-20 16:01:17 +00:00
|
|
|
TRACE "Under /bin/usb-init"
|
2023-02-18 17:58:43 +00:00
|
|
|
|
2022-08-25 18:43:31 +00:00
|
|
|
if [ "$CONFIG_TPM" = "y" -o "$CONFIG_TPM2_TOOLS" = "y" ]; then
|
2017-12-05 08:29:07 +00:00
|
|
|
# Extend PCR4 as soon as possible
|
2022-08-25 18:43:31 +00:00
|
|
|
tpmr extend -ix 4 -ic usb
|
2017-12-05 08:29:07 +00:00
|
|
|
fi
|
2017-04-29 17:40:34 +00:00
|
|
|
|
2023-01-26 20:03:03 +00:00
|
|
|
media-scan usb
|
2017-07-08 20:59:37 +00:00
|
|
|
recovery "Something failed during USB boot"
|