<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:DengXian;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"\@DengXian";
        panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
span.EmailStyle19
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal">Hello<o:p></o:p></p>
<p class="MsoNormal">I would like to give a proposal for the openssl 1.1 replacement in EDKII community.<o:p></o:p></p>
<p class="MsoNormal"><b><o:p> </o:p></b></p>
<p class="MsoNormal"><b>[Problem Statement]<o:p></o:p></b></p>
<p class="MsoNormal">Openssl 1.1 is about to EOL at September, 2023. We need find replacement.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Bugzilla:<o:p></o:p></p>
<p class="MsoNormal">1. Openssl3.0: <a href="https://bugzilla.tianocore.org/show_bug.cgi?id=3466">
https://bugzilla.tianocore.org/show_bug.cgi?id=3466</a><o:p></o:p></p>
<p class="MsoNormal">2. MbedTls: <a href="https://bugzilla.tianocore.org/show_bug.cgi?id=4177">
https://bugzilla.tianocore.org/show_bug.cgi?id=4177</a><o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><b>[POC result]<o:p></o:p></b></p>
<p class="MsoNormal">1. The natural successor is Openssl 3.0.<o:p></o:p></p>
<p class="MsoNormal">However, it brings size issue according to the POC evaluation -
<a href="https://edk2.groups.io/g/devel/topic/87479913">https://edk2.groups.io/g/devel/topic/87479913</a>.<o:p></o:p></p>
<p class="MsoNormal">The concern is that: The size of flash is fixed. If we naïve replace it directly, the existing platforms may be broken immediately.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">2. The alternative is MbedTls, which is much smaller.<o:p></o:p></p>
<p class="MsoNormal">However, there is feature gap, e.g. PKCS7 is not there.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">3. At same time, we evaluated other crypto library.<o:p></o:p></p>
<p class="MsoNormal">A. Intel-IPP: <a href="https://software.intel.com/en-us/intel-ipp">
https://software.intel.com/en-us/intel-ipp</a> , <a href="https://github.com/intel/ipp-crypto">
https://github.com/intel/ipp-crypto</a> (Apache license) - CON: Only crypto primitive, no certificate, no TLS<o:p></o:p></p>
<p class="MsoNormal">B. Libsodium: <a href="https://doc.libsodium.org/">https://doc.libsodium.org/</a>,
<a href="https://github.com/jedisct1/libsodium">https://github.com/jedisct1/libsodium</a> (ISC license) - CON: Only crypto primitive, no certificate, no TLS<o:p></o:p></p>
<p class="MsoNormal">C: BoringSSL: <a href="https://github.com/google/boringssl">
https://github.com/google/boringssl</a> (ISC license) – CON: Google only project. It says: “We don't recommend that third parties depend upon it.”<o:p></o:p></p>
<p class="MsoNormal">D: WolfSSL: <a href="https://www.wolfssl.com/">https://www.wolfssl.com/</a>,
<a href="https://github.com/wolfSSL/wolfssl">https://github.com/wolfSSL/wolfssl</a> (GPL license) - CON: GPL License issue.<o:p></o:p></p>
<p class="MsoNormal">E: BearSSL: <a href="https://bearssl.org/">https://bearssl.org/</a> (MIT license) – CON: Current version is 0.6. It is now considered beta-quality software.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><b>[Proposal]<o:p></o:p></b></p>
<p class="MsoNormal">1. Let’s put *<b>Openssl 3.0 POC</b>* to *<b>edk2-staging</b>*, and continue the research on how to reduce the size.<o:p></o:p></p>
<p class="MsoNormal">It is possible that we may need add MACRO to Openssl 3.0 to reduce the size. We can do POC and submit to openssl community.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">2. Let’s put *<b>MbedTls POC</b>* to *<b>edk2-staging</b>*, and continue the research on how to add missing features.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">3. If 1 or 2 can success, we can replace openssl 1.1 with one crypto lib.<o:p></o:p></p>
<p class="MsoNormal">If both 1 and 2 fail, we may use *<b>dual-crypto module</b>*. For example: mbedtls for PEI and openssl3.0 for DXE.<o:p></o:p></p>
<p class="MsoNormal">The source code size will become larger, more time to download the tree.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">4. We need control the quality of Openssl 1.1 replacement to avoid regression.<o:p></o:p></p>
<p class="MsoNormal">I propose the check-in criteria below:<o:p></o:p></p>
<p class="MsoNormal">A) Size delta < +10%<o:p></o:p></p>
<p class="MsoNormal">B) No API change.<o:p></o:p></p>
<p class="MsoNormal">C) All existing crypto usages in EDKII are covered, including:<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">UEFI Secure Boot - image verification/auth variable update (PKCS7)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">TCG Trusted Boot (SHA2/SM3)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">UEFI/PI FMP Capsule (PKCS7/PKCS1-v1.5-RSA)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">HTTPs Boot (TLS 1.2/1.3)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">BIOS Password (PKCS5-PBKDF)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">iSCSI (SHA2)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">HDD Password (SHA2)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">Hash2Dxe (SHA2)<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">Pkcs7Verify (PKCS7)<o:p></o:p></p>
<p class="MsoNormal">D) All crypto APIs in EDKII are covered besides above use case, including:<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">SHA3-ParallelHash<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">HMAC/HKDF<o:p></o:p></p>
<p class="MsoNormal" style="margin-left:.75in">ECC<o:p></o:p></p>
<p class="MsoNormal">E) All crypto test need pass.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Please review and provide your feedback. <o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><b>[Misc]<o:p></o:p></b></p>
<p class="MsoNormal">I would like to clarify my position on the original openssl 3.0 path, to avoid the misunderstanding:<o:p></o:p></p>
<p class="MsoNormal">A) I never expressed a desire to retain the OpenSSL 1.1. (I am sorry, if I did not say that clearly.)<o:p></o:p></p>
<p class="MsoNormal">B) I raised the concern that *<b>current OpenSSL 3.0 patch requires more improvement</b>*, because it will increase the size and break the existing platform.<o:p></o:p></p>
<p class="MsoNormal">It has no difference with other comment I give in the EDKII. If we want to check in, we need resolve the concern and ensure it can still work with existing platform.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Last but not least, I would like to suggest *<b>again</b>* that we maintain *<b>a civil and healthy community environment</b>*. (Thanks, Ard)<o:p></o:p></p>
<p class="MsoNormal">NOTE: All EDKII maintainers are doing volunteer work here. We are using development mailing list. Let’s focus on technical topic.<o:p></o:p></p>
<p class="MsoNormal">If anyone has any constructive technical idea, feel free to express your opinion, and we are happy to listen and discuss.<o:p></o:p></p>
<p class="MsoNormal">Any collaboration, patch submission, and validation are more than welcome.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">This is not a small work. We need all EDK-II community people’s help to deal with this OpenSSL 1.1 EOL.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thank you<o:p></o:p></p>
<p class="MsoNormal">Yao, Jiewen<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>


<div width="1" style="color:white;clear:both">_._,_._,_</div>
<hr>


Groups.io Links:<p>


  
    You receive all messages sent to this group.
  
  


<p>
<a target="_blank" href="https://edk2.groups.io/g/devel/message/99638">View/Reply Online (#99638)</a> |


  

|

  <a target="_blank" href="https://groups.io/mt/96741156/1813853">Mute This Topic</a>

| <a href="https://edk2.groups.io/g/devel/post">New Topic</a><br>




<a href="https://edk2.groups.io/g/devel/editsub/1813853">Your Subscription</a> |
<a href="mailto:devel+owner@edk2.groups.io">Contact Group Owner</a> |

<a href="https://edk2.groups.io/g/devel/unsub">Unsubscribe</a>

 [edk2-devel-archive@redhat.com]<br>
<div width="1" style="color:white;clear:both">_._,_._,_</div>