• <bdo id='1i4ef'></bdo><ul id='1i4ef'></ul>
    <i id='1i4ef'><tr id='1i4ef'><dt id='1i4ef'><q id='1i4ef'><span id='1i4ef'><b id='1i4ef'><form id='1i4ef'><ins id='1i4ef'></ins><ul id='1i4ef'></ul><sub id='1i4ef'></sub></form><legend id='1i4ef'></legend><bdo id='1i4ef'><pre id='1i4ef'><center id='1i4ef'></center></pre></bdo></b><th id='1i4ef'></th></span></q></dt></tr></i><div id='1i4ef'><tfoot id='1i4ef'></tfoot><dl id='1i4ef'><fieldset id='1i4ef'></fieldset></dl></div>
  • <small id='1i4ef'></small><noframes id='1i4ef'>

    <tfoot id='1i4ef'></tfoot>
  • <legend id='1i4ef'><style id='1i4ef'><dir id='1i4ef'><q id='1i4ef'></q></dir></style></legend>

      1. 从 x509Certificate2 启动 RSACryptoServiceProvider 的最佳方

        时间:2023-06-02
          <tbody id='UmkM4'></tbody>
            • <bdo id='UmkM4'></bdo><ul id='UmkM4'></ul>

              <small id='UmkM4'></small><noframes id='UmkM4'>

            • <legend id='UmkM4'><style id='UmkM4'><dir id='UmkM4'><q id='UmkM4'></q></dir></style></legend>

                <tfoot id='UmkM4'></tfoot>

                <i id='UmkM4'><tr id='UmkM4'><dt id='UmkM4'><q id='UmkM4'><span id='UmkM4'><b id='UmkM4'><form id='UmkM4'><ins id='UmkM4'></ins><ul id='UmkM4'></ul><sub id='UmkM4'></sub></form><legend id='UmkM4'></legend><bdo id='UmkM4'><pre id='UmkM4'><center id='UmkM4'></center></pre></bdo></b><th id='UmkM4'></th></span></q></dt></tr></i><div id='UmkM4'><tfoot id='UmkM4'></tfoot><dl id='UmkM4'><fieldset id='UmkM4'></fieldset></dl></div>
                • 本文介绍了从 x509Certificate2 启动 RSACryptoServiceProvider 的最佳方式?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  限时送ChatGPT账号..

                  从我从密钥库中取出的 X509Certificate2 启动新的 RSACryptoServiceProvider 对象的最佳方法是什么?证书与公共(用于加密)和私有(用于解密)密钥相关联.

                  What is the best way to initate a new RSACryptoServiceProvider object from an X509Certificate2 I pulled out of a key store? The certificate is associated with both public (for encryption) and private (for decryption) keys.

                  我目前正在使用 FromXmlString 方法,但一定有更好的方法.

                  I'm current using the FromXmlString method but there must be a better way.

                  谢谢

                  推荐答案

                  RSACryptoServiceProvider publicKeyProvider = 
                      (RSACryptoServiceProvider)certificate.PublicKey.Key;
                  

                  RSACryptoServiceProvider privateKeyProvider = 
                      (RSACryptoServiceProvider)certificate.PrivateKey;
                  

                  证书的公钥或私钥属性的密钥属性是 AsymmetricAlgorithm 类型.

                  The key property on the public or private key property of the certificate is of type AsymmetricAlgorithm.

                  这篇关于从 x509Certificate2 启动 RSACryptoServiceProvider 的最佳方式?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:是否可以使用.net RSACryptoServiceProvider 使用私钥加 下一篇:对称加密 (AES):将 IV 和 Salt 与加密数据一起保存是

                  相关文章

                  最新文章

                  <small id='Vcv7U'></small><noframes id='Vcv7U'>

                  <legend id='Vcv7U'><style id='Vcv7U'><dir id='Vcv7U'><q id='Vcv7U'></q></dir></style></legend>
                  <tfoot id='Vcv7U'></tfoot>
                  1. <i id='Vcv7U'><tr id='Vcv7U'><dt id='Vcv7U'><q id='Vcv7U'><span id='Vcv7U'><b id='Vcv7U'><form id='Vcv7U'><ins id='Vcv7U'></ins><ul id='Vcv7U'></ul><sub id='Vcv7U'></sub></form><legend id='Vcv7U'></legend><bdo id='Vcv7U'><pre id='Vcv7U'><center id='Vcv7U'></center></pre></bdo></b><th id='Vcv7U'></th></span></q></dt></tr></i><div id='Vcv7U'><tfoot id='Vcv7U'></tfoot><dl id='Vcv7U'><fieldset id='Vcv7U'></fieldset></dl></div>
                    • <bdo id='Vcv7U'></bdo><ul id='Vcv7U'></ul>