<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>i.MX ProcessorsのトピックRe: Secure boot imx6 Invalid IVT structure</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620566#M203116</link>
    <description>&lt;P&gt;Hi Druvit,&lt;/P&gt;&lt;P&gt;thanks for response.&lt;/P&gt;&lt;P&gt;Yes, i have added now the 0x1000 padded bytes at end of zImage and didn't get any hab error events.&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Blocks = 0x12000000 0x0 0x00933368 "vmlinuz-pad-ivt.bin"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;0x00933368 = size_of_pad_ivt_img.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Used hab_auth_img &amp;lt;load_address&amp;gt; &amp;lt;signed_img_size&amp;gt; &amp;lt;ivt_offset&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;signed_img_size = padded_img+ivt+csf .&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;U-Boot &amp;gt; hab_auth_img 0x12000000 0x009342a8 0x00933348&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;hab fuse not enabled&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Authenticate image from DDR location 0x12000000...&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Secure boot disabled&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;HAB Configuration: 0xf0, HAB State: 0x66&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;--------- HAB Event 1 -----------------&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;event data:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x01&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;STS = HAB_WARNING (0x69)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;RSN = HAB_ENG_FAIL (0x30)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;CTX = HAB_CTX_ENTRY (0xE1)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;ENG = HAB_ENG_CAAM (0x1D)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;I have signed dtb and initrd img also, and checked all hab status of all images, But i am getting above warning in all hab but not getting any error.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;1) How to get rid of this warning ?&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;2) While botting i am still getting the&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Authenticate image from DDR location 0x12000000... bad magic magic=0x0 length=0xa000 version=0xe1 bad length magic=0x0 length=0xa000 version=0xe1 bad version magic=0x0 length=0xa000 version=0xe1 Error: Invalid IVT structure Allowed IVT structure: IVT HDR = 0x4X2000D1&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Using u-boot (2021) kernel(5.10).&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Please help me here on this issue/warning.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Regards,&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Rakesh&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 23 Mar 2023 07:19:19 GMT</pubDate>
    <dc:creator>rakesh3</dc:creator>
    <dc:date>2023-03-23T07:19:19Z</dc:date>
    <item>
      <title>Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1618944#M203007</link>
      <description>&lt;P&gt;Hi team,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am getting the below error after signing the kernel image&amp;nbsp;vmlinux_signed.bin ,&lt;/P&gt;&lt;P&gt;U-Boot &amp;gt; hab_auth_img 0x12000000 0x00933348&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;hab fuse not enabled&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;Authenticate image from DDR location 0x12000000...&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;bad magic magic=0x0 length=0xa000 version=0xe1&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;bad length magic=0x0 length=0xa000 version=0xe1&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;bad version magic=0x0 length=0xa000 version=0xe1&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;Error: Invalid IVT structure&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;Allowed IVT structure:&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT HDR = 0x4X2000D1&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT ENTRY = 0xXXXXXXXX&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT RSV1 = 0x0&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT DCD = 0x0&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT BOOT_DATA = 0xXXXXXXXX&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT SELF = 0xXXXXXXXX&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT CSF = 0xXXXXXXXX&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT RSV2 = 0x0&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;MX6 HORIZON U-Boot &amp;gt;&lt;/P&gt;&lt;P&gt;i have followed the below link to sign the kernel image.&lt;/P&gt;&lt;P&gt;&lt;A href="https://elixir.bootlin.com/u-boot/v2021.10/source/doc/imx/habv4/guides/mx6_mx7_secure_boot.txt" target="_blank"&gt;mx6_mx7_secure_boot.txt - doc/imx/habv4/guides/mx6_mx7_secure_boot.txt - U-boot source code (v2021.10) - Bootlin&lt;/A&gt;&lt;/P&gt;&lt;P&gt;below is my csf file content.&lt;/P&gt;&lt;P&gt;[Authenticate Data]&lt;BR /&gt;# Key slot index used to authenticate the image data&lt;BR /&gt;&amp;nbsp;Verification index = 2&lt;BR /&gt;&amp;nbsp;# Authenticate Start Address, Offset, Length and file&lt;BR /&gt;&amp;nbsp;# Blocks = 0x877ff400 0x00000000 0x0009ec00 "u-boot-dtb.imx"&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;Blocks = 0x12000000 0x0 0x00933368 "vmlinuz-pad-ivt.bin"&lt;/P&gt;&lt;P&gt;Please help me to find the issue, any input would be appriciated.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rk&lt;/P&gt;</description>
      <pubDate>Tue, 21 Mar 2023 07:11:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1618944#M203007</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-03-21T07:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620505#M203109</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;DIV&gt;I hope you are doing well.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Please make sure that you have correctly loaded kernel zimage to load the address.&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Please try padding the zimage to&amp;nbsp;the next 4kB boundary.&lt;/DIV&gt;
