here’s preparation, it’s cryptsetup utility to create encrypted rootfs for image flashing. please have $ sudo apt-get install cryptsetup installed.
please also check Tool for EKB Generation, you must re-generate EKS image by adding your encryption key.
please see-also Topic 270934 for disk encryption verification with a custom key.
Thanks for your response! I successfully enabled my device with both AB rootfs and disk encryption. I had to make a few adjustments, but the instructions from the topic you suggested were helpful and closely related to my issue. Thanks again!
Hi alex,
I used example.sh from the optee source file to generate my keys and eks_t234.img.
OPTEE PATH: ~/Linux_for_Tegra/source/public/optee/samples/hwkey-agent/host/tool/gen_ekb/
Then, copy the sym2_t324.key to the BSP PATH/Linux_for_Tegra/
Very strange. I’ve followed step by step your commands on Orin AGX(not included ROOTFS_AB=1), it still fails. Can you post output of hexdump -C -n 4 -s 0x24 eks_t234.img. I’m suspecting some issues with cryptsetup (or OPTEE package) as mine output is
Hi Alex,
If you run the example.sh it will overwrite the generated eks_t234image every time. so as the keys will update as well.
Check your commands for the Orin AGX adaptation. The commands I shared were for Jetson Orin NX.
It’s not about type of Orin, but creating eks image. I’ve tried OPTEE package from Jetpack 35.4.1 and it has “4 magical bytes” (EEKB)
00000024 45 45 4b 42 |EEKB|
00000028
As you can see, my last reply doesn’t match with this, so I asked you to execute this command to confirm, that this is problem of my machine, but not package
hi,
I have not said to check your commands for viewing the image content.
Anyway, -n 4 will read only 4 bytes of the file. and I am getting the same values each time for my image.
I think you didn’t understand what I meant. I was reffering to this topic Jetson Orin Nano Custom Key Encryption - #8 by JerryChang
That’s why I asked you to execute this commands. I’ve reinstalled the OPTEE package so I need to know if it is still corrupted or not
��NOTICE: BL31: v2.8(release):e12e3fa93
NOTICE: BL31: Built : 17:14:28, Jan 7 2025
I/TC:
I/TC: Non-secure external DT found
I/TC: OP-TEE version: 4.2 (gcc version 11.3.0 (Buildroot 2022.08)) #2 Wed Jan 8 01:24:03 UTC 2025 aarch64
I/TC: WARNING: This OP-TEE configuration might be insecure!
I/TC: WARNING: Please check https://optee.readthedocs.io/en/latest/architecture/porting_guidelines.html
I/TC: Primary CPU initializing
I/TC: Test OEM keys are being used. This is insecure for shipping products!
E/TC:00 00 ekb_extraction_process:404 Tried all EKB_RKs but still can't extract the EKB image.
E/TC:00 00 jetson_user_key_pta_init:1154 jetson_user_key_pta_init: Failed (ffff000f).
E/TC:00 00 call_initcalls:43 Initcall __text_start + 0x001ad380 failed
I/TC: fTPM ID is not enabled.
I/TC: ftpm-helper PTA: fTPM DT or EKB is not available. fTPM provisioning is not supported.
I/TC: Primary CPU switching to normal world boot
��
Jetson UEFI firmware (version 36.4.3-gcid-38968081 built on 2025-01-08T01:18:20+00:00)
Algorithm is the same, but results is non-bootable devices both Orin AGX and Orin NX