Configuration
- Stock JetPack 5.1.2 / L4T r35.4.1 with this NVIDIA-vetted hotfix
- Two NVIDIA Xavier AGX DevKits (
conf="jetson-agx-xavier-devkit"
)- One is stock and unfused, all fuses are as per factory defaults
- One is fused into production mode with SBK, PKC, and KEK0/1/2
Observations
Both fused and unfused devices can be flashed to internal
storage and booted successfully using both the traditional flash.sh
and l4t_initrd_flash.sh
.
Both fused and unfused devices can be flashed to internal
storage using eitherflash.sh
orl4t_initrd_flash.sh
when ROOTFS_AB=1
and ROOTFS_ENC=1
.
However, neither fused or unfused devices can boot after flashing, if ROOTFS_AB=1
and ROOTFS_ENC=1
.
From the console boot log, both fused and unfused give the same error:
ERROR: fail to unlock the encrypted dev /dev/mmcblk0p3.
Setup Details
We have followed the L4T r35.4.1 documentation closely and have no customizations.
Our flashing setup shell scripts use the following commands:
boot_keys_args=(
-u "${boot_keys}/pkc.private" # for unfused modules, comment this line out
-v "${boot_keys}/sbk.key" # for unfused modules, comment this line out
)
echo "${ekb_key}" > "ekb.key"
conf="jetson-agx-xavier-devkit"
ROOTFS_AB=1 ROOTFS_ENC=1 \
sudo --preserve-env=ROOTFS_AB,ROOTFS_ENC \
bash -x \
flash.sh \
-i "ekb.key" \
"${boot_keys_args[@]}" \
--uefi-keys "uefi_keys/uefi_keys.conf" \
"${conf}" internal
I emphasize that the only difference in the flashing setup is presence or absence of boot_keys_args
in the above.
Further Investigation
To help track this down, we rebuilt l4t_initrd.img
to introduce additional logging. Note that no functionality was changed, only extra logging was added.
Note that all keys in any logging output herein are insecure and are safe for public disclosure.
- fused-console.log (159.3 KB)
- fused-flash.log (1.4 MB)
- unfused-console.log (86.8 KB)
- unfused-flash.log (1.4 MB)
From the log files:
fused initrd log:
nvluks-srv-app -u -c '6f1f2487-2a44-4682-adaa-f06ab112d966' -> 'TEEC_InvokeCommand failed 0xffff0001 origin 0x4'
unfused initrd log:
nvluks-srv-app -u -c '9c448cf0-32a7-4283-85e6-628a94af083b' -> 'd4024a369b1a0dcf92f8a981f1053885'
So d4024a...
is the LUKS password for filesystem UUID 9c448cf0...
However:
tools/disk_encryption/gen_luks_passphrase.py -k ekb.key -u -e 0x8[redacted]0 -c 9c448cf0-32a7-4283-85e6-628a94af083b -> d3dbc7bfd1f960e57e5b94ba3db6adde
… which is … a different password, and incorrect: d4024a...
is incorrect, d3dbc7...
is correct. This has been verified by manually luks
-mounting system_root_encrypted.img.raw
.
The only difference is fused vs unfused - everything else is 100% identical.
Neither can unlock the luks partition, but for different reasons!