<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.15"/> <meta name="viewport" content="width=device-width, initial-scale=1"/> <title>Crypto++: AsymmetricAlgorithm Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectalign" style="padding-left: 0.5em;"> <div id="projectname">Crypto++  <span id="projectnumber">7.0</span> </div> <div id="projectbrief">Free C++ class library of cryptographic schemes</div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.15 --> <script type="text/javascript" src="menudata.js"></script> <script type="text/javascript" src="menu.js"></script> <script type="text/javascript"> /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ $(function() { initMenu('',false,false,'search.php','Search'); }); /* @license-end */</script> <div id="main-nav"></div> </div><!-- top --> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="class_asymmetric_algorithm-members.html">List of all members</a> </div> <div class="headertitle"> <div class="title">AsymmetricAlgorithm Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div> </div> </div><!--header--> <div class="contents"> <p>Interface for asymmetric algorithms. <a href="class_asymmetric_algorithm.html#details">More...</a></p> <div id="dynsection-0" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;"> <img id="dynsection-0-trigger" src="closed.png" alt="+"/> Inheritance diagram for AsymmetricAlgorithm:</div> <div id="dynsection-0-summary" class="dynsummary" style="display:block;"> </div> <div id="dynsection-0-content" class="dyncontent" style="display:none;"> <div class="center"> <img src="class_asymmetric_algorithm.png" usemap="#AsymmetricAlgorithm_map" alt=""/> <map id="AsymmetricAlgorithm_map" name="AsymmetricAlgorithm_map"> <area href="class_algorithm.html" title="Interface for all crypto algorithms." alt="Algorithm" shape="rect" coords="3905,56,4676,80"/> <area href="class_clonable.html" title="Interface for cloning objects." alt="Clonable" shape="rect" coords="3905,0,4676,24"/> <area href="class_key_agreement_algorithm.html" title="Interface for key agreement algorithms." alt="KeyAgreementAlgorithm" shape="rect" coords="781,168,1552,192"/> <area href="class_private_key_algorithm.html" title="Interface for asymmetric algorithms using private keys." alt="PrivateKeyAlgorithm" shape="rect" coords="3905,168,4676,192"/> <area href="class_public_key_algorithm.html" title="Interface for asymmetric algorithms using public keys." alt="PublicKeyAlgorithm" shape="rect" coords="7029,168,7800,192"/> <area href="class_authenticated_key_agreement_domain.html" title="Interface for domains of authenticated key agreement protocols." alt="AuthenticatedKeyAgreementDomain" shape="rect" coords="0,224,771,248"/> <area href="class_simple_key_agreement_domain.html" title="Interface for domains of simple key agreement protocols." alt="SimpleKeyAgreementDomain" shape="rect" coords="1562,224,2333,248"/> <area href="class_p_k___decryptor.html" title="Interface for public-key decryptors." alt="PK_Decryptor" shape="rect" coords="3124,224,3895,248"/> <area href="class_p_k___signer.html" title="Interface for public-key signers." alt="PK_Signer" shape="rect" coords="4686,224,5457,248"/> <area href="class_p_k___encryptor.html" title="Interface for public-key encryptors." alt="PK_Encryptor" shape="rect" coords="6248,224,7019,248"/> <area href="class_p_k___verifier.html" title="Interface for public-key signature verifiers." alt="PK_Verifier" shape="rect" coords="7810,224,8581,248"/> <area href="class_d_h2.html" title="Unified Diffie-Hellman in GF(p)" alt="DH2" shape="rect" coords="781,280,1552,304"/> <area href="class_f_h_m_q_v___domain.html" title="Fully Hashed Menezes-Qu-Vanstone in GF(p)" alt="FHMQV_Domain< GROUP_PARAMETERS, COFACTOR_OPTION, HASH >" shape="rect" coords="781,336,1552,360"/> <area href="class_h_m_q_v___domain.html" title="Hashed Menezes-Qu-Vanstone in GF(p)" alt="HMQV_Domain< GROUP_PARAMETERS, COFACTOR_OPTION, HASH >" shape="rect" coords="781,392,1552,416"/> <area href="class_m_q_v___domain.html" title="MQV domain for performing authenticated key agreement." alt="MQV_Domain< GROUP_PARAMETERS, COFACTOR_OPTION >" shape="rect" coords="781,448,1552,472"/> <area href="class_d_l___simple_key_agreement_domain_base.html" title="Discrete Log (DL) simple key agreement base implementation." alt="DL_SimpleKeyAgreementDomainBase< T >" shape="rect" coords="2343,280,3114,304"/> <area href="class_d_l___simple_key_agreement_domain_base.html" alt="DL_SimpleKeyAgreementDomainBase< DL_GroupParameters_GFP_DefaultSafePrime ::Element >" shape="rect" coords="2343,336,3114,360"/> <area href="class_d_l___simple_key_agreement_domain_base.html" alt="DL_SimpleKeyAgreementDomainBase< GROUP_PARAMETERS::Element >" shape="rect" coords="2343,392,3114,416"/> <area href="class_x_t_r___d_h.html" title="XTR-DH with key validation." alt="XTR_DH" shape="rect" coords="2343,448,3114,472"/> <area href="class_d_l___crypto_system_base.html" alt="DL_CryptoSystemBase< PK_Decryptor, DL_PrivateKey< SCHEME_OPTIONS::Element > >" shape="rect" coords="3905,280,4676,304"/> <area href="class_d_l___crypto_system_base.html" alt="DL_CryptoSystemBase< PK_Decryptor, DL_PrivateKey< T > >" shape="rect" coords="3905,336,4676,360"/> <area href="class_p_k___fixed_length_crypto_system_impl.html" alt="PK_FixedLengthCryptoSystemImpl< PK_Decryptor >" shape="rect" coords="3905,392,4676,416"/> <area href="class_d_l___signature_scheme_base.html" alt="DL_SignatureSchemeBase< PK_Signer, DL_PrivateKey< SCHEME_OPTIONS::Element > >" shape="rect" coords="5467,280,6238,304"/> <area href="class_d_l___signature_scheme_base.html" alt="DL_SignatureSchemeBase< PK_Signer, DL_PrivateKey< T > >" shape="rect" coords="5467,336,6238,360"/> <area href="class_t_f___signature_scheme_base.html" alt="TF_SignatureSchemeBase< PK_Signer, TF_Base< RandomizedTrapdoorFunctionInverse, PK_SignatureMessageEncodingMethod > >" shape="rect" coords="5467,392,6238,416"/> <area href="class_d_l___crypto_system_base.html" alt="DL_CryptoSystemBase< PK_Encryptor, DL_PublicKey< SCHEME_OPTIONS::Element > >" shape="rect" coords="7029,280,7800,304"/> <area href="class_d_l___crypto_system_base.html" alt="DL_CryptoSystemBase< PK_Encryptor, DL_PublicKey< T > >" shape="rect" coords="7029,336,7800,360"/> <area href="class_p_k___fixed_length_crypto_system_impl.html" alt="PK_FixedLengthCryptoSystemImpl< PK_Encryptor >" shape="rect" coords="7029,392,7800,416"/> <area href="class_d_l___signature_scheme_base.html" alt="DL_SignatureSchemeBase< PK_Verifier, DL_PublicKey< SCHEME_OPTIONS::Element > >" shape="rect" coords="8591,280,9362,304"/> <area href="class_d_l___signature_scheme_base.html" alt="DL_SignatureSchemeBase< PK_Verifier, DL_PublicKey< T > >" shape="rect" coords="8591,336,9362,360"/> <area href="class_t_f___signature_scheme_base.html" alt="TF_SignatureSchemeBase< PK_Verifier, TF_Base< TrapdoorFunction, PK_SignatureMessageEncodingMethod > >" shape="rect" coords="8591,392,9362,416"/> </map> </div></div> <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr class="memitem:ad99d55413166b69a0a12e10d111926c8"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="class_crypto_material.html">CryptoMaterial</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_asymmetric_algorithm.html#ad99d55413166b69a0a12e10d111926c8">AccessMaterial</a> ()=0</td></tr> <tr class="memdesc:ad99d55413166b69a0a12e10d111926c8"><td class="mdescLeft"> </td><td class="mdescRight">Retrieves a reference to <a class="el" href="class_crypto_material.html" title="Interface for crypto material, such as public and private keys, and crypto parameters.">CryptoMaterial</a>. <a href="#ad99d55413166b69a0a12e10d111926c8">More...</a><br /></td></tr> <tr class="separator:ad99d55413166b69a0a12e10d111926c8"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:adf9cc798c5a2d20ab3436dbad8e6df2d"><td class="memItemLeft" align="right" valign="top">virtual const <a class="el" href="class_crypto_material.html">CryptoMaterial</a> & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_asymmetric_algorithm.html#adf9cc798c5a2d20ab3436dbad8e6df2d">GetMaterial</a> () const =0</td></tr> <tr class="memdesc:adf9cc798c5a2d20ab3436dbad8e6df2d"><td class="mdescLeft"> </td><td class="mdescRight">Retrieves a reference to <a class="el" href="class_crypto_material.html" title="Interface for crypto material, such as public and private keys, and crypto parameters.">CryptoMaterial</a>. <a href="#adf9cc798c5a2d20ab3436dbad8e6df2d">More...</a><br /></td></tr> <tr class="separator:adf9cc798c5a2d20ab3436dbad8e6df2d"><td class="memSeparator" colspan="2"> </td></tr> <tr class="inherit_header pub_methods_class_algorithm"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_class_algorithm')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="class_algorithm.html">Algorithm</a></td></tr> <tr class="memitem:a1c77f5117ca2cd881baf26a364cfc606 inherit pub_methods_class_algorithm"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_algorithm.html#a1c77f5117ca2cd881baf26a364cfc606">Algorithm</a> (bool checkSelfTestStatus=true)</td></tr> <tr class="memdesc:a1c77f5117ca2cd881baf26a364cfc606 inherit pub_methods_class_algorithm"><td class="mdescLeft"> </td><td class="mdescRight">Interface for all crypto algorithms. <a href="class_algorithm.html#a1c77f5117ca2cd881baf26a364cfc606">More...</a><br /></td></tr> <tr class="separator:a1c77f5117ca2cd881baf26a364cfc606 inherit pub_methods_class_algorithm"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a4f31510a192d1121856efe8ad0a9b844 inherit pub_methods_class_algorithm"><td class="memItemLeft" align="right" valign="top">virtual std::string </td><td class="memItemRight" valign="bottom"><a class="el" href="class_algorithm.html#a4f31510a192d1121856efe8ad0a9b844">AlgorithmName</a> () const</td></tr> <tr class="memdesc:a4f31510a192d1121856efe8ad0a9b844 inherit pub_methods_class_algorithm"><td class="mdescLeft"> </td><td class="mdescRight">Provides the name of this algorithm. <a href="class_algorithm.html#a4f31510a192d1121856efe8ad0a9b844">More...</a><br /></td></tr> <tr class="separator:a4f31510a192d1121856efe8ad0a9b844 inherit pub_methods_class_algorithm"><td class="memSeparator" colspan="2"> </td></tr> <tr class="inherit_header pub_methods_class_clonable"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_class_clonable')"><img src="closed.png" alt="-"/> Public Member Functions inherited from <a class="el" href="class_clonable.html">Clonable</a></td></tr> <tr class="memitem:ad0016ba2d505c23aa85aad49e6c19bb7 inherit pub_methods_class_clonable"><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="class_clonable.html">Clonable</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="class_clonable.html#ad0016ba2d505c23aa85aad49e6c19bb7">Clone</a> () const</td></tr> <tr class="memdesc:ad0016ba2d505c23aa85aad49e6c19bb7 inherit pub_methods_class_clonable"><td class="mdescLeft"> </td><td class="mdescRight">Copies this object. <a href="class_clonable.html#ad0016ba2d505c23aa85aad49e6c19bb7">More...</a><br /></td></tr> <tr class="separator:ad0016ba2d505c23aa85aad49e6c19bb7 inherit pub_methods_class_clonable"><td class="memSeparator" colspan="2"> </td></tr> </table> <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> <div class="textblock"><p>Interface for asymmetric algorithms. </p> <p>BERDecode() and DEREncode() were removed under Issue 569 and Commit 9b174e84de7a. Programs should use <code><a class="el" href="class_asymmetric_algorithm.html#ad99d55413166b69a0a12e10d111926c8" title="Retrieves a reference to CryptoMaterial.">AccessMaterial()</a>.Load(bt)</code> or <code><a class="el" href="class_asymmetric_algorithm.html#ad99d55413166b69a0a12e10d111926c8" title="Retrieves a reference to CryptoMaterial.">AccessMaterial()</a>.Save(bt)</code> instead. </p><dl class="section see"><dt>See also</dt><dd><a href="https://github.com/weidai11/cryptopp/issues/569">Issue 569</a> </dd></dl> <p class="definition">Definition at line <a class="el" href="cryptlib_8h_source.html#l02388">2388</a> of file <a class="el" href="cryptlib_8h_source.html">cryptlib.h</a>.</p> </div><h2 class="groupheader">Member Function Documentation</h2> <a id="ad99d55413166b69a0a12e10d111926c8"></a> <h2 class="memtitle"><span class="permalink"><a href="#ad99d55413166b69a0a12e10d111926c8">◆ </a></span>AccessMaterial()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual <a class="el" href="class_crypto_material.html">CryptoMaterial</a>& AsymmetricAlgorithm::AccessMaterial </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Retrieves a reference to <a class="el" href="class_crypto_material.html" title="Interface for crypto material, such as public and private keys, and crypto parameters.">CryptoMaterial</a>. </p> <dl class="section return"><dt>Returns</dt><dd>a reference to the crypto material </dd></dl> <p>Implemented in <a class="el" href="class_key_agreement_algorithm.html#ab9c52198ff0dd877243c9520d96beaaa">KeyAgreementAlgorithm</a>, <a class="el" href="class_private_key_algorithm.html#a48cf4528f16263f2200d5b908a0b8ffb">PrivateKeyAlgorithm</a>, and <a class="el" href="class_public_key_algorithm.html#a74b77db3086e07caf5506fda9ec204e7">PublicKeyAlgorithm</a>.</p> </div> </div> <a id="adf9cc798c5a2d20ab3436dbad8e6df2d"></a> <h2 class="memtitle"><span class="permalink"><a href="#adf9cc798c5a2d20ab3436dbad8e6df2d">◆ </a></span>GetMaterial()</h2> <div class="memitem"> <div class="memproto"> <table class="mlabels"> <tr> <td class="mlabels-left"> <table class="memname"> <tr> <td class="memname">virtual const <a class="el" href="class_crypto_material.html">CryptoMaterial</a>& AsymmetricAlgorithm::GetMaterial </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </td> <td class="mlabels-right"> <span class="mlabels"><span class="mlabel">pure virtual</span></span> </td> </tr> </table> </div><div class="memdoc"> <p>Retrieves a reference to <a class="el" href="class_crypto_material.html" title="Interface for crypto material, such as public and private keys, and crypto parameters.">CryptoMaterial</a>. </p> <dl class="section return"><dt>Returns</dt><dd>a const reference to the crypto material </dd></dl> <p>Implemented in <a class="el" href="class_key_agreement_algorithm.html#a3a1eb8e141b2f26a21efed7a1d7744c9">KeyAgreementAlgorithm</a>, <a class="el" href="class_private_key_algorithm.html#a59f3867165685cc6ac6be3f53d5f371b">PrivateKeyAlgorithm</a>, and <a class="el" href="class_public_key_algorithm.html#a8c2bb02751348ff151ad9d4756cafd74">PublicKeyAlgorithm</a>.</p> </div> </div> <hr/>The documentation for this class was generated from the following file:<ul> <li><a class="el" href="cryptlib_8h_source.html">cryptlib.h</a></li> </ul> </div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated on Wed Nov 27 2019 15:03:54 for Crypto++ by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.15 </small></address> </body> </html>