&lt;DIV&gt;Please refer to 3.1 Padding the image in&lt;A href="https://source.codeaurora.org/external/imx/uboot-imx/tree/doc/imx/habv4/guides/mx6_mx7_secure_boot.txt?h=lf_v2022.04" target="_blank" rel="noopener" data-saferedirecturl="https://www.google.com/url?q=https://source.codeaurora.org/external/imx/uboot-imx/tree/doc/imx/habv4/guides/mx6_mx7_secure_boot.txt?h%3Dlf_v2022.04&amp;amp;source=gmail&amp;amp;ust=1679633851779000&amp;amp;usg=AOvVaw3_BFHukiJUmJUq3eeatQK3"&gt;&amp;nbsp;/doc/imx/habv4/guides/mx6_&lt;WBR /&gt;mx7_secure_boot.txt&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;One can refer to the mentioned document for hab authentication.&lt;/DIV&gt;
&lt;DIV&gt;&lt;A href="https://boundarydevices.com/high-assurance-boot-hab-dummies/" target="_blank" rel="noopener" data-saferedirecturl="https://www.google.com/url?q=https://boundarydevices.com/high-assurance-boot-hab-dummies/&amp;amp;source=gmail&amp;amp;ust=1679633851779000&amp;amp;usg=AOvVaw06RIRV0aUz1reB0dd7jRUv"&gt;&lt;STRONG&gt;High Assurance Boot (HAB)&lt;/STRONG&gt;&lt;/A&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Thanks &amp;amp; Regards,&lt;/DIV&gt;
&lt;DIV&gt;Dhruvit Vasavada&lt;/DIV&gt;</description>
      <pubDate>Thu, 23 Mar 2023 05:40:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620505#M203109</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-03-23T05:40:36Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620566#M203116</link>
      <description>&lt;P&gt;Hi Druvit,&lt;/P&gt;&lt;P&gt;thanks for response.&lt;/P&gt;&lt;P&gt;Yes, i have added now the 0x1000 padded bytes at end of zImage and didn't get any hab error events.&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Blocks = 0x12000000 0x0 0x00933368 "vmlinuz-pad-ivt.bin"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;0x00933368 = size_of_pad_ivt_img.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Used hab_auth_img &amp;lt;load_address&amp;gt; &amp;lt;signed_img_size&amp;gt; &amp;lt;ivt_offset&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;signed_img_size = padded_img+ivt+csf .&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;U-Boot &amp;gt; hab_auth_img 0x12000000 0x009342a8 0x00933348&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;hab fuse not enabled&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Authenticate image from DDR location 0x12000000...&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;Secure boot disabled&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;HAB Configuration: 0xf0, HAB State: 0x66&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;--------- HAB Event 1 -----------------&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;event data:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x01&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;STS = HAB_WARNING (0x69)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;RSN = HAB_ENG_FAIL (0x30)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;CTX = HAB_CTX_ENTRY (0xE1)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT face="batang,apple gothic"&gt;ENG = HAB_ENG_CAAM (0x1D)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;I have signed dtb and initrd img also, and checked all hab status of all images, But i am getting above warning in all hab but not getting any error.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;1) How to get rid of this warning ?&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;2) While botting i am still getting the&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Authenticate image from DDR location 0x12000000... bad magic magic=0x0 length=0xa000 version=0xe1 bad length magic=0x0 length=0xa000 version=0xe1 bad version magic=0x0 length=0xa000 version=0xe1 Error: Invalid IVT structure Allowed IVT structure: IVT HDR = 0x4X2000D1&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Using u-boot (2021) kernel(5.10).&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Please help me here on this issue/warning.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Regards,&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="batang,apple gothic"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Rakesh&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 23 Mar 2023 07:19:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620566#M203116</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-03-23T07:19:19Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620831#M203148</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I hope you are doing well.&lt;/P&gt;
