<?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>Secure AuthenticationのトピックRe: openssl provier error when generate key</title>
    <link>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1989829#M1747</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/243015"&gt;@chanyoung&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The openssl provider generates RSA in plain mode by default, which is not supported on SE050F, if you want to use provider to generates RSA CRT instead, just change the following&amp;nbsp;kSSS_CipherType_RSA to&amp;nbsp;kSSS_CipherType_RSA_CRT in&amp;nbsp;sssProvider_main.h .&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Kan_Li_0-1730960781906.png" style="width: 642px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/309117iBF71B508CA606FBA/image-dimensions/642x284?v=v2" width="642" height="284" role="button" title="Kan_Li_0-1730960781906.png" alt="Kan_Li_0-1730960781906.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;please also note RSA key length &amp;lt;2048 bits is not supported on SE050F either.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW, as provider doesn't support Key ID as a parameter, the default key ID is set as&amp;nbsp; "0xEF000011", but you may modify it in&amp;nbsp;sssProvider_key_mgmt_rsa.c. Alternatively you may use SETool instead to generate RSA key pairs in SE050F.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Kan_Li_1-1730961155046.png" style="width: 606px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/309119i2D840466DDE3A2CA/image-dimensions/606x178?v=v2" width="606" height="178" role="button" title="Kan_Li_1-1730961155046.png" alt="Kan_Li_1-1730961155046.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Please refer to&amp;nbsp;se05x_mw_v04.05.01/simw-top/doc/demos/se05x/seTool/Readme.html for more details.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&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;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 07 Nov 2024 06:33:33 GMT</pubDate>
    <dc:creator>Kan_Li</dc:creator>
    <dc:date>2024-11-07T06:33:33Z</dc:date>
    <item>
      <title>openssl provier error when generate key</title>
      <link>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1989030#M1746</link>
      <description>&lt;P&gt;hello.&lt;/P&gt;&lt;P&gt;An error occurred while running the test example.&lt;/P&gt;&lt;P&gt;The environment is raspberry pi + OM-SE050ARD0-F + openssl3 + provider&lt;/P&gt;&lt;P&gt;While creating a key pair in se050, the following error occurred and ended.&lt;/P&gt;&lt;P&gt;Could I ask for some advice?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;mw version : 4.5.1&lt;/P&gt;&lt;P&gt;PTMW_APPLET : SE050_C&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;$ openssl genrsa --provider /usr/local/lib/libsssProvider.so --provider default -out tls_client_key_ref_0xEF000011.pem 2048
App   :INFO :Using PortName='/dev/i2c-1' (ENV: EX_SSS_BOOT_SSS_PORT=/dev/i2c-1)
App   :WARN :Using SCP03 keys from:'/tmp/SE05X/plain_scp.txt' (FILE=/tmp/SE05X/plain_scp.txt)
sss   :INFO :atr (Len=35)
      00 A0 00 00    03 96 04 03    E8 00 FE 02    0B 03 E8 08
      01 00 00 00    00 64 00 00    0A 4A 43 4F    50 34 20 41
      54 50 4F
App   :INFO :Using PortName='/dev/i2c-1' (ENV: EX_SSS_BOOT_SSS_PORT=/dev/i2c-1)
App   :WARN :Using SCP03 keys from:'/tmp/SE05X/plain_scp.txt' (FILE=/tmp/SE05X/plain_scp.txt)
sss   :INFO :atr (Len=35)
      00 A0 00 00    03 96 04 03    E8 00 FE 02    0B 03 E8 08
      01 00 00 00    00 64 00 00    0A 4A 43 4F    50 34 20 41
      54 50 4F
