<?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中的主题 回复： dm_crypt    file in /mnt/encrypted unencrypt</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1613082#M202565</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/192970"&gt;@Harvey021&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I already know why. It's explained on the document---“NAND flash is an MTD device, hence, DM-Crypt cannot be used with”， my flash is NAND flash, I made a big joke&lt;/P&gt;</description>
    <pubDate>Fri, 10 Mar 2023 09:50:22 GMT</pubDate>
    <dc:creator>haichao</dc:creator>
    <dc:date>2023-03-10T09:50:22Z</dc:date>
    <item>
      <title>dm_crypt    file in /mnt/encrypted unencrypt</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1611524#M202474</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I am following the application note AN12714 (i.MX Encrypted Storage Using CAAM Secure Keys&amp;nbsp; Rev. 0 — 25 February 2020).&amp;nbsp; when I create secure key, I get:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;[root@IoT-A6G2C /jffs/dm_crypto]# ./keyctl add caam_tk seckey "new ecb 16" @s | xargs ./keyctl print &amp;gt; blob&lt;BR /&gt;keyctl_read_alloc: Permission denied&lt;BR /&gt;[root@IoT-A6G2C /jffs/dm_crypto]#&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I dont know how to slove it, then I use cmd:&amp;nbsp;./keyctl add caam_tk seckey "new ecb 16" &lt;FONT color="#FF0000"&gt;@u&lt;/FONT&gt; | xargs ./keyctl print &amp;gt; blob&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;success!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;but when I&amp;nbsp;Execute the following command：&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;[root@IoT-A6G2C /jffs/dm_crypto]# mount -t ext4 /dev/mapper/encrypted /jffs/dm_crypto/mnt/encrypted/&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I find the files in&amp;nbsp;/jffs/dm_crypto/mnt/encrypted/ unencrypt，I don't know how solve it,I need help. thanks&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;[root@IoT-A6G2C /jffs/dm_crypto/mnt/encrypted]# cat readme.txt&lt;BR /&gt;This is a test of full disk encryption on i.MX&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;[root@IoT-A6G2C /jffs/dm_crypto]#uname -a&lt;BR /&gt;Linux IoT-A6G2C 4.14.98-g586ed8b06-dirty #1 SMP Wed Mar 8 08:48:46 UTC 2023 armv7l GNU/Linux&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;imx6ul&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Mar 2023 09:27:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1611524#M202474</guid>
      <dc:creator>haichao</dc:creator>
      <dc:date>2023-03-08T09:27:02Z</dc:date>
    </item>
    <item>
      <title>回复： dm_crypt    file in /mnt/encrypted unencrypt</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1612101#M202500</link>
      <description>&lt;P&gt;&lt;SPAN&gt;[root@IoT-A6G2C /jffs/dm_crypto]# ./keyctl add caam_tk seckey "new ecb 16" @s | xargs ./keyctl print &amp;gt; blob&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;keyctl_read_alloc: Permission denied&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;about the problom, the list link give me the answor&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/Unable-to-store-keys-in-key-ring-using-keyctl/m-p/1376947" target="_blank"&gt;Unable to store keys in key ring using keyctl - NXP Community&lt;/A&gt;&lt;/P&gt;&lt;P&gt;yes&lt;/P&gt;&lt;P&gt;use this cmd: &lt;STRONG&gt;keyctl session &lt;/STRONG&gt;before&amp;nbsp;&lt;SPAN&gt;./keyctl add caam_tk seckey "new ecb 16" @s | xargs ./keyctl print &amp;gt; blob&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;but I follow the&amp;nbsp;&lt;SPAN&gt;AN12714 (i.MX Encrypted Storage Using CAAM Secure Keys&amp;nbsp; Rev. 0 — 25 February 2020)，when I put file to mnt/encrypted, the file is unencrypt,&amp;nbsp; I don't know why ,please help me&amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;many thanks!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Mar 2023 04:21:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1612101#M202500</guid>
      <dc:creator>haichao</dc:creator>
      <dc:date>2023-03-09T04:21:49Z</dc:date>
    </item>
    <item>
      <title>Re: dm_crypt    file in /mnt/encrypted unencrypt</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1612888#M202547</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/213132"&gt;@haichao&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Both session keyring and ext4 filesystem could be done without issue with the BSP that we provided.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please share how you've tested for the unencrypted? ensure that every step has operated with success, Like how is the Mount operation?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;P&gt;Harvey&lt;/P&gt;</description>
      <pubDate>Fri, 10 Mar 2023 05:53:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1612888#M202547</guid>
      <dc:creator>Harvey021</dc:creator>
      <dc:date>2023-03-10T05:53:35Z</dc:date>
    </item>
    <item>
      <title>Re: dm_crypt    file in /mnt/encrypted unencrypt</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1612940#M202550</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/192970"&gt;@Harvey021&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your reply！&lt;/P&gt;&lt;P&gt;I follow the note&amp;nbsp; &lt;STRONG&gt;AN12714&amp;nbsp;&amp;nbsp;Rev. 0 — 25 February 2020&lt;/STRONG&gt; step by step. &lt;FONT color="#FF0000"&gt;the diffence is my kernel verison(imx-4.14.98)&lt;/FONT&gt;&lt;STRONG&gt;.&amp;nbsp;&lt;/STRONG&gt;download &lt;EM&gt;meta-imx-fde-demo&lt;/EM&gt; and insert the patch file in the recipes-kernel into my kernel,and modify config file.&lt;/P&gt;&lt;P&gt;.part of kernel startup information：&lt;/P&gt;&lt;P&gt;sdhci-esdhc-imx 2194000.usdhc: assigned as wifi host&lt;BR /&gt;mmc1: SDHCI controller on 2194000.usdhc [2194000.usdhc] using ADMA&lt;BR /&gt;caam 2140000.caam: ERA source: CCBVID.&lt;BR /&gt;caam 2140000.caam: device ID = 0x0a16030000000000 (Era &lt;LI-EMOJI id="lia_smiling-face-with-sunglasses" title=":戴墨镜微笑:"&gt;&lt;/LI-EMOJI&gt;&lt;BR /&gt;caam 2140000.caam: job rings = 3, qi = 0, dpaa2 = no&lt;BR /&gt;caam_jr 2141000.jr0: Entropy delay = 3200&lt;BR /&gt;caam_jr 2141000.jr0: Instantiated RNG4 SH0.&lt;BR /&gt;caam_jr 2141000.jr0: Instantiated RNG4 SH1.&lt;BR /&gt;&lt;STRONG&gt;caam algorithms registered in /proc/crypto&lt;/STRONG&gt;&lt;BR /&gt;caam_jr 2141000.jr0: registering rng-caam&lt;BR /&gt;&lt;STRONG&gt;caam 2140000.caam: caam pkc algorithms registered in /proc/crypto&lt;/STRONG&gt;&lt;BR /&gt;platform caam_sm: blkkey_ex: 8 keystore units available&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key input: [key: 00101000(8) black_key: 00101000(128), auth: 0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key processing: [key: 00101000(8) black_key: 00101000(8)&lt;BR /&gt;caam_jr 2143000.jr2: req:16, auth: 0x0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key input: [key: 00101080(16) black_key: 00101080(128), auth: 0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key processing: [key: 00101080(16) black_key: 00101080(16)&lt;BR /&gt;caam_jr 2143000.jr2: req:16, auth: 0x0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key input: [key: 00101100(24) black_key: 00101100(128), auth: 0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key processing: [key: 00101100(24) black_key: 00101100(24)&lt;BR /&gt;caam_jr 2143000.jr2: req:32, auth: 0x0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key input: [key: 00101180(32) black_key: 00101180(128), auth: 0]&lt;BR /&gt;caam_jr 2143000.jr2: caam_black_key processing: [key: 00101180(32) black_key: 00101180(32)&lt;BR /&gt;caam_jr 2143000.jr2: req:32, auth: 0x0]&lt;BR /&gt;platform caam_sm: 64-bit clear key:&lt;BR /&gt;platform caam_sm: [0000] 00 01 02 03 04 0f 06 07&lt;BR /&gt;platform caam_sm: 64-bit black key:&lt;BR /&gt;platform caam_sm: [0000] 66 e4 85 83 07 f2 c9 10&lt;BR /&gt;platform caam_sm: [0008] fb c6 2f c3 99 7a 5f 65&lt;BR /&gt;platform caam_sm: 128-bit clear key:&lt;BR /&gt;platform caam_sm: [0000] 00 01 02 03 04 0f 06 07&lt;BR /&gt;platform caam_sm: [0008] 08 09 0a 0b 0c 0d 0e 0f&lt;BR /&gt;platform caam_sm: 128-bit black key:&lt;BR /&gt;platform caam_sm: [0000] 61 ea 2d b6 28 1c 5f 15&lt;BR /&gt;platform caam_sm: [0008] 60 95 c1 5e f9 0b 89 a4&lt;BR /&gt;platform caam_sm: 192-bit clear key:&lt;BR /&gt;platform caam_sm: [0000] 00 01 02 03 04 0f 06 07&lt;BR /&gt;platform caam_sm: [0008] 08 09 0a 0b 0c 0d 0e 0f&lt;BR /&gt;platform caam_sm: [0016] 10 11 12 13 14 15 16 17&lt;BR /&gt;platform caam_sm: 192-bit black key:&lt;BR /&gt;platform caam_sm: [0000] e4 41 b7 ba 9f fc c6 e9&lt;BR /&gt;platform caam_sm: [0008] f7 eb ea f1 15 49 51 5a&lt;BR /&gt;platform caam_sm: [0016] e2 e2 d5 20 af d8 20 dd&lt;BR /&gt;platform caam_sm: [0024] fd 27 4c 7d 2e 22 a6 01&lt;BR /&gt;platform caam_sm: 256-bit clear key:&lt;BR /&gt;platform caam_sm: [0000] 00 01 02 03 04 0f 06 07&lt;BR /&gt;platform caam_sm: [0008] 08 09 0a 0b 0c 0d 0e 0f&lt;BR /&gt;platform caam_sm: [0016] 10 11 12 13 14 15 16 17&lt;BR /&gt;platform caam_sm: [0024] 18 19 1a 1b 1c 1d 1e 1f&lt;BR /&gt;platform caam_sm: 256-bit black key:&lt;BR /&gt;platform caam_sm: [0000] fc fd 0b 4f 45 d3 83 fd&lt;BR /&gt;platform caam_sm: [0008] 9f 45 2e 2a 03 88 15 8b&lt;BR /&gt;platform caam_sm: [0016] 78 d8 37 fd b2 eb d8 71&lt;BR /&gt;platform caam_sm: [0024] 05 b7 38 59 bd 49 6f fb&lt;BR /&gt;platform caam_sm: 64-bit unwritten blob:&lt;BR /&gt;platform caam_sm: [0000] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0008] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0016] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0024] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0032] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0040] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0048] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0056] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0064] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 128-bit unwritten blob:&lt;BR /&gt;platform caam_sm: [0000] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0008] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0016] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0024] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0032] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0040] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0048] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0056] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0064] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 196-bit unwritten blob:&lt;BR /&gt;platform caam_sm: [0000] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0008] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0016] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0024] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0032] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0040] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0048] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0056] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0064] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 256-bit unwritten blob:&lt;BR /&gt;platform caam_sm: [0000] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0008] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0016] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0024] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0032] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0040] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0048] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0056] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0064] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 64-bit black key in blob:&lt;BR /&gt;platform caam_sm: [0000] 06 0d b0 d0 31 91 82 71&lt;BR /&gt;platform caam_sm: [0008] e9 b3 59 80 ca f5 ef 90&lt;BR /&gt;platform caam_sm: [0016] 0c 30 a1 d1 61 70 96 f7&lt;BR /&gt;platform caam_sm: [0024] 3c e6 d7 a6 a7 4b c6 13&lt;BR /&gt;platform caam_sm: [0032] 3f 38 e9 e2 8b 2e fc 03&lt;BR /&gt;platform caam_sm: [0040] 88 7d af 67 5c ed bc 7e&lt;BR /&gt;platform caam_sm: [0048] 67 e7 65 69 4b 4d b8 82&lt;BR /&gt;platform caam_sm: [0056] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0064] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 128-bit black key in blob:&lt;BR /&gt;platform caam_sm: [0000] 66 b0 db 79 be 57 a7 fe&lt;BR /&gt;platform caam_sm: [0008] 38 7e a9 63 fa f9 23 be&lt;BR /&gt;platform caam_sm: [0016] 2e a7 fd 0c d2 71 13 99&lt;BR /&gt;platform caam_sm: [0024] 53 54 f5 80 d4 e5 ff 5a&lt;BR /&gt;platform caam_sm: [0032] f2 ba e2 76 21 21 68 68&lt;BR /&gt;platform caam_sm: [0040] 4c 1b 17 90 a4 df 8b 6a&lt;BR /&gt;platform caam_sm: [0048] 35 9c 77 f8 10 c0 6c a9&lt;BR /&gt;platform caam_sm: [0056] fa e0 d9 3d cc 79 d6 99&lt;BR /&gt;platform caam_sm: [0064] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 192-bit black key in blob:&lt;BR /&gt;platform caam_sm: [0000] f1 26 9d d2 de 91 3f a2&lt;BR /&gt;platform caam_sm: [0008] bb d3 4a c7 1e da 6b 40&lt;BR /&gt;platform caam_sm: [0016] 04 79 08 04 f3 df 0f 3f&lt;BR /&gt;platform caam_sm: [0024] bf b7 ac 93 1a 02 15 db&lt;BR /&gt;platform caam_sm: [0032] dc de 8f 35 2e 3c 95 79&lt;BR /&gt;platform caam_sm: [0040] df 59 d8 14 ba 3d ae 46&lt;BR /&gt;platform caam_sm: [0048] eb 71 8d 8b 38 02 15 d8&lt;BR /&gt;platform caam_sm: [0056] c9 28 fb d5 f9 98 fa 54&lt;BR /&gt;platform caam_sm: [0064] ae 81 d2 d1 5f de 17 47&lt;BR /&gt;platform caam_sm: [0072] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: 256-bit black key in blob:&lt;BR /&gt;platform caam_sm: [0000] 1f 60 64 a4 72 ca c2 b1&lt;BR /&gt;platform caam_sm: [0008] 9b 68 47 e3 8b c8 ab 85&lt;BR /&gt;platform caam_sm: [0016] a2 50 b9 4a c9 b1 3a bf&lt;BR /&gt;platform caam_sm: [0024] 73 53 b9 60 83 61 13 69&lt;BR /&gt;platform caam_sm: [0032] b2 8d 08 26 b1 7f ed 79&lt;BR /&gt;platform caam_sm: [0040] 1e a0 6a 8d c7 fd a3 bb&lt;BR /&gt;platform caam_sm: [0048] bd c5 9e f1 6d 50 cb a8&lt;BR /&gt;platform caam_sm: [0056] bd b0 91 6b f3 1a 97 83&lt;BR /&gt;platform caam_sm: [0064] 13 8d 6b 0c 35 78 7f fd&lt;BR /&gt;platform caam_sm: [0072] 89 c2 1b 61 d1 90 0b ac&lt;BR /&gt;platform caam_sm: [0080] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: [0088] 00 00 00 00 00 00 00 00&lt;BR /&gt;platform caam_sm: restored 64-bit black key:&lt;BR /&gt;platform caam_sm: [0000] 17 8b 93 6d 2c 58 81 c0&lt;BR /&gt;platform caam_sm: [0008] ee ec f5 34 9e e2 67 58&lt;BR /&gt;platform caam_sm: restored 128-bit black key:&lt;BR /&gt;platform caam_sm: [0000] 61 ea 2d b6 28 1c 5f 15&lt;BR /&gt;platform caam_sm: [0008] 60 95 c1 5e f9 0b 89 a4&lt;BR /&gt;platform caam_sm: restored 192-bit black key:&lt;BR /&gt;platform caam_sm: [0000] e4 41 b7 ba 9f fc c6 e9&lt;BR /&gt;platform caam_sm: [0008] f7 eb ea f1 15 49 51 5a&lt;BR /&gt;platform caam_sm: [0016] 67 1e 14 77 5a 19 4e 54&lt;BR /&gt;platform caam_sm: [0024] 55 00 7c 73 ed 46 1c fa&lt;BR /&gt;platform caam_sm: restored 256-bit black key:&lt;BR /&gt;platform caam_sm: [0000] fc fd 0b 4f 45 d3 83 fd&lt;BR /&gt;platform caam_sm: [0008] 9f 45 2e 2a 03 88 15 8b&lt;BR /&gt;platform caam_sm: [0016] 78 d8 37 fd b2 eb d8 71&lt;BR /&gt;platform caam_sm: [0024] 05 b7 38 59 bd 49 6f fb&lt;BR /&gt;&lt;STRONG&gt;caam-snvs 20cc000.caam-snvs: can't get snvs clock&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;caam-snvs 20cc000.caam-snvs: violation handlers armed - trusted state&lt;/STRONG&gt;&lt;BR /&gt;usbcore: registered new interface driver usbhid&lt;BR /&gt;usbhid: USB HID core driver&lt;BR /&gt;vf610-adc 2198000.adc: 2198000.adc supply vref not found, using dummy regulator&lt;BR /&gt;NET: Registered protocol family 26&lt;BR /&gt;nf_conntrack version 0.5.0 (2048 buckets, 8192 max)&lt;BR /&gt;xt_time: kernel timezone is -0000&lt;BR /&gt;ip_tables: (C) 2000-2006 Netfilter Core Team&lt;BR /&gt;NET: Registered protocol family 10&lt;BR /&gt;Segment Routing with IPv6&lt;BR /&gt;NET: Registered protocol family 17&lt;BR /&gt;can: controller area network core (rev 20170425 abi 9)&lt;BR /&gt;NET: Registered protocol family 29&lt;BR /&gt;can: raw protocol (rev 20170425)&lt;BR /&gt;can: broadcast manager protocol (rev 20170425 t)&lt;BR /&gt;can: netlink gateway (rev 20170425) max_hops=1&lt;BR /&gt;Bluetooth: RFCOMM TTY layer initialized&lt;BR /&gt;Bluetooth: RFCOMM socket layer initialized&lt;BR /&gt;Bluetooth: RFCOMM ver 1.11&lt;BR /&gt;Bluetooth: BNEP (Ethernet Emulation) ver 1.3&lt;BR /&gt;Bluetooth: BNEP filters: protocol multicast&lt;BR /&gt;Bluetooth: BNEP socket layer initialized&lt;BR /&gt;Bluetooth: HIDP (Human Interface Emulation) ver 1.2&lt;BR /&gt;Bluetooth: HIDP socket layer initialized&lt;BR /&gt;Key type dns_resolver registered&lt;BR /&gt;mmc0: new high speed SDHC card at address aaaa&lt;BR /&gt;mmcblk0: mmc0:aaaa SA08G 7.40 GiB&lt;BR /&gt;mmcblk0: p1&lt;BR /&gt;imx_thermal 2000000.aips-bus:tempmon: Automotive CPU temperature grade - max:125C critical:120C passive:115C&lt;BR /&gt;snvs_rtc 20cc000.snvs:snvs-rtc-lp: setting system clock to 1970-01-01 22:06:52 UTC (79612)&lt;BR /&gt;&lt;STRONG&gt;Key type caam_tk registered&lt;/STRONG&gt;&lt;BR /&gt;wlreg_on: disabling&lt;BR /&gt;md: Waiting for all devices to be available before autodetect&lt;BR /&gt;md: If you don't use raid, use raid=noautodetect&lt;BR /&gt;md: Autodetecting RAID arrays.&lt;BR /&gt;..................&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Refer to Section 3.2,the implementation results of each step are as follows:&lt;/P&gt;&lt;P&gt;1.make sure that cryptographic transformations using Tagged Key are registered.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;# grep -B1 -A2 tk- /proc/crypto|grep -v kernel
