1.
As part of the offline image encryption process the CST will first generate a Data Encryption Key (DEK). The DEK is the key that will be used to actually encrypt the image. The problem then is how do we protect the DEK since it is required on the IC to decrypt the image at boot time? The solution is to create a DEK blob. The DEK blob is created by CAAM HW (using a proprietary protocol) that encrypts the DEK using the OTP master key. The OTP master key an AES-256 key burned to fuses by FSL before the IC is shipped. The OTPMK is unique per chip and only CAAM can access the key. This allows CAAM to encrypt and decrypt secrets for that chip. So, once that DEK blob is created only CAAM can decrypt it. To further add to the security of the DEK, the blob is decrypted to a partition of secure memory that only CAAM can access. After the DEK blob is created software will never have access to the DEK – not even the ROM. Section 5.6.5 of the i.MX6 Security Reference Manual has a full description on CAAM blobs.
https://www.freescale.com/webapp/Download?colCode=IMX6DQ6SDLSRM&appType=moderatedWithoutFAE
The ROM will first load the encrypted image to DDR and then as part of the CSF processing (i.e. an Install Key and corresponding Authenticate Image command) will decrypt the image in place. CAAM HW is used to perform the actual AES operations. Note in this case encrypted boot does not provide confidentiality but does provide anti-cloning protection of the flash image. Device secrets can be wrapped in blobs similar to the DEK blob but this is currently outside the scope of HAB.
2.
Encrypted boot has been prototyped and support has been included in the i.MX6 platform SDK. The code can be found at sdk/drvers/caam.
Keep in mind that in order to generate a blob with the CAAM OTPMK a secure boot with HAB in closed config (see the notes for slide 4),
otherwise in open config the blob will be created using the known CAAM default master key. The platform SDK code is useful for generating
a blob for a single chip but is not useful in a production environment. The platform SDK code:
2.1. Configures CAAM appropriately in order to generate a key blob
2.2. Writes a fixed data encryption key (DEK) to a CAAM memory partition - same partition used by HAB
2.3. Configures the CAAM memory partition as CAAM read only
2.4. Generates the blob with CAAM
2.5. Re-allocate CAAM memory parition - erases original DEK
2.6. Decapsultates the blob to obtain the original DEK in CAAM read only memory partition
2.7. Perform a self test with the decapsulated DEK to ensure the DEK was properly restored
For a production environment steps 1-4 would be done by the MfgTool. The remainder of the steps would be performed by HAB when i.MX6 boots.
3.
As for MFG :
"We don't provide native key blob creation support in the Mfg Tool for encrypted boot.
We do have a process to create it, but not in a seamless way."