<?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>topic Guidance to provision custom SCP03 keys in Secure Authentication</title>
    <link>https://community.nxp.com/t5/Secure-Authentication/Guidance-to-provision-custom-SCP03-keys/m-p/2179312#M1874</link>
    <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/59276"&gt;@Kan_Li&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;I’m working with an ESP32 host and SE050C1. Environment details:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;Plug &amp;amp; Trust: v3.0.6 (Mini)&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;SE050 applet version: &lt;STRONG&gt;03 01 01 6F FF 01 0B&lt;/STRONG&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;I can open a secure channel using the default keys, generate an EC keypair on the SE, and create a CSR successfully.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Now I’d like to &lt;STRONG&gt;provision my own SCP03 keyset (ENC/MAC/DEK, AES-256)&lt;/STRONG&gt; once, store it on the SE050 under a new key version, and thereafter always open the SCP03 session using that version.&lt;/P&gt;&lt;P&gt;What I need from you:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;API / Example for PUT KEY in&amp;nbsp; v3.0.6 (Mini)&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;In my Mini drop I see INS_GP_PUT_KEY defined, but I don’t find a higher-level helper like Se05x_API_PutKeys(), nxScp03_ChangeKeys(), or an ex_scp03_change_keys example.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Could you confirm whether Mini v3.0.6 includes an SCP03 key-rotation helper?&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;If yes: which source file(s) and function(s) should I call, and what headers do I include?&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;If no: please share the recommended way (and a minimal code sample) to send &lt;STRONG&gt;GlobalPlatform PUT KEY (CLA=0x80, INS=0xD8)&lt;/STRONG&gt; over an already-open SCP03 session using the Mini APDU transport (e.g., Se05x_API_Transceive/Se05x_API_SendAPDU), including the expected &lt;STRONG&gt;TLV format&lt;/STRONG&gt; for ENC/MAC/DEK and &lt;STRONG&gt;KCV&lt;/STRONG&gt; calculation .&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Auth context structure for AES (SCP03) in v3.0.6&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;My boot context is gex_sss_boot_ctx.ex_se05x_auth.&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;ex_se05x_auth.param.scp03.ex_static.&lt;SPAN class=""&gt;Enc&lt;/SPAN&gt;&lt;SPAN class=""&gt;/Mac/&lt;/SPAN&gt;&lt;SPAN class=""&gt;Dek&lt;/SPAN&gt; ex_se05x_auth.param.scp03.keyVer&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;I select AES via argv (--auth aes) and load keys into ex_static.{Enc,Mac,Dek} and the version into keyVer.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Please confirm the &lt;STRONG&gt;correct field names&lt;/STRONG&gt; for v3.0.6 Mini so I don’t rely on trial-and-error.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Reference implementation / paths&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;If there is an example in the full Plug &amp;amp; Trust (non-Mini) that demonstrates SCP03 key update, could you point me to the &lt;STRONG&gt;exact path and function name&lt;/STRONG&gt;&amp;nbsp;so I can mirror that logic in Mini? Typical names I looked for:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;examples/sss/ex_scp03_change_keys.*&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;hostlib/hostLib/libCommon/scp/nxScp03.*&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;hostlib/hostLib/libSE05X/src/*scp03* or any usage of INS_GP_PUT_KEY.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Versioning &amp;amp; key length&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;I plan to use &lt;STRONG&gt;AES-256&lt;/STRONG&gt; (32-byte keys) and a new key version (e.g., 0x11). Any constraints or best practices you recommend for &lt;STRONG&gt;key version&lt;/STRONG&gt; selection or &lt;STRONG&gt;minimum key length&lt;/STRONG&gt; on applet &lt;STRONG&gt;03 01 01 6F FF 01 0B&lt;/STRONG&gt;?&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Tooling alternative&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;If the recommended path is to provision once using&amp;nbsp;and then switch my firmware to always open with the new keys, could you share the tool name/command (and where to get it).&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;My immediate blocker is the lack of a callable helper for &lt;STRONG&gt;PUT KEY&lt;/STRONG&gt; in Mini; I’m happy to implement a raw APDU if you can share the &lt;STRONG&gt;exact APDU build and send sequence&lt;/STRONG&gt; expected by the SE050 in this applet version.&lt;/P&gt;&lt;P&gt;Thanks a lot for your guidance!&lt;/P&gt;&lt;P&gt;Best regards,&lt;BR /&gt;Reddy&lt;/P&gt;</description>
    <pubDate>Thu, 02 Oct 2025 11:45:05 GMT</pubDate>
    <dc:creator>Rutwik0409</dc:creator>
    <dc:date>2025-10-02T11:45:05Z</dc:date>
    <item>
      <title>Guidance to provision custom SCP03 keys</title>
      <link>https://community.nxp.com/t5/Secure-Authentication/Guidance-to-provision-custom-SCP03-keys/m-p/2179312#M1874</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/59276"&gt;@Kan_Li&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;I’m working with an ESP32 host and SE050C1. Environment details:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;Plug &amp;amp; Trust: v3.0.6 (Mini)&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;SE050 applet version: &lt;STRONG&gt;03 01 01 6F FF 01 0B&lt;/STRONG&gt;&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;I can open a secure channel using the default keys, generate an EC keypair on the SE, and create a CSR successfully.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Now I’d like to &lt;STRONG&gt;provision my own SCP03 keyset (ENC/MAC/DEK, AES-256)&lt;/STRONG&gt; once, store it on the SE050 under a new key version, and thereafter always open the SCP03 session using that version.&lt;/P&gt;&lt;P&gt;What I need from you:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;API / Example for PUT KEY in&amp;nbsp; v3.0.6 (Mini)&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;In my Mini drop I see INS_GP_PUT_KEY defined, but I don’t find a higher-level helper like Se05x_API_PutKeys(), nxScp03_ChangeKeys(), or an ex_scp03_change_keys example.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Could you confirm whether Mini v3.0.6 includes an SCP03 key-rotation helper?&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;If yes: which source file(s) and function(s) should I call, and what headers do I include?&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;If no: please share the recommended way (and a minimal code sample) to send &lt;STRONG&gt;GlobalPlatform PUT KEY (CLA=0x80, INS=0xD8)&lt;/STRONG&gt; over an already-open SCP03 session using the Mini APDU transport (e.g., Se05x_API_Transceive/Se05x_API_SendAPDU), including the expected &lt;STRONG&gt;TLV format&lt;/STRONG&gt; for ENC/MAC/DEK and &lt;STRONG&gt;KCV&lt;/STRONG&gt; calculation .&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Auth context structure for AES (SCP03) in v3.0.6&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;My boot context is gex_sss_boot_ctx.ex_se05x_auth.&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;SPAN&gt;ex_se05x_auth.param.scp03.ex_static.&lt;SPAN class=""&gt;Enc&lt;/SPAN&gt;&lt;SPAN class=""&gt;/Mac/&lt;/SPAN&gt;&lt;SPAN class=""&gt;Dek&lt;/SPAN&gt; ex_se05x_auth.param.scp03.keyVer&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;I select AES via argv (--auth aes) and load keys into ex_static.{Enc,Mac,Dek} and the version into keyVer.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;Please confirm the &lt;STRONG&gt;correct field names&lt;/STRONG&gt; for v3.0.6 Mini so I don’t rely on trial-and-error.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Reference implementation / paths&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;If there is an example in the full Plug &amp;amp; Trust (non-Mini) that demonstrates SCP03 key update, could you point me to the &lt;STRONG&gt;exact path and function name&lt;/STRONG&gt;&amp;nbsp;so I can mirror that logic in Mini? Typical names I looked for:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;examples/sss/ex_scp03_change_keys.*&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;hostlib/hostLib/libCommon/scp/nxScp03.*&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;hostlib/hostLib/libSE05X/src/*scp03* or any usage of INS_GP_PUT_KEY.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Versioning &amp;amp; key length&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;I plan to use &lt;STRONG&gt;AES-256&lt;/STRONG&gt; (32-byte keys) and a new key version (e.g., 0x11). Any constraints or best practices you recommend for &lt;STRONG&gt;key version&lt;/STRONG&gt; selection or &lt;STRONG&gt;minimum key length&lt;/STRONG&gt; on applet &lt;STRONG&gt;03 01 01 6F FF 01 0B&lt;/STRONG&gt;?&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P&gt;&lt;STRONG&gt;Tooling alternative&lt;/STRONG&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P&gt;If the recommended path is to provision once using&amp;nbsp;and then switch my firmware to always open with the new keys, could you share the tool name/command (and where to get it).&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;My immediate blocker is the lack of a callable helper for &lt;STRONG&gt;PUT KEY&lt;/STRONG&gt; in Mini; I’m happy to implement a raw APDU if you can share the &lt;STRONG&gt;exact APDU build and send sequence&lt;/STRONG&gt; expected by the SE050 in this applet version.&lt;/P&gt;&lt;P&gt;Thanks a lot for your guidance!&lt;/P&gt;&lt;P&gt;Best regards,&lt;BR /&gt;Reddy&lt;/P&gt;</description>
      <pubDate>Thu, 02 Oct 2025 11:45:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Secure-Authentication/Guidance-to-provision-custom-SCP03-keys/m-p/2179312#M1874</guid>
      <dc:creator>Rutwik0409</dc:creator>
      <dc:date>2025-10-02T11:45:05Z</dc:date>
    </item>
    <item>
      <title>Re: Guidance to provision custom SCP03 keys</title>
      <link>https://community.nxp.com/t5/Secure-Authentication/Guidance-to-provision-custom-SCP03-keys/m-p/2183610#M1878</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/254544"&gt;@Rutwik0409&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So far we just provide PlatformSCP key rotation demo in the full version and nano version of the MW, but I think you just need to run this kind of application once per device life, so you may try to port the nano package to your platform as a quick solution. Please kindly refer to&amp;nbsp;&lt;A href="https://github.com/NXPPlugNTrust/nano-package/tree/master/examples/se05x_rotate_scp03_keys" target="_blank"&gt;https://github.com/NXPPlugNTrust/nano-package/tree/master/examples/se05x_rotate_scp03_keys&lt;/A&gt;&amp;nbsp;for details.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope that helps,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have a great day,&lt;BR /&gt;Kan&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;-------------------------------------------------------------------------------&lt;BR /&gt;Note:&lt;BR /&gt;- If this post answers your question, please click the "Mark Correct" button. Thank you!&lt;BR /&gt;- We are following threads for 7 weeks after the last post, later replies are ignored&lt;BR /&gt;Please open a new thread and refer to the closed one, if you have a related question at a later point in time.&lt;BR /&gt;-------------------------------------------------------------------------------&lt;/P&gt;</description>
      <pubDate>Fri, 10 Oct 2025 06:55:09 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Secure-Authentication/Guidance-to-provision-custom-SCP03-keys/m-p/2183610#M1878</guid>
      <dc:creator>Kan_Li</dc:creator>
      <dc:date>2025-10-10T06:55:09Z</dc:date>
    </item>
  </channel>
</rss>