name : tk(ecb(aes))
driver : tk-ecb-aes-caam
priority : 1
--
name : tk(cbc(aes))
driver : tk-cbc-aes-caam
priority : 1&lt;/LI-CODE&gt;&lt;P&gt;2.Make sure Dm-Crypt is enabled&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;# ./dmsetup targets
crypt v1.18.1
striped v1.6.0
linear v1.4.0
error v1.5.0&lt;/LI-CODE&gt;&lt;P&gt;3. provide the device with its key&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;#./keyctl add caam_tk seckey "new ecb 16" @s | xargs ./keyctl print &amp;gt; blob
keyctl_read_alloc: Permission denied
# ./keyctl list @s
1 key in keyring:
228517484: --alswrv 0 65534 keyring: _uid.0
# ./keyctl session
Joined session keyring: 1066486877
# ./keyctl list @s
keyring is empty
# ./keyctl add caam_tk seckey "new ecb 16" @s | xargs ./keyctl print &amp;gt; blob
# ./keyctl list @s
1 key in keyring:
972125402: --als-rv 0 0 caam_tk: seckey
# cat blob
:hex:9926ac021bdba1a40875778dd9aed6a560673ea8fcad7554456ab8826d67743af1304086076f7a5b9fc88ba6a1f5741243f4637fbc15d284f417166b4354d867&lt;/LI-CODE&gt;&lt;P&gt;4. Create a secure volue&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;# ./dd if=/dev/zero of=encrypted.img bs=1M count=8
8+0 records in
8+0 records out
8388608 bytes (8.4 MB, 8.0 MiB) copied, 1.74919 s, 4.8 MB/s
# ./losetup /dev/loop0 encrypted.img&lt;/LI-CODE&gt;&lt;P&gt;5.&amp;nbsp;create a new device-mapper device named encrypted&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;# ./dmsetup -v create encrypted --table "0 $(./blockdev --getsz /dev/loop0) crypt capi:tk(cbc(aes))-plain :32:caam_tk:secke
Name:              encrypted
State:             ACTIVE
Read Ahead:        256
Tables present:    LIVE
Open count:        0
Event number:      0
Major, minor:      253, 0
Number of targets: 1