&lt;P&gt;HAB Event warning could be generated due to&lt;SPAN&gt; incorrect implementation of drng self-test in boot ROM.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P data-unlink="true"&gt;&lt;SPAN&gt;Please refer to&amp;nbsp;&lt;A href="https://source.codeaurora.org/external/imx/uboot-imx/commit/drivers/crypto/fsl?h=lf_v2021.04&amp;amp;id=578c36a50b4169854cfcc747d80ca95c06984704" target="_self"&gt;MLK-20950 Run RNG self test for impacted i.MX chips.&amp;nbsp;&lt;/A&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;While botting I am still getting the&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;Authenticate image from DDR location 0x12000000... bad magic magic=0x0 length=0xa000 version=0xe1 bad length magic=0x0 length=0xa000 version=0xe1 bad version magic=0x0 length=0xa000 version=0xe1 Error: Invalid IVT structure Allowed IVT structure: IVT HDR = 0x4X2000D1&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;[Ans]: This could be due to not signing&amp;nbsp;&lt;STRONG&gt;kernel image&lt;/STRONG&gt; and dtb image correctly.&lt;/P&gt;
&lt;P&gt;Please make sure that you have used the correct&amp;nbsp;zImage_pad_ivt.bin size in CSF after padding.&lt;BR /&gt;and followed the correct steps as mentioned in&amp;nbsp;&lt;A href="https://boundarydevices.com/high-assurance-boot-hab-dummies/" target="_blank" rel="noopener nofollow noreferrer" data-saferedirecturl="https://www.google.com/url?q=https://boundarydevices.com/high-assurance-boot-hab-dummies/&amp;amp;source=gmail&amp;amp;ust=1679633851779000&amp;amp;usg=AOvVaw06RIRV0aUz1reB0dd7jRUv"&gt;&lt;STRONG&gt;High Assurance Boot (HAB)&lt;/STRONG&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Thanks &amp;amp; Regards,&lt;BR /&gt;Dhruvit Vasavada&lt;/P&gt;</description>
      <pubDate>Thu, 23 Mar 2023 11:41:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1620831#M203148</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-03-23T11:41:29Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1621135#M203173</link>
      <description>&lt;P&gt;Hi Druvit,&lt;/P&gt;&lt;P&gt;thanks for reply,&lt;/P&gt;&lt;P&gt;Let me explain , how i am calculating and using the kernel image.&lt;/P&gt;&lt;P&gt;&amp;gt; hexdump -C vmlinuz-5.10.158-cip22+mel2 | tail -n 1&lt;BR /&gt;0x00932348&lt;/P&gt;&lt;P&gt;above is the size of my kernel and i have padded to this image(0x1000) and make it&amp;nbsp;&lt;/P&gt;&lt;P&gt;hexdump -C vmlinuz-pad.bin | tail -n 1&lt;BR /&gt;0x00933348&lt;/P&gt;&lt;P&gt;below is my genIVT.pl&amp;nbsp;&lt;/P&gt;&lt;P&gt;#! /usr/bin/perl -w&lt;BR /&gt;use strict;&lt;BR /&gt;open(my $out, '&amp;gt;:raw', 'ivt.bin') or die "Unable to open: $!";&lt;BR /&gt;print $out pack("V", 0x412000D1); # Signature&lt;BR /&gt;print $out pack("V", 0x12000000); # Load Address (*load_address)&lt;BR /&gt;print $out pack("V", 0x0); # Reserved&lt;BR /&gt;print $out pack("V", 0x0); # DCD pointer&lt;BR /&gt;print $out pack("V", 0x0); # Boot Data&lt;BR /&gt;print $out pack("V", 0x12933348); # Self Pointer (*ivt)&lt;BR /&gt;print $out pack("V", 0x12933368); # CSF Pointer (*csf)&lt;BR /&gt;print $out pack("V", 0x0); # Reserved&lt;BR /&gt;close($out);&lt;/P&gt;&lt;P&gt;ivt = load_address + size_of_padded_img (0x12000000 + 0x00933348)&lt;/P&gt;&lt;P&gt;CSF = ivt+offset (0x20) = (0x12933348 + 0x20)&amp;nbsp;&lt;/P&gt;&lt;P&gt;appended the vmlinuz-pad.bin to ivt.bin.&lt;/P&gt;&lt;P&gt;below is the content of my vmlinuz-pad-ivt.bin .&lt;/P&gt;&lt;P&gt;&amp;gt; hexdump -C vmlinuz-pad-ivt..bin&amp;nbsp;&lt;/P&gt;&lt;P&gt;00932340 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................|&lt;BR /&gt;*&lt;BR /&gt;00933340 00 00 00 00 00 00 00 00 &lt;FONT color="#008000"&gt;&lt;STRONG&gt;d1 00 20 41 00 00 00 12 |.......... A....|&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#008000"&gt;&lt;STRONG&gt;00933350 00 00 00 00 00 00 00 00 00 00 00 00 48 33 93 12 |............H3..|&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#008000"&gt;&lt;STRONG&gt;00933360 68 33 93 12 00 00 00 00&lt;/STRONG&gt;&lt;/FONT&gt; |h3......|&lt;BR /&gt;00933368&lt;/P&gt;&lt;P&gt;As we can see the content contain the IVT structure at 0x00933348 and size of vmlinuz-pad-ivt.bin is 0x00933368.&amp;nbsp;&lt;/P&gt;&lt;P&gt;SO in csf file i have mention Authentication Data as below.&lt;/P&gt;&lt;P&gt;[Authenticate Data]&lt;BR /&gt;# Key slot index used to authenticate the image data&lt;BR /&gt;Verification index = 2&lt;BR /&gt;# Authenticate Start Address, Offset, Length and file&lt;/P&gt;&lt;P&gt;Blocks = 0x12000000 0x0 0x00933368 "vmlinuz-pad-ivt.bin"&lt;/P&gt;&lt;P&gt;followed as below.&lt;/P&gt;&lt;P&gt;Block = &amp;lt;load_address&amp;gt; &amp;lt;offset&amp;gt; &amp;lt;size_of_img(size_of img+pad_ivt)&amp;gt;&lt;/P&gt;&lt;P&gt;and checking the hab_auth_img as below.&lt;/P&gt;&lt;P&gt;loaded the img like&amp;nbsp;&lt;/P&gt;&lt;P&gt;u-boot&amp;gt;load mmc 3:1 0x12000000 /boot/vmlinuz-pad-ivt-signed.bin&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;U-Boot &amp;gt; hab_auth_img 0x12000000 009342a8 00933348&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;hab fuse not enabled&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;Authenticate image from DDR location 0x12000000...&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;Secure boot disabled&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;HAB Configuration: 0xf0, HAB State: 0x66&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;--------- HAB Event 1 -----------------&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;event data:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x01&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;STS = HAB_WARNING (0x69)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;RSN = HAB_ENG_FAIL (0x30)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;CTX = HAB_CTX_ENTRY (0xE1)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;ENG = HAB_ENG_CAAM (0x1D)&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;No, error but just warning on checking the hab status of kernel img.&lt;/P&gt;&lt;P&gt;Please suggest, if i am wrong anywhere in my followings steps. After loading the kernel image when using&amp;nbsp;&lt;/P&gt;&lt;P&gt;u-boot &amp;gt; boot&amp;nbsp;&lt;/P&gt;&lt;P&gt;its again showing the same Invalid IVT structure. Is the kernel image is not loading correctly ot any issue .Please suggest on this .&lt;/P&gt;&lt;P&gt;1) Please point out any mistake here.&lt;/P&gt;&lt;P&gt;2) how to run&amp;nbsp;&lt;SPAN&gt;RNG self test&lt;/SPAN&gt;&amp;nbsp;?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rk&lt;/P&gt;</description>
      <pubDate>Thu, 23 Mar 2023 19:00:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1621135#M203173</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-03-23T19:00:24Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1621644#M203227</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I hope you are doing well.&lt;/P&gt;
