Hi All,
This is my first topic post.
I am in the process of enabling secureboot in my Jetson NVIDIA Xavier NX production kit with eMMC.
(I have built the OS, flashes and runs fine with no secureboot.)
I checked the given links at the end of the post. However, not limited to.
I just want to be sure that I do not brick my only NX.
And I understand each and every step before getting my hands dirty.
Hence, seeking confirmation/review whether the mentioned steps will surely help me achieve secure boot and consecutive signed flashes.
Note: Keeping the argument --test
with odmfuse.sh
so that no one bricks their kits in a hurry.
kernel version: 4.9.253
l4t version: 32.6.1
Steps
-
read fuse
$ sudo ./odmfuseread.sh -i 0x19 nvcb_emmc
-
Generated rsa_priv.pem as mentioned in the ‘security’ page. (unable to link here)
-
Created files sbk.xml, kek2.xml and kek256.xml as random 32, 32 and 64 digit big-endian hexadecimal values respectively.
-
odm test fuse and all key burn
$ sudo BOARDID=3668 FAB=301 BOARDSKU=0003 BOARDREV=B.0 ./odmfuse.sh --test --noburn -i 0x19 --auth SBKPKC -p -k rsa_priv.pem -S sbk.xml --KEK2 kek2.xml --KEK256 kek256.xml nvcb_emmc
-
Burn the fuses
$ tar xpvf fuseblob.tbz2
$ cd bootloader/
$ sudo ./fusecmd.sh -
Flash with security
$ cd bootloader
$ sudo bash ./flashcmd.txt -
Never loose the keys. Keep the keys handy for next flash. Or I will never be able to flash the same NX again.
-
While next new image to be flashed.
$ sudo ./flash.sh –-no-flash --sign -u rsa_priv.pem -v sbk.xml --user_key kek2.xml nvcb_emmc mmcblk0p1
-
Flash with security
$ cd bootloader
$ sudo bash ./flashcmd.txt -
Further if I need to also sign and encrypt Kernel, Kernel-DTB, Initrd, and extlinux.conf Files
$ ./l4t_sign_image.sh --file ./kernel/nvidia-l4t-kernel_4.9.253-tegra-32.6.1-20210726122859_arm64.deb --chip 0x19 --key rsa_priv.pem --encrypt_key kek2.xml --type deb --minratchet_config bootloader/t186ref/BCT/tegra194-mb1-bct-ratchet-p3668.cfg
Note: I do not find the ratchet cfg file; bootloader/t186ref/BCT/tegra194-mb1-bct-ratchet-p3668.cfg.
I follow the same for all the the files I want to encrypt. -
Flash with security
$ cd bootloader
$ sudo bash ./flashcmd.txt
Queries:
- Which files are recommended to encrypt to assure full security as per mentions in the step of signing and encrypting the kernel and all.
- In the same step I did not see the use of the kek256.xml file’s use.
- I do not find the ratchet cfg file in bootloader/t186ref/BCT/tegra194-mb1-bct-ratchet-p3668.cfg file.
- Is the list of steps are complete for full security with full encryption?
Thank you for helping me review the steps.