# ./dmsetup table --showkey encrypted
0 16384 crypt capi:tk(cbc(aes))-plain :32:caam_tk:seckey 0 7:0 0
# ls -l /dev/mapper/
total 0
crw-------    1 root     root       10, 236 Jan  1  1970 control
brw-------    1 root     root      253,   0 Mar  9 21:37 encrypted&lt;/LI-CODE&gt;&lt;P&gt;6,7,8 set mount point and mount&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;# ./mkfs.ext4 /dev/mapper/encrypted
mke2fs 1.47.0 (5-Feb-2023)
Creating filesystem with 8192 1k blocks and 2048 inodes

Allocating group tables: done
Writing inode tables: done
Creating journal (1024 blocks): done
Writing superblocks and filesystem accounting information: done

# mkdir -p ./mnt/encrypted
# mount -t ext4 /dev/mapper/encrypted ./mnt/encrypted/
# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root                18.3M     18.3M         0 100% /
..............
/dev/mmcblk0p1            7.4G     58.1M      7.3G   1% /media/mmcblk0p1
tmpfs                    58.0M    584.0K     57.4M   1% /root/.ssh
/dev/mapper/encrypted
                          6.4M     46.0K      5.8M   1% /jffs/dm_crypt/mnt/encrypted
&lt;/LI-CODE&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;When I execute the mount command, the serial port has the following information，I'm not sure if this is abnormal information&lt;/FONT&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;EXT4-fs (dm-0): mounted filesystem with ordered data mode. Opts: (null)&lt;/LI-CODE&gt;&lt;P&gt;9. write to device&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;# echo "hello,world"  &amp;gt; ./mnt/encrypted/readme.txt
# cat ./mnt/encrypted/readme.txt
hello,world&lt;/LI-CODE&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;According to step 8------At this level, everything data you write to /mnt/encrypted is encrypted on the real block device /dev/loop0&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;I think the readme.txt file should be encrypted, but it is&amp;nbsp; unencrypted&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;STRONG&gt;I don't why and how to solve it&amp;nbsp;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;Best regards&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;haichao&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 10 Mar 2023 07:15:02 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1612940#M202550</guid>
      <dc:creator>haichao</dc:creator>
      <dc:date>2023-03-10T07:15:02Z</dc:date>
    </item>
    <item>
      <title>回复： dm_crypt    file in /mnt/encrypted unencrypt</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1613047#M202561</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/192970"&gt;@Harvey021&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I execute the following command：&lt;/P&gt;&lt;P&gt;# fdisk -l&lt;BR /&gt;Disk /dev/mmcblk0: 7580 MB, 7948206080 bytes, 15523840 sectors&lt;BR /&gt;966 cylinders, 255 heads, 63 sectors/track&lt;BR /&gt;Units: sectors of 1 * 512 = 512 bytes&lt;/P&gt;&lt;P&gt;Device Boot StartCHS EndCHS StartLBA EndLBA Sectors Size Id Type&lt;BR /&gt;/dev/mmcblk0p1 * 0,32,33 965,254,63 2048 15518789 15516742 7576M c Win95 FAT32 (LBA)&lt;BR /&gt;Disk /dev/dm-0: 8 MB, 8388608 bytes, 16384 sectors&lt;BR /&gt;1 cylinders, 255 heads, 63 sectors/track&lt;BR /&gt;Units: sectors of 1 * 512 = 512 bytes&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;Disk /dev/dm-0 doesn't contain a valid partition table&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;Is it the reason why there is no partition in dm-0? What partition method should I make&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Fri, 10 Mar 2023 09:05:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1613047#M202561</guid>
      <dc:creator>haichao</dc:creator>
      <dc:date>2023-03-10T09:05:42Z</dc:date>
    </item>
    <item>
      <title>回复： dm_crypt    file in /mnt/encrypted unencrypt</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1613082#M202565</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/192970"&gt;@Harvey021&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I already know why. It's explained on the document---“NAND flash is an MTD device, hence, DM-Crypt cannot be used with”， my flash is NAND flash, I made a big joke&lt;/P&gt;</description>
      <pubDate>Fri, 10 Mar 2023 09:50:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/dm-crypt-file-in-mnt-encrypted-unencrypt/m-p/1613082#M202565</guid>
      <dc:creator>haichao</dc:creator>
      <dc:date>2023-03-10T09:50:22Z</dc:date>
    </item>
  </channel>
</rss>