&lt;P&gt;It seems that the Kernel image is not padded correctly, As&amp;nbsp;&lt;SPAN&gt;0x00933348 does not look to be the next 0x1000 boundary.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;In this case, the vmlinuz size is&amp;nbsp;0x00932348, So the next 0x1000 boundary is&amp;nbsp;0x00933000.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The correct command to sign the image would be as below.&lt;/SPAN&gt;&lt;/P&gt;
&lt;PRE&gt;$ objcopy -I binary -O binary --pad-to 0x&lt;SPAN&gt;933000&lt;/SPAN&gt; --gap-fill=0x00 \
  &lt;SPAN&gt;&amp;nbsp;vmlinuz-5.10.158-cip22+mel2&lt;/SPAN&gt; &lt;SPAN&gt;vmlinuz-pad.bin&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks &amp;amp; Regards,&lt;BR /&gt;Dhruvit Vasavada&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2023 11:53:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1621644#M203227</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-03-24T11:53:41Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1622306#M203268</link>
      <description>&lt;P&gt;Thanks Dhruvit for pointing out the padding mistake here.&lt;/P&gt;&lt;P&gt;I have to signed the dtb and initrd.img also, So do we have to pad these images also or without padding bytes we can include these images in the blocks&amp;nbsp; ?&lt;/P&gt;&lt;P&gt;As below&amp;nbsp;&lt;BR /&gt;Blocks = 0x12000000 0x0 0x00933020 "vmlinuz-new-pad-ivt.bin"&lt;BR /&gt;Blocks = 0x18000000 0x0 0x0000d318 "imx6q.dtb"&lt;BR /&gt;Blocks = 0x13000000 0x0 0x004989c8 "initrd-img.bin"&lt;/P&gt;&lt;P&gt;2) Can we use&amp;nbsp; csf_additional_image.txt but created this csf.bin file with what image we can append this csf.bin file. ? ( with vmlinuz file ?)&amp;nbsp;&lt;/P&gt;&lt;P&gt;Or we can individually create the csf.bin for dtb and initramfs also ?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rk&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2023 07:27:36 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1622306#M203268</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-03-27T07:27:36Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1622618#M203293</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I hope you are doing well.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;dtb and initrd.img should not require padding.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Can we use&amp;nbsp; csf_additional_image.txt but created this csf.bin file with what image we can append this csf.bin file. ? ( with vmlinuz file ?)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;[Ans]:&amp;nbsp; Yes, One can refer to&amp;nbsp;csf_additional_image.txt.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;csf.bin is appended to the kernel image. ( e.g. zImage)&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Please make sure that uboot defconfig contains&lt;STRONG&gt;&amp;nbsp;CONFIG_RNG_SELF_TEST=y.&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanks &amp;amp; Regards,&lt;BR /&gt;Dhruvit Vasavada&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2023 13:06:38 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1622618#M203293</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-03-27T13:06:38Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1623048#M203320</link>
      <description>&lt;P&gt;Thanks Dhruvit for suggestion.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i already have enabled below config&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;CONFIG_RNG_SELF_TEST=y&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;and have this patch also in my uboot code&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://source.codeaurora.org/external/imx/uboot-imx/commit/drivers/crypto/fsl?h=lf_v2021.04&amp;amp;id=578c36a50b4169854cfcc747d80ca95c06984704" target="_blank"&gt;https://source.codeaurora.org/external/imx/uboot-imx/commit/drivers/crypto/fsl?h=lf_v2021.04&amp;amp;id=578c36a50b4169854cfcc747d80ca95c06984704&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;But still getting below warning.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;-&lt;FONT size="2"&gt;-------- HAB Event 1 -----------------&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;event data:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0xdb 0x00 0x24 0x42 0x69 0x30 0xe1 0x1d&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x04 0x00 0x02 0x40 0x00 0x36 0x06&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x55 0x55 0x00 0x03 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x00 0x00 0x00 0x01&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;STS = HAB_WARNING (0x69)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;RSN = HAB_ENG_FAIL (0x30)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;CTX = HAB_CTX_ENTRY (0xE1)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;ENG = HAB_ENG_CAAM (0x1D&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;How to get rid of this warning any suggestion ?&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;How to perform rng_self_test and remove this last warning also? &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Regards,&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Rk&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2023 06:13:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1623048#M203320</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-03-28T06:13:03Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1623125#M203330</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I hope you are doing well.&lt;/P&gt;
&lt;P&gt;Does u-boot successfully able to boot the kernel?&lt;/P&gt;
&lt;P&gt;Do hab_status commands show similar output?&lt;/P&gt;
&lt;P&gt;Please provide me with the silicon revision of the chip, and u-boot logs( which can be seen in the u-boot logs). and the command used to authenticate the kernel image.&lt;/P&gt;
&lt;P&gt;How to perform rng_self_test and remove this last warning also?&lt;BR /&gt;[Ans]: rng_selt_test runs when enabling&amp;nbsp;&lt;STRONG&gt;CONFIG_RNG_SELF_TEST &lt;/STRONG&gt;option.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;This&amp;nbsp;issue does not have any real impact on secure Boot flow and does not compromise the security of the device.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The descriptors used to run the RNG self-test in certain HAB versions of i.MX chips have been constructed incorrectly due to which the RNG self-test fails in CAAM.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanks &amp;amp; Regards,&lt;BR /&gt;Dhruvit Vasavada&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2023 07:40:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1623125#M203330</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-03-28T07:40:13Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1623222#M203343</link>
      <description>&lt;P&gt;Hi Dhruvit,&lt;/P&gt;&lt;P&gt;Thanks for your response.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Does u-boot successfully able to boot the kernel?&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;[Ans] - Yes, I am able to successfully able to boot u-boot and kernel and getting only one same warning.&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Do hab_status commands show similar output?&amp;nbsp;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;[Ans] - Yes&lt;/P&gt;&lt;P&gt;Silicon version - 1.6&amp;nbsp; (CPU: i.MX6D rev1.6 at 792MHz)&lt;/P&gt;&lt;P&gt;Below is the u-boot logs.&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;Image Type: Freescale IMX Boot Image&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;Image Ver: 2 (i.MX53/6/7 compatible)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;Mode: DCD&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;Data Size: 610400 Bytes = 596.09 KiB = 0.58 MiB&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;Load Address: 177ff420&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;Entry Point: 17800000&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;HAB Blocks: 0x177ff400 0x00000000 0x00092c00&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;DCD Blocks: 0x00910000 0x0000002c 0x000002f8&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;$ hexdump -C vmlinuz-pad.bin | tail -n 1&lt;BR /&gt;00933000&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;$ hexdump -C vmlinuz-pad-ivt.bin | tail -n 1&lt;BR /&gt;00933020&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;$&amp;nbsp; hexdump -C vmlinuz-new-signed.bin | tail -n 1&lt;BR /&gt;00933f60&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;below is content of kernel_genIVT.pl&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;#! /usr/bin/perl -w&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;use strict;&lt;BR /&gt;open(my $out, '&amp;gt;:raw', 'ivt.bin') or die "Unable to open: $!";&lt;BR /&gt;print $out pack("V", 0x402000D1); # Signature&lt;BR /&gt;print $out pack("V", 0x12000000); # Load Address (*load_address)&lt;BR /&gt;print $out pack("V", 0x0); # Reserved&lt;BR /&gt;print $out pack("V", 0x0); # DCD pointer&lt;BR /&gt;print $out pack("V", 0x0); # Boot Data&lt;BR /&gt;print $out pack("V", 0x12933000); # Self Pointer (*ivt)&lt;BR /&gt;print $out pack("V", 0x12933020); # CSF Pointer (*csf)&lt;BR /&gt;print $out pack("V", 0x0); # Reserved&lt;BR /&gt;close($out);&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;Command used to Authenticate kernel image is &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;=&amp;gt;hab_auth_img&amp;nbsp;&lt;SPAN&gt;&lt;SPAN class=""&gt;0x12000000 0x00933f60 0x00933000&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;after enabling DEBUG in hab.c i can see correct expected o/p.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;U-Boot &amp;gt; hab_auth_img 0x12000000 0x00933f60 0x00933000&lt;BR /&gt;hab fuse not enabled&lt;/P&gt;&lt;P&gt;Authenticate image from DDR location 0x12000000...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ivt_offset = 0x933000, ivt addr = 0x12933000&lt;BR /&gt;ivt entry = 0x12000000, dcd = 0x00000000, csf = 0x12933020&lt;BR /&gt;Dumping IVT&lt;BR /&gt;12933000: 402000d1 12000000 00000000 00000000&amp;nbsp;&amp;nbsp;&amp;nbsp; .. @............&lt;BR /&gt;12933010: 00000000 12933000 12933020 00000000&amp;nbsp;&amp;nbsp;&amp;nbsp; .....0.. 0......&lt;BR /&gt;Dumping CSF Header&lt;BR /&gt;12933020: 425000d4 000c00be 00001703 50000000&amp;nbsp;&amp;nbsp;&amp;nbsp; ..PB...........P&lt;BR /&gt;12933030: 020c00be 01000009 90040000 000c00ca&amp;nbsp;&amp;nbsp;&amp;nbsp; ................&lt;BR /&gt;12933040: 001dc501 e4070000 000c00be 02000009&amp;nbsp;&amp;nbsp;&amp;nbsp; ................&lt;BR /&gt;12933050: e8090000 001400ca 001dc502 3c0d0000&amp;nbsp;&amp;nbsp;&amp;nbsp; ...............&amp;lt;&lt;/P&gt;&lt;P&gt;If you need any further file info (drivers/crypto/rng_self_test.c) then can tell&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Regards,&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Rk&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Mar 2023 09:21:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1623222#M203343</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-03-28T09:21:33Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1624982#M203453</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I hope you are doing well.&lt;/P&gt;