sssprov-flw: Generate RSA key inside SE05x
sss   :WARN :nxEnsure:'ret == SM_OK' failed. At Line:7837 Function:sss_se05x_TXn
sss   :WARN :nxEnsure:'status == SM_OK' failed. At Line:4063 Function:sss_se05x_key_store_generate_key
App   :WARN :nxEnsure:'status == kStatus_SSS_Success' failed. At Line:471 Function:sss_keymgmt_rsa_gen
genrsa: Error generating RSA key&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Nov 2024 16:10:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1989030#M1746</guid>
      <dc:creator>chanyoung</dc:creator>
      <dc:date>2024-11-06T16:10:35Z</dc:date>
    </item>
    <item>
      <title>Re: openssl provier error when generate key</title>
      <link>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1989829#M1747</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/243015"&gt;@chanyoung&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The openssl provider generates RSA in plain mode by default, which is not supported on SE050F, if you want to use provider to generates RSA CRT instead, just change the following&amp;nbsp;kSSS_CipherType_RSA to&amp;nbsp;kSSS_CipherType_RSA_CRT in&amp;nbsp;sssProvider_main.h .&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Kan_Li_0-1730960781906.png" style="width: 642px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/309117iBF71B508CA606FBA/image-dimensions/642x284?v=v2" width="642" height="284" role="button" title="Kan_Li_0-1730960781906.png" alt="Kan_Li_0-1730960781906.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;please also note RSA key length &amp;lt;2048 bits is not supported on SE050F either.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;BTW, as provider doesn't support Key ID as a parameter, the default key ID is set as&amp;nbsp; "0xEF000011", but you may modify it in&amp;nbsp;sssProvider_key_mgmt_rsa.c. Alternatively you may use SETool instead to generate RSA key pairs in SE050F.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Kan_Li_1-1730961155046.png" style="width: 606px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/309119i2D840466DDE3A2CA/image-dimensions/606x178?v=v2" width="606" height="178" role="button" title="Kan_Li_1-1730961155046.png" alt="Kan_Li_1-1730961155046.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Please refer to&amp;nbsp;se05x_mw_v04.05.01/simw-top/doc/demos/se05x/seTool/Readme.html for more details.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&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;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 07 Nov 2024 06:33:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1989829#M1747</guid>
      <dc:creator>Kan_Li</dc:creator>
      <dc:date>2024-11-07T06:33:33Z</dc:date>
    </item>
    <item>
      <title>Re: openssl provier error when generate key</title>
      <link>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1990073#M1749</link>
      <description>&lt;P&gt;thank you for your reply&lt;BR /&gt;I modified it according to the advice and confirmed that it was created normally.&lt;/P&gt;&lt;P&gt;But there's one more problem&lt;BR /&gt;During the process of creating a CSR by calling the created key pair, the program ends without being created.&lt;/P&gt;&lt;P&gt;Is it impossible to create it with RSA? Or I would like to know if there is another way&lt;/P&gt;&lt;P&gt;Additionally, here is the full script of the example I am referring to.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;TLS client example using RSA keys&lt;/H3&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;# Create Root CA key pair and certificate&lt;BR /&gt;openssl genrsa -out tls_rootca_key.pem 2048&lt;BR /&gt;openssl req -x509 -new -nodes -key tls_rootca_key.pem -subj "/OU=NXP Plug Trust CA/CN=NXP RootCAvExxx" -days 4380 -out tls_rootca.cer&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;# Create client key inside secure element&lt;BR /&gt;openssl genrsa --provider /usr/local/lib/libsssProvider.so --provider default -out tls_client_key_ref_0xEF000011.pem 2048&lt;/P&gt;&lt;P&gt;# Create Client key CSR. Use the provider to access the client key created in the previous file.&lt;BR /&gt;openssl req -new --provider /usr/local/lib/libsssProvider.so --provider default -key tls_client_key_ref_0xEF000011.pem -subj "/CN=NXP_SE050_TLS_CLIENT_RSA" -out tls_client.csr&lt;/P&gt;&lt;P&gt;# Create Client certificate&lt;BR /&gt;openssl x509 -req --provider default -in tls_client.csr -CAcreateserial -out tls_client.cer -days 5000 -CA tls_rootca.cer -CAkey tls_rootca_key.pem&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;# Create Server key pair and certificate&lt;BR /&gt;openssl genrsa -out tls_server_key.pem 2048&lt;BR /&gt;openssl req -new -key tls_server_key.pem -subj "/CN=NXP_SE050_TLS_SERVER_RSA" -out tls_server.csr&lt;BR /&gt;openssl x509 -req -sha256 -days 4380 -in tls_server.csr -CAcreateserial -CA tls_rootca.cer -CAkey tls_rootca_key.pem -out tls_server.cer&lt;/P&gt;</description>
      <pubDate>Thu, 07 Nov 2024 09:57:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1990073#M1749</guid>
      <dc:creator>chanyoung</dc:creator>
      <dc:date>2024-11-07T09:57:19Z</dc:date>
    </item>
    <item>
      <title>Re: openssl provier error when generate key</title>
      <link>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1991561#M1750</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/243015"&gt;@chanyoung&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes, it is possible to use RSA in TLS client demo, but if you use ref key instead, you'd better use the access Manager together with the openssl provider. Please kindly refer to&amp;nbsp;simw-top/doc/hostlib/hostLib/accessManager/doc/accessManager.html for more details.&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>Mon, 11 Nov 2024 02:52:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Secure-Authentication/openssl-provier-error-when-generate-key/m-p/1991561#M1750</guid>
      <dc:creator>Kan_Li</dc:creator>
      <dc:date>2024-11-11T02:52:53Z</dc:date>
    </item>
  </channel>
</rss>