&lt;P&gt;This warning message was generated by HAB due to incorrect implementation of drng&lt;BR /&gt;self test in boot ROM.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;There is no method to remove the warning that occurs in the Boot ROM phase.&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;After implementing the rng_self_test (CONFIG_RNG_SELF_TEST=y) this warning can be ignored in further implementation of security.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanks &amp;amp; Regards,&lt;BR /&gt;Dhruvit Vasavada&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Mar 2023 06:52:31 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1624982#M203453</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-03-30T06:52:31Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1627018#M203633</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;A href="https://community.nxp.com/t5/user/viewprofilepage/user-id/201299" target="_self"&gt;&lt;SPAN class=""&gt;Dhruvit,&lt;/SPAN&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Thanks for such good support.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;Summary of whole discussion: -&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;1)&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;bad version magic=0x0 length=0xa000 version=0xe1&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;Error: Invalid IVT structure&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;Allowed IVT structure:&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT HDR = 0x4X2000D1&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF6600"&gt;&lt;STRONG&gt;IVT ENTRY = 0xXXXXXX&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF6600"&gt;Solution:- Mostly this error comes because of incorrect address passed during signed signing of img.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;1) Mistake :- Calculation of padding bytes to kernel img:&lt;/P&gt;&lt;P&gt;solution :- it should be padded to its nearest 4kb(0x1000) length.&lt;/P&gt;&lt;P&gt;2) Calculation of IVT-offset -&amp;nbsp;&lt;/P&gt;&lt;P&gt;=&amp;gt;hab_auth_img &amp;lt;load_address&amp;gt; &amp;lt;signed_img_size&amp;gt; &amp;lt;ivt_offset_in_signed_img&amp;gt;&lt;/P&gt;&lt;P&gt;$ hexdump -C signed_img&amp;nbsp; - search of ivt header (0xd1 00 20 41/41)&amp;nbsp; ..thats will be ivt-offset in signed image.&lt;/P&gt;&lt;P&gt;Thanks for your support.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rk&lt;/P&gt;</description>
      <pubDate>Mon, 03 Apr 2023 17:19:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1627018#M203633</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-04-03T17:19:46Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1627680#M203709</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/212816"&gt;@rakesh3&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;I hope you are doing well.&lt;/P&gt;
&lt;P&gt;can I mark this case as close now?&lt;/P&gt;
&lt;P&gt;Thanks &amp;amp; Regards,&lt;BR /&gt;Dhruvit Vasavada&lt;/P&gt;</description>
      <pubDate>Tue, 04 Apr 2023 12:36:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1627680#M203709</guid>
      <dc:creator>Dhruvit</dc:creator>
      <dc:date>2023-04-04T12:36:45Z</dc:date>
    </item>
    <item>
      <title>Re: Secure boot imx6 Invalid IVT structure</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1627691#M203715</link>
      <description>&lt;P&gt;Hi Druvit,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes, you can close this ticket now.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for such great support.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rk&lt;/P&gt;</description>
      <pubDate>Tue, 04 Apr 2023 12:54:10 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/Secure-boot-imx6-Invalid-IVT-structure/m-p/1627691#M203715</guid>
      <dc:creator>rakesh3</dc:creator>
      <dc:date>2023-04-04T12:54:10Z</dc:date>
    </item>
  </channel>
</rss>

