group___epid_common.html 67 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066
  1. <!-- HTML header for doxygen 1.8.10-->
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  6. <meta http-equiv="X-UA-Compatible" content="IE=9"/>
  7. <meta name="generator" content="Doxygen 1.8.11"/>
  8. <title>Intel&reg; Enhanced Privacy ID SDK: common</title>
  9. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  10. <script type="text/javascript" src="jquery.js"></script>
  11. <script type="text/javascript" src="dynsections.js"></script>
  12. <link href="navtree.css" rel="stylesheet" type="text/css"/>
  13. <script type="text/javascript" src="resize.js"></script>
  14. <script type="text/javascript" src="navtreedata.js"></script>
  15. <script type="text/javascript" src="navtree.js"></script>
  16. <script type="text/javascript">
  17. $(document).ready(initResizable);
  18. $(window).load(resizeHeight);
  19. </script>
  20. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  21. <link href="epidstyle.css" rel="stylesheet" type="text/css"/>
  22. </head>
  23. <body>
  24. <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
  25. <div id="titlearea">
  26. <table cellspacing="0" cellpadding="0">
  27. <tbody>
  28. <tr style="height: 56px;">
  29. <td id="projectalign" style="padding-left: 0.5em;">
  30. <div id="projectname"><a
  31. onclick="storeLink('index.html')"
  32. id="projectlink"
  33. class="index.html"
  34. href="index.html">Intel&reg; Enhanced Privacy ID SDK</a>
  35. &#160;<span id="projectnumber">2.0.0</span>
  36. </div>
  37. </td>
  38. </tr>
  39. </tbody>
  40. </table>
  41. </div>
  42. <!-- end header part -->
  43. <!-- Generated by Doxygen 1.8.11 -->
  44. </div><!-- top -->
  45. <div id="side-nav" class="ui-resizable side-nav-resizable">
  46. <div id="nav-tree">
  47. <div id="nav-tree-contents">
  48. <div id="nav-sync" class="sync"></div>
  49. </div>
  50. </div>
  51. <div id="splitbar" style="-moz-user-select:none;"
  52. class="ui-resizable-handle">
  53. </div>
  54. </div>
  55. <script type="text/javascript">
  56. $(document).ready(function(){initNavTree('group___epid_common.html','');});
  57. </script>
  58. <div id="doc-content">
  59. <div class="header">
  60. <div class="summary">
  61. <a href="#groups">Modules</a> &#124;
  62. <a href="#nested-classes">Data Structures</a> &#124;
  63. <a href="#define-members">Macros</a> &#124;
  64. <a href="#typedef-members">Typedefs</a> &#124;
  65. <a href="#func-members">Functions</a> </div>
  66. <div class="headertitle">
  67. <div class="title">common<div class="ingroups"><a class="el" href="group___epid_module.html">epid</a></div></div> </div>
  68. </div><!--header-->
  69. <div class="contents">
  70. <p>Common code shared between core sub-components.
  71. <a href="#details">More...</a></p>
  72. <table class="memberdecls">
  73. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="groups"></a>
  74. Modules</h2></td></tr>
  75. <tr class="memitem:group___epid_math"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_math.html">math</a></td></tr>
  76. <tr class="memdesc:group___epid_math"><td class="mdescLeft">&#160;</td><td class="mdescRight">Math Primitives and Group Operations. <br /></td></tr>
  77. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  78. <tr class="memitem:group___error_codes"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___error_codes.html">errors</a></td></tr>
  79. <tr class="memdesc:group___error_codes"><td class="mdescLeft">&#160;</td><td class="mdescRight">Error reporting interface. <br /></td></tr>
  80. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  81. <tr class="memitem:group___file_parser"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___file_parser.html">fileparser</a></td></tr>
  82. <tr class="memdesc:group___file_parser"><td class="mdescLeft">&#160;</td><td class="mdescRight">Parser for issuer material. <br /></td></tr>
  83. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  84. <tr class="memitem:group___epid_print"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_print.html">print_utils</a></td></tr>
  85. <tr class="memdesc:group___epid_print"><td class="mdescLeft">&#160;</td><td class="mdescRight">Debug print routines. <br /></td></tr>
  86. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  87. <tr class="memitem:group___epid_types"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_types.html">types</a></td></tr>
  88. <tr class="memdesc:group___epid_types"><td class="mdescLeft">&#160;</td><td class="mdescRight">SDK data types. <br /></td></tr>
  89. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  90. </table><table class="memberdecls">
  91. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a>
  92. Data Structures</h2></td></tr>
  93. <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_commit_values.html">CommitValues</a></td></tr>
  94. <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Storage for values to create commitment in Sign and Verify algorithms. <a href="struct_commit_values.html#details">More...</a><br /></td></tr>
  95. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  96. <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_epid2_params__.html">Epid2Params_</a></td></tr>
  97. <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Internal representation of <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. <a href="struct_epid2_params__.html#details">More...</a><br /></td></tr>
  98. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  99. <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_group_pub_key__.html">GroupPubKey_</a></td></tr>
  100. <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Internal representation of <a class="el" href="struct_group_pub_key.html" title="Intel(R) EPID 2.0 group public key. ">GroupPubKey</a>. <a href="struct_group_pub_key__.html#details">More...</a><br /></td></tr>
  101. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  102. <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_priv_key__.html">PrivKey_</a></td></tr>
  103. <tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Internal implementation of <a class="el" href="struct_priv_key.html" title="Intel(R) EPID 2.0 private key. ">PrivKey</a>. <a href="struct_priv_key__.html#details">More...</a><br /></td></tr>
  104. <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
  105. </table><table class="memberdecls">
  106. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a>
  107. Macros</h2></td></tr>
  108. <tr class="memitem:ga29a7e07cd5181e738f98fc026979efca"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga29a7e07cd5181e738f98fc026979efca">ntohl</a>(u32) </td></tr>
  109. <tr class="memdesc:ga29a7e07cd5181e738f98fc026979efca"><td class="mdescLeft">&#160;</td><td class="mdescRight">Macros to transform oct str 32 into uint_32. <a href="#ga29a7e07cd5181e738f98fc026979efca">More...</a><br /></td></tr>
  110. <tr class="separator:ga29a7e07cd5181e738f98fc026979efca"><td class="memSeparator" colspan="2">&#160;</td></tr>
  111. <tr class="memitem:gab1587898f15de1b51cd5e799a43465ff"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gab1587898f15de1b51cd5e799a43465ff"></a>
  112. #define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gab1587898f15de1b51cd5e799a43465ff">EPID_ENABLE_EPID_ZERO_MEMORY_ON_FREE</a></td></tr>
  113. <tr class="memdesc:gab1587898f15de1b51cd5e799a43465ff"><td class="mdescLeft">&#160;</td><td class="mdescRight">When enabled secrets are wiped out from the memory by EpidFree. <br /></td></tr>
  114. <tr class="separator:gab1587898f15de1b51cd5e799a43465ff"><td class="memSeparator" colspan="2">&#160;</td></tr>
  115. <tr class="memitem:ga38fad13430eba25f9f9b05e35ecd22f8"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga38fad13430eba25f9f9b05e35ecd22f8"></a>
  116. #define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga38fad13430eba25f9f9b05e35ecd22f8">SAFE_ALLOC</a>(size)&#160;&#160;&#160;<a class="el" href="group___epid_common.html#gada170fd890504b013139f4a33033ae4b">EpidAlloc</a>(size);</td></tr>
  117. <tr class="memdesc:ga38fad13430eba25f9f9b05e35ecd22f8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Allocates zero initalized block of memory. <br /></td></tr>
  118. <tr class="separator:ga38fad13430eba25f9f9b05e35ecd22f8"><td class="memSeparator" colspan="2">&#160;</td></tr>
  119. <tr class="memitem:ga2ca3c202ee727774d55890e568621842"><td class="memItemLeft" align="right" valign="top">#define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga2ca3c202ee727774d55890e568621842">SAFE_FREE</a>(ptr) </td></tr>
  120. <tr class="memdesc:ga2ca3c202ee727774d55890e568621842"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deallocates space allocated by <a class="el" href="group___epid_common.html#ga38fad13430eba25f9f9b05e35ecd22f8" title="Allocates zero initalized block of memory. ">SAFE_ALLOC()</a> and nulls pointer. <a href="#ga2ca3c202ee727774d55890e568621842">More...</a><br /></td></tr>
  121. <tr class="separator:ga2ca3c202ee727774d55890e568621842"><td class="memSeparator" colspan="2">&#160;</td></tr>
  122. <tr class="memitem:ga41c113e15b695291199c27fac4bd53fa"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ga41c113e15b695291199c27fac4bd53fa"></a>
  123. #define&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga41c113e15b695291199c27fac4bd53fa">SAFE_REALLOC</a>(ptr, size)&#160;&#160;&#160;<a class="el" href="group___epid_common.html#ga6911838728d546e4a51d7bcb8404525c">EpidRealloc</a>((ptr), (size))</td></tr>
  124. <tr class="memdesc:ga41c113e15b695291199c27fac4bd53fa"><td class="mdescLeft">&#160;</td><td class="mdescRight">Changes the size of the memory block pointed to by ptr. <br /></td></tr>
  125. <tr class="separator:ga41c113e15b695291199c27fac4bd53fa"><td class="memSeparator" colspan="2">&#160;</td></tr>
  126. </table><table class="memberdecls">
  127. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
  128. Typedefs</h2></td></tr>
  129. <tr class="memitem:ga6119a2c0323a3fca9e502b24bc378c2c"><td class="memItemLeft" align="right" valign="top">typedef int(__STDCALL *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga6119a2c0323a3fca9e502b24bc378c2c">BitSupplier</a>) (unsigned int *rand_data, int num_bits, void *user_data)</td></tr>
  130. <tr class="memdesc:ga6119a2c0323a3fca9e502b24bc378c2c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Generates random data. <a href="#ga6119a2c0323a3fca9e502b24bc378c2c">More...</a><br /></td></tr>
  131. <tr class="separator:ga6119a2c0323a3fca9e502b24bc378c2c"><td class="memSeparator" colspan="2">&#160;</td></tr>
  132. </table><table class="memberdecls">
  133. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
  134. Functions</h2></td></tr>
  135. <tr class="memitem:ga2d54f4f222e965222024113c0420602d"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga2d54f4f222e965222024113c0420602d">SetKeySpecificCommitValues</a> (<a class="el" href="struct_group_pub_key.html">GroupPubKey</a> const *pub_key, <a class="el" href="struct_commit_values.html">CommitValues</a> *values)</td></tr>
  136. <tr class="memdesc:ga2d54f4f222e965222024113c0420602d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set group public key related fields from <a class="el" href="struct_commit_values.html" title="Storage for values to create commitment in Sign and Verify algorithms. ">CommitValues</a> structure. <a href="#ga2d54f4f222e965222024113c0420602d">More...</a><br /></td></tr>
  137. <tr class="separator:ga2d54f4f222e965222024113c0420602d"><td class="memSeparator" colspan="2">&#160;</td></tr>
  138. <tr class="memitem:ga3f3c3b965dd714179cbc2f8d96678ee0"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga3f3c3b965dd714179cbc2f8d96678ee0">SetCalculatedCommitValues</a> (<a class="el" href="struct_g1_elem_str.html">G1ElemStr</a> const *B, <a class="el" href="struct_g1_elem_str.html">G1ElemStr</a> const *K, <a class="el" href="struct_g1_elem_str.html">G1ElemStr</a> const *T, <a class="el" href="group___ec_group_primitives.html#ga85c1d5e106031b385a6e23e598ac98fa">EcPoint</a> const *R1, <a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *G1, <a class="el" href="group___finite_field_primitives.html#ga6cff5c7c06b07a87442b810ccc0a86fa">FfElement</a> const *R2, <a class="el" href="group___finite_field_primitives.html#gab281b24e336a8b3d7d90079d862d969e">FiniteField</a> *GT, <a class="el" href="struct_commit_values.html">CommitValues</a> *values)</td></tr>
  139. <tr class="memdesc:ga3f3c3b965dd714179cbc2f8d96678ee0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set <a class="el" href="struct_commit_values.html" title="Storage for values to create commitment in Sign and Verify algorithms. ">CommitValues</a> structure fields calculated in algorithm. <a href="#ga3f3c3b965dd714179cbc2f8d96678ee0">More...</a><br /></td></tr>
  140. <tr class="separator:ga3f3c3b965dd714179cbc2f8d96678ee0"><td class="memSeparator" colspan="2">&#160;</td></tr>
  141. <tr class="memitem:ga23f8ea0f7529e8e7a81bd88e607dda01"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga23f8ea0f7529e8e7a81bd88e607dda01">CalculateCommitmentHash</a> (<a class="el" href="struct_commit_values.html">CommitValues</a> const *values, <a class="el" href="group___finite_field_primitives.html#gab281b24e336a8b3d7d90079d862d969e">FiniteField</a> *Fp, <a class="el" href="group___epid_types.html#ga5e450438f6f9a5eacd0cf5ce354ec890">HashAlg</a> hash_alg, void const *msg, size_t msg_len, <a class="el" href="group___finite_field_primitives.html#ga6cff5c7c06b07a87442b810ccc0a86fa">FfElement</a> *c)</td></tr>
  142. <tr class="memdesc:ga23f8ea0f7529e8e7a81bd88e607dda01"><td class="mdescLeft">&#160;</td><td class="mdescRight">Calculate Fp.hash(t3 || m) for Sign and Verfiy algorithms. <a href="#ga23f8ea0f7529e8e7a81bd88e607dda01">More...</a><br /></td></tr>
  143. <tr class="separator:ga23f8ea0f7529e8e7a81bd88e607dda01"><td class="memSeparator" colspan="2">&#160;</td></tr>
  144. <tr class="memitem:ga5c396a5ac8a0e5ec1e02330c53420dce"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga5c396a5ac8a0e5ec1e02330c53420dce">CreateEpid2Params</a> (<a class="el" href="struct_epid2_params__.html">Epid2Params_</a> **params)</td></tr>
  145. <tr class="memdesc:ga5c396a5ac8a0e5ec1e02330c53420dce"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs the internal representation of <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. <a href="#ga5c396a5ac8a0e5ec1e02330c53420dce">More...</a><br /></td></tr>
  146. <tr class="separator:ga5c396a5ac8a0e5ec1e02330c53420dce"><td class="memSeparator" colspan="2">&#160;</td></tr>
  147. <tr class="memitem:gac22664b5f7df5cd4da1bd7b1b1e7912f"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gac22664b5f7df5cd4da1bd7b1b1e7912f">DeleteEpid2Params</a> (<a class="el" href="struct_epid2_params__.html">Epid2Params_</a> **epid_params)</td></tr>
  148. <tr class="memdesc:gac22664b5f7df5cd4da1bd7b1b1e7912f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deallocates storage for internal representation of <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. <a href="#gac22664b5f7df5cd4da1bd7b1b1e7912f">More...</a><br /></td></tr>
  149. <tr class="separator:gac22664b5f7df5cd4da1bd7b1b1e7912f"><td class="memSeparator" colspan="2">&#160;</td></tr>
  150. <tr class="memitem:ga20a575d3d538b0bac654fd57f20e2b30"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga20a575d3d538b0bac654fd57f20e2b30">CreateGroupPubKey</a> (<a class="el" href="struct_group_pub_key.html">GroupPubKey</a> const *pub_key_str, <a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *G1, <a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *G2, <a class="el" href="struct_group_pub_key__.html">GroupPubKey_</a> **pub_key)</td></tr>
  151. <tr class="memdesc:ga20a575d3d538b0bac654fd57f20e2b30"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs internal representation of <a class="el" href="struct_group_pub_key.html" title="Intel(R) EPID 2.0 group public key. ">GroupPubKey</a>. <a href="#ga20a575d3d538b0bac654fd57f20e2b30">More...</a><br /></td></tr>
  152. <tr class="separator:ga20a575d3d538b0bac654fd57f20e2b30"><td class="memSeparator" colspan="2">&#160;</td></tr>
  153. <tr class="memitem:ga07c9b47d326ee784aecb78195adffb8b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga07c9b47d326ee784aecb78195adffb8b">DeleteGroupPubKey</a> (<a class="el" href="struct_group_pub_key__.html">GroupPubKey_</a> **pub_key)</td></tr>
  154. <tr class="memdesc:ga07c9b47d326ee784aecb78195adffb8b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deallocates storage for internal representation of <a class="el" href="struct_group_pub_key.html" title="Intel(R) EPID 2.0 group public key. ">GroupPubKey</a>. <a href="#ga07c9b47d326ee784aecb78195adffb8b">More...</a><br /></td></tr>
  155. <tr class="separator:ga07c9b47d326ee784aecb78195adffb8b"><td class="memSeparator" colspan="2">&#160;</td></tr>
  156. <tr class="memitem:gad471f600f6032f432b99432fda97a070"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gad471f600f6032f432b99432fda97a070">EpidZeroMemory</a> (void *ptr, size_t size)</td></tr>
  157. <tr class="memdesc:gad471f600f6032f432b99432fda97a070"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clear information stored in block of memory pointer to by ptr. <a href="#gad471f600f6032f432b99432fda97a070">More...</a><br /></td></tr>
  158. <tr class="separator:gad471f600f6032f432b99432fda97a070"><td class="memSeparator" colspan="2">&#160;</td></tr>
  159. <tr class="memitem:gada170fd890504b013139f4a33033ae4b"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gada170fd890504b013139f4a33033ae4b">EpidAlloc</a> (size_t size)</td></tr>
  160. <tr class="memdesc:gada170fd890504b013139f4a33033ae4b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Allocates memory of size bytes. <a href="#gada170fd890504b013139f4a33033ae4b">More...</a><br /></td></tr>
  161. <tr class="separator:gada170fd890504b013139f4a33033ae4b"><td class="memSeparator" colspan="2">&#160;</td></tr>
  162. <tr class="memitem:ga6911838728d546e4a51d7bcb8404525c"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga6911838728d546e4a51d7bcb8404525c">EpidRealloc</a> (void *ptr, size_t new_size)</td></tr>
  163. <tr class="memdesc:ga6911838728d546e4a51d7bcb8404525c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Reallocates memory allocated by EpidAlloc. <a href="#ga6911838728d546e4a51d7bcb8404525c">More...</a><br /></td></tr>
  164. <tr class="separator:ga6911838728d546e4a51d7bcb8404525c"><td class="memSeparator" colspan="2">&#160;</td></tr>
  165. <tr class="memitem:gaeae76709e6bfc80c9d79ec4943ccc1ac"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gaeae76709e6bfc80c9d79ec4943ccc1ac">EpidFree</a> (void *ptr)</td></tr>
  166. <tr class="memdesc:gaeae76709e6bfc80c9d79ec4943ccc1ac"><td class="mdescLeft">&#160;</td><td class="mdescRight">Frees memory allocated by EpidAlloc. <a href="#gaeae76709e6bfc80c9d79ec4943ccc1ac">More...</a><br /></td></tr>
  167. <tr class="separator:gaeae76709e6bfc80c9d79ec4943ccc1ac"><td class="memSeparator" colspan="2">&#160;</td></tr>
  168. <tr class="memitem:ga4856121ac4bce4161a015a8a2b4f5b1c"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga4856121ac4bce4161a015a8a2b4f5b1c">memcpy_S</a> (void *dest, size_t destsz, void const *src, size_t count)</td></tr>
  169. <tr class="memdesc:ga4856121ac4bce4161a015a8a2b4f5b1c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Copies bytes between buffers with security ehancements. <a href="#ga4856121ac4bce4161a015a8a2b4f5b1c">More...</a><br /></td></tr>
  170. <tr class="separator:ga4856121ac4bce4161a015a8a2b4f5b1c"><td class="memSeparator" colspan="2">&#160;</td></tr>
  171. <tr class="memitem:ga23ec3f6c8b89eb63e04d2b1ec6fd2696"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdtypes_8h.html#ad5c9d4ba3dc37783a528b0925dc981a0">bool</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga23ec3f6c8b89eb63e04d2b1ec6fd2696">IsSigRlValid</a> (<a class="el" href="group___epid_types.html#gada666b48d0cbc301985405fde896f1de">GroupId</a> const *gid, <a class="el" href="struct_sig_rl.html">SigRl</a> const *sig_rl, size_t sig_rl_size)</td></tr>
  172. <tr class="memdesc:ga23ec3f6c8b89eb63e04d2b1ec6fd2696"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function to verify if signature based revocation list is valid. <a href="#ga23ec3f6c8b89eb63e04d2b1ec6fd2696">More...</a><br /></td></tr>
  173. <tr class="separator:ga23ec3f6c8b89eb63e04d2b1ec6fd2696"><td class="memSeparator" colspan="2">&#160;</td></tr>
  174. <tr class="memitem:ga00cb25d52726cef61a9a5266176c2a58"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdtypes_8h.html#ad5c9d4ba3dc37783a528b0925dc981a0">bool</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga00cb25d52726cef61a9a5266176c2a58">CreateStack</a> (size_t element_size, <a class="el" href="struct_stack.html">Stack</a> **stack)</td></tr>
  175. <tr class="memdesc:ga00cb25d52726cef61a9a5266176c2a58"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create stack. <a href="#ga00cb25d52726cef61a9a5266176c2a58">More...</a><br /></td></tr>
  176. <tr class="separator:ga00cb25d52726cef61a9a5266176c2a58"><td class="memSeparator" colspan="2">&#160;</td></tr>
  177. <tr class="memitem:ga0b4dedb867504e0148aa0e1fdf642b2b"><td class="memItemLeft" align="right" valign="top">void *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga0b4dedb867504e0148aa0e1fdf642b2b">StackPushN</a> (<a class="el" href="struct_stack.html">Stack</a> *stack, size_t n, void *elements)</td></tr>
  178. <tr class="memdesc:ga0b4dedb867504e0148aa0e1fdf642b2b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Push multiple elements to the stack. <a href="#ga0b4dedb867504e0148aa0e1fdf642b2b">More...</a><br /></td></tr>
  179. <tr class="separator:ga0b4dedb867504e0148aa0e1fdf642b2b"><td class="memSeparator" colspan="2">&#160;</td></tr>
  180. <tr class="memitem:ga8cdde2b366f4473f0a6965bcfea5b6a6"><td class="memItemLeft" align="right" valign="top"><a class="el" href="stdtypes_8h.html#ad5c9d4ba3dc37783a528b0925dc981a0">bool</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga8cdde2b366f4473f0a6965bcfea5b6a6">StackPopN</a> (<a class="el" href="struct_stack.html">Stack</a> *stack, size_t n, void *elements)</td></tr>
  181. <tr class="memdesc:ga8cdde2b366f4473f0a6965bcfea5b6a6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Pop multiple elements from the stack. <a href="#ga8cdde2b366f4473f0a6965bcfea5b6a6">More...</a><br /></td></tr>
  182. <tr class="separator:ga8cdde2b366f4473f0a6965bcfea5b6a6"><td class="memSeparator" colspan="2">&#160;</td></tr>
  183. <tr class="memitem:gab34066dc882ad63362c43c0790973fdc"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gab34066dc882ad63362c43c0790973fdc">StackGetSize</a> (<a class="el" href="struct_stack.html">Stack</a> const *stack)</td></tr>
  184. <tr class="memdesc:gab34066dc882ad63362c43c0790973fdc"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get number of elements in the stack. <a href="#gab34066dc882ad63362c43c0790973fdc">More...</a><br /></td></tr>
  185. <tr class="separator:gab34066dc882ad63362c43c0790973fdc"><td class="memSeparator" colspan="2">&#160;</td></tr>
  186. <tr class="memitem:ga3335a4754825c54840263aa4b2a9bf67"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga3335a4754825c54840263aa4b2a9bf67">DeleteStack</a> (<a class="el" href="struct_stack.html">Stack</a> **stack)</td></tr>
  187. <tr class="memdesc:ga3335a4754825c54840263aa4b2a9bf67"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deallocates memory used for the stack. <a href="#ga3335a4754825c54840263aa4b2a9bf67">More...</a><br /></td></tr>
  188. <tr class="separator:ga3335a4754825c54840263aa4b2a9bf67"><td class="memSeparator" colspan="2">&#160;</td></tr>
  189. <tr class="memitem:gae51985a0e811f4bbb2d70b62e35b881e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#gae51985a0e811f4bbb2d70b62e35b881e">CreatePrivKey</a> (<a class="el" href="struct_priv_key.html">PrivKey</a> const *priv_key_str, <a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *G1, <a class="el" href="group___finite_field_primitives.html#gab281b24e336a8b3d7d90079d862d969e">FiniteField</a> *Fp, <a class="el" href="struct_priv_key__.html">PrivKey_</a> **priv_key)</td></tr>
  190. <tr class="memdesc:gae51985a0e811f4bbb2d70b62e35b881e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs internal representation of <a class="el" href="struct_priv_key.html" title="Intel(R) EPID 2.0 private key. ">PrivKey</a>. <a href="#gae51985a0e811f4bbb2d70b62e35b881e">More...</a><br /></td></tr>
  191. <tr class="separator:gae51985a0e811f4bbb2d70b62e35b881e"><td class="memSeparator" colspan="2">&#160;</td></tr>
  192. <tr class="memitem:ga53db100214e65e362fa426508a240d12"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="group___epid_common.html#ga53db100214e65e362fa426508a240d12">DeletePrivKey</a> (<a class="el" href="struct_priv_key__.html">PrivKey_</a> **priv_key)</td></tr>
  193. <tr class="memdesc:ga53db100214e65e362fa426508a240d12"><td class="mdescLeft">&#160;</td><td class="mdescRight">Deallocate storage for internal representation of <a class="el" href="struct_priv_key.html" title="Intel(R) EPID 2.0 private key. ">PrivKey</a>. <a href="#ga53db100214e65e362fa426508a240d12">More...</a><br /></td></tr>
  194. <tr class="separator:ga53db100214e65e362fa426508a240d12"><td class="memSeparator" colspan="2">&#160;</td></tr>
  195. </table>
  196. <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
  197. <p>Common code shared between core sub-components. </p>
  198. <p>Constants, utility functions, and libraries that are used widely in the implementation or definition of APIs and samples. </p>
  199. <h2 class="groupheader">Macro Definition Documentation</h2>
  200. <a class="anchor" id="ga29a7e07cd5181e738f98fc026979efca"></a>
  201. <div class="memitem">
  202. <div class="memproto">
  203. <table class="memname">
  204. <tr>
  205. <td class="memname">#define ntohl</td>
  206. <td>(</td>
  207. <td class="paramtype">&#160;</td>
  208. <td class="paramname">u32</td><td>)</td>
  209. <td></td>
  210. </tr>
  211. </table>
  212. </div><div class="memdoc">
  213. <b>Value:</b><div class="fragment"><div class="line">((uint32_t)(((((<span class="keywordtype">unsigned</span> <span class="keywordtype">char</span>*)&amp;(u32))[0]) &lt;&lt; 24) + \</div><div class="line"> ((((<span class="keywordtype">unsigned</span> <span class="keywordtype">char</span>*)&amp;(u32))[1]) &lt;&lt; 16) + \</div><div class="line"> ((((<span class="keywordtype">unsigned</span> <span class="keywordtype">char</span>*)&amp;(u32))[2]) &lt;&lt; 8) + \</div><div class="line"> (((<span class="keywordtype">unsigned</span> <span class="keywordtype">char</span>*)&amp;(u32))[3])))</div></div><!-- fragment -->
  214. <p>Macros to transform oct str 32 into uint_32. </p>
  215. </div>
  216. </div>
  217. <a class="anchor" id="ga2ca3c202ee727774d55890e568621842"></a>
  218. <div class="memitem">
  219. <div class="memproto">
  220. <table class="memname">
  221. <tr>
  222. <td class="memname">#define SAFE_FREE</td>
  223. <td>(</td>
  224. <td class="paramtype">&#160;</td>
  225. <td class="paramname">ptr</td><td>)</td>
  226. <td></td>
  227. </tr>
  228. </table>
  229. </div><div class="memdoc">
  230. <b>Value:</b><div class="fragment"><div class="line">{ \</div><div class="line"> if (NULL != (ptr)) { \</div><div class="line"> EpidFree(ptr); \</div><div class="line"> (ptr) = NULL; \</div><div class="line"> } \</div><div class="line"> }</div></div><!-- fragment -->
  231. <p>Deallocates space allocated by <a class="el" href="group___epid_common.html#ga38fad13430eba25f9f9b05e35ecd22f8" title="Allocates zero initalized block of memory. ">SAFE_ALLOC()</a> and nulls pointer. </p>
  232. </div>
  233. </div>
  234. <h2 class="groupheader">Typedef Documentation</h2>
  235. <a class="anchor" id="ga6119a2c0323a3fca9e502b24bc378c2c"></a>
  236. <div class="memitem">
  237. <div class="memproto">
  238. <table class="memname">
  239. <tr>
  240. <td class="memname">typedef int(__STDCALL* BitSupplier) (unsigned int *rand_data, int num_bits, void *user_data)</td>
  241. </tr>
  242. </table>
  243. </div><div class="memdoc">
  244. <p>Generates random data. </p>
  245. <p>It is the responsibility of the caller of the SDK interfaces to implement a function of this prototype and to then pass a pointer to this function into methods that require it.</p>
  246. <dl class="params"><dt>Parameters</dt><dd>
  247. <table class="params">
  248. <tr><td class="paramdir">[out]</td><td class="paramname">rand_data</td><td>destination buffer </td></tr>
  249. <tr><td class="paramdir">[in]</td><td class="paramname">num_bits</td><td>size of rand_data in bits </td></tr>
  250. <tr><td class="paramdir">[in]</td><td class="paramname">user_data</td><td>user data passed through from api call.</td></tr>
  251. </table>
  252. </dd>
  253. </dl>
  254. <dl class="section return"><dt>Returns</dt><dd>zero on success and non-zero value on error. </dd></dl>
  255. </div>
  256. </div>
  257. <h2 class="groupheader">Function Documentation</h2>
  258. <a class="anchor" id="ga23f8ea0f7529e8e7a81bd88e607dda01"></a>
  259. <div class="memitem">
  260. <div class="memproto">
  261. <table class="memname">
  262. <tr>
  263. <td class="memname"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a> CalculateCommitmentHash </td>
  264. <td>(</td>
  265. <td class="paramtype"><a class="el" href="struct_commit_values.html">CommitValues</a> const *&#160;</td>
  266. <td class="paramname"><em>values</em>, </td>
  267. </tr>
  268. <tr>
  269. <td class="paramkey"></td>
  270. <td></td>
  271. <td class="paramtype"><a class="el" href="group___finite_field_primitives.html#gab281b24e336a8b3d7d90079d862d969e">FiniteField</a> *&#160;</td>
  272. <td class="paramname"><em>Fp</em>, </td>
  273. </tr>
  274. <tr>
  275. <td class="paramkey"></td>
  276. <td></td>
  277. <td class="paramtype"><a class="el" href="group___epid_types.html#ga5e450438f6f9a5eacd0cf5ce354ec890">HashAlg</a>&#160;</td>
  278. <td class="paramname"><em>hash_alg</em>, </td>
  279. </tr>
  280. <tr>
  281. <td class="paramkey"></td>
  282. <td></td>
  283. <td class="paramtype">void const *&#160;</td>
  284. <td class="paramname"><em>msg</em>, </td>
  285. </tr>
  286. <tr>
  287. <td class="paramkey"></td>
  288. <td></td>
  289. <td class="paramtype">size_t&#160;</td>
  290. <td class="paramname"><em>msg_len</em>, </td>
  291. </tr>
  292. <tr>
  293. <td class="paramkey"></td>
  294. <td></td>
  295. <td class="paramtype"><a class="el" href="group___finite_field_primitives.html#ga6cff5c7c06b07a87442b810ccc0a86fa">FfElement</a> *&#160;</td>
  296. <td class="paramname"><em>c</em>&#160;</td>
  297. </tr>
  298. <tr>
  299. <td></td>
  300. <td>)</td>
  301. <td></td><td></td>
  302. </tr>
  303. </table>
  304. </div><div class="memdoc">
  305. <p>Calculate Fp.hash(t3 || m) for Sign and Verfiy algorithms. </p>
  306. <p>Calculate c = Fp.hash(t3 || m) where t3 is Fp.hash(p || g1 || g2 || h1 || h2 || w || B || K || T || R1 || R2).</p>
  307. <dl class="params"><dt>Parameters</dt><dd>
  308. <table class="params">
  309. <tr><td class="paramdir">[in]</td><td class="paramname">values</td><td>Commit values to hash </td></tr>
  310. <tr><td class="paramdir">[in]</td><td class="paramname">Fp</td><td>Finite field to perfom hash operation in </td></tr>
  311. <tr><td class="paramdir">[in]</td><td class="paramname">hash_alg</td><td>Hash algorithm to use </td></tr>
  312. <tr><td class="paramdir">[in]</td><td class="paramname">msg</td><td>Message to hash </td></tr>
  313. <tr><td class="paramdir">[in]</td><td class="paramname">msg_len</td><td>Size of msg buffer in bytes </td></tr>
  314. <tr><td class="paramdir">[out]</td><td class="paramname">c</td><td>Result of calculation</td></tr>
  315. </table>
  316. </dd>
  317. </dl>
  318. <dl class="section return"><dt>Returns</dt><dd><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360" title="Return status for SDK functions. ">EpidStatus</a></dd></dl>
  319. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga2d54f4f222e965222024113c0420602d" title="Set group public key related fields from CommitValues structure. ">SetKeySpecificCommitValues</a> </dd>
  320. <dd>
  321. <a class="el" href="group___epid_common.html#ga3f3c3b965dd714179cbc2f8d96678ee0" title="Set CommitValues structure fields calculated in algorithm. ">SetCalculatedCommitValues</a> </dd></dl>
  322. </div>
  323. </div>
  324. <a class="anchor" id="ga5c396a5ac8a0e5ec1e02330c53420dce"></a>
  325. <div class="memitem">
  326. <div class="memproto">
  327. <table class="memname">
  328. <tr>
  329. <td class="memname"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a> CreateEpid2Params </td>
  330. <td>(</td>
  331. <td class="paramtype"><a class="el" href="struct_epid2_params__.html">Epid2Params_</a> **&#160;</td>
  332. <td class="paramname"><em>params</em></td><td>)</td>
  333. <td></td>
  334. </tr>
  335. </table>
  336. </div><div class="memdoc">
  337. <p>Constructs the internal representation of <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. </p>
  338. <p>Allocates memory for the internal representation of <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. Initialize the <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. Use <a class="el" href="group___epid_common.html#gac22664b5f7df5cd4da1bd7b1b1e7912f" title="Deallocates storage for internal representation of Epid2Params. ">DeleteEpid2Params()</a> to deallocate memory.</p>
  339. <dl class="params"><dt>Parameters</dt><dd>
  340. <table class="params">
  341. <tr><td class="paramdir">[in,out]</td><td class="paramname">params</td><td>Internal <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a></td></tr>
  342. </table>
  343. </dd>
  344. </dl>
  345. <dl class="section return"><dt>Returns</dt><dd><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360" title="Return status for SDK functions. ">EpidStatus</a> </dd></dl>
  346. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#gac22664b5f7df5cd4da1bd7b1b1e7912f" title="Deallocates storage for internal representation of Epid2Params. ">DeleteEpid2Params</a> </dd></dl>
  347. </div>
  348. </div>
  349. <a class="anchor" id="ga20a575d3d538b0bac654fd57f20e2b30"></a>
  350. <div class="memitem">
  351. <div class="memproto">
  352. <table class="memname">
  353. <tr>
  354. <td class="memname"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a> CreateGroupPubKey </td>
  355. <td>(</td>
  356. <td class="paramtype"><a class="el" href="struct_group_pub_key.html">GroupPubKey</a> const *&#160;</td>
  357. <td class="paramname"><em>pub_key_str</em>, </td>
  358. </tr>
  359. <tr>
  360. <td class="paramkey"></td>
  361. <td></td>
  362. <td class="paramtype"><a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *&#160;</td>
  363. <td class="paramname"><em>G1</em>, </td>
  364. </tr>
  365. <tr>
  366. <td class="paramkey"></td>
  367. <td></td>
  368. <td class="paramtype"><a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *&#160;</td>
  369. <td class="paramname"><em>G2</em>, </td>
  370. </tr>
  371. <tr>
  372. <td class="paramkey"></td>
  373. <td></td>
  374. <td class="paramtype"><a class="el" href="struct_group_pub_key__.html">GroupPubKey_</a> **&#160;</td>
  375. <td class="paramname"><em>pub_key</em>&#160;</td>
  376. </tr>
  377. <tr>
  378. <td></td>
  379. <td>)</td>
  380. <td></td><td></td>
  381. </tr>
  382. </table>
  383. </div><div class="memdoc">
  384. <p>Constructs internal representation of <a class="el" href="struct_group_pub_key.html" title="Intel(R) EPID 2.0 group public key. ">GroupPubKey</a>. </p>
  385. <p>Allocates memory and initializes gid, h1, h2, w parameters. Use <a class="el" href="group___epid_common.html#ga07c9b47d326ee784aecb78195adffb8b" title="Deallocates storage for internal representation of GroupPubKey. ">DeleteGroupPubKey()</a> to deallocate memory</p>
  386. <dl class="params"><dt>Parameters</dt><dd>
  387. <table class="params">
  388. <tr><td class="paramdir">[in]</td><td class="paramname">pub_key_str</td><td>Oct string representation of group public key </td></tr>
  389. <tr><td class="paramdir">[in]</td><td class="paramname">G1</td><td>EcGroup containing elements h1 and h2 </td></tr>
  390. <tr><td class="paramdir">[in]</td><td class="paramname">G2</td><td>EcGroup containing element w </td></tr>
  391. <tr><td class="paramdir">[out]</td><td class="paramname">pub_key</td><td>Group public key: (gid, h1, h2, w)</td></tr>
  392. </table>
  393. </dd>
  394. </dl>
  395. <dl class="section return"><dt>Returns</dt><dd><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360" title="Return status for SDK functions. ">EpidStatus</a> </dd></dl>
  396. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga07c9b47d326ee784aecb78195adffb8b" title="Deallocates storage for internal representation of GroupPubKey. ">DeleteGroupPubKey</a> </dd></dl>
  397. </div>
  398. </div>
  399. <a class="anchor" id="gae51985a0e811f4bbb2d70b62e35b881e"></a>
  400. <div class="memitem">
  401. <div class="memproto">
  402. <table class="memname">
  403. <tr>
  404. <td class="memname"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a> CreatePrivKey </td>
  405. <td>(</td>
  406. <td class="paramtype"><a class="el" href="struct_priv_key.html">PrivKey</a> const *&#160;</td>
  407. <td class="paramname"><em>priv_key_str</em>, </td>
  408. </tr>
  409. <tr>
  410. <td class="paramkey"></td>
  411. <td></td>
  412. <td class="paramtype"><a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *&#160;</td>
  413. <td class="paramname"><em>G1</em>, </td>
  414. </tr>
  415. <tr>
  416. <td class="paramkey"></td>
  417. <td></td>
  418. <td class="paramtype"><a class="el" href="group___finite_field_primitives.html#gab281b24e336a8b3d7d90079d862d969e">FiniteField</a> *&#160;</td>
  419. <td class="paramname"><em>Fp</em>, </td>
  420. </tr>
  421. <tr>
  422. <td class="paramkey"></td>
  423. <td></td>
  424. <td class="paramtype"><a class="el" href="struct_priv_key__.html">PrivKey_</a> **&#160;</td>
  425. <td class="paramname"><em>priv_key</em>&#160;</td>
  426. </tr>
  427. <tr>
  428. <td></td>
  429. <td>)</td>
  430. <td></td><td></td>
  431. </tr>
  432. </table>
  433. </div><div class="memdoc">
  434. <p>Constructs internal representation of <a class="el" href="struct_priv_key.html" title="Intel(R) EPID 2.0 private key. ">PrivKey</a>. </p>
  435. <p>This function allocates memory and initializes gid, A, x, f parameters.</p>
  436. <dl class="params"><dt>Parameters</dt><dd>
  437. <table class="params">
  438. <tr><td class="paramdir">[in]</td><td class="paramname">priv_key_str</td><td>Serialized representation of private key </td></tr>
  439. <tr><td class="paramdir">[in]</td><td class="paramname">G1</td><td>EcGroup containing element A </td></tr>
  440. <tr><td class="paramdir">[in]</td><td class="paramname">Fp</td><td>FiniteField containing elements x and f </td></tr>
  441. <tr><td class="paramdir">[out]</td><td class="paramname">priv_key</td><td>Newly created private key: (gid, A, x, f)</td></tr>
  442. </table>
  443. </dd>
  444. </dl>
  445. <dl class="section return"><dt>Returns</dt><dd><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360" title="Return status for SDK functions. ">EpidStatus</a> </dd></dl>
  446. </div>
  447. </div>
  448. <a class="anchor" id="ga00cb25d52726cef61a9a5266176c2a58"></a>
  449. <div class="memitem">
  450. <div class="memproto">
  451. <table class="memname">
  452. <tr>
  453. <td class="memname"><a class="el" href="stdtypes_8h.html#ad5c9d4ba3dc37783a528b0925dc981a0">bool</a> CreateStack </td>
  454. <td>(</td>
  455. <td class="paramtype">size_t&#160;</td>
  456. <td class="paramname"><em>element_size</em>, </td>
  457. </tr>
  458. <tr>
  459. <td class="paramkey"></td>
  460. <td></td>
  461. <td class="paramtype"><a class="el" href="struct_stack.html">Stack</a> **&#160;</td>
  462. <td class="paramname"><em>stack</em>&#160;</td>
  463. </tr>
  464. <tr>
  465. <td></td>
  466. <td>)</td>
  467. <td></td><td></td>
  468. </tr>
  469. </table>
  470. </div><div class="memdoc">
  471. <p>Create stack. </p>
  472. <dl class="params"><dt>Parameters</dt><dd>
  473. <table class="params">
  474. <tr><td class="paramdir">[in]</td><td class="paramname">element_size</td><td>Size of stack element </td></tr>
  475. <tr><td class="paramdir">[out]</td><td class="paramname">stack</td><td><a class="el" href="struct_stack.html" title="Internal representation of a Stack. ">Stack</a> context to be created</td></tr>
  476. </table>
  477. </dd>
  478. </dl>
  479. <dl class="section return"><dt>Returns</dt><dd>true is operation succeed, false if stack were failed to allocate</dd></dl>
  480. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga3335a4754825c54840263aa4b2a9bf67" title="Deallocates memory used for the stack. ">DeleteStack</a> </dd></dl>
  481. </div>
  482. </div>
  483. <a class="anchor" id="gac22664b5f7df5cd4da1bd7b1b1e7912f"></a>
  484. <div class="memitem">
  485. <div class="memproto">
  486. <table class="memname">
  487. <tr>
  488. <td class="memname">void DeleteEpid2Params </td>
  489. <td>(</td>
  490. <td class="paramtype"><a class="el" href="struct_epid2_params__.html">Epid2Params_</a> **&#160;</td>
  491. <td class="paramname"><em>epid_params</em></td><td>)</td>
  492. <td></td>
  493. </tr>
  494. </table>
  495. </div><div class="memdoc">
  496. <p>Deallocates storage for internal representation of <a class="el" href="struct_epid2_params.html" title="Intel(R) EPID 2.0 Parameters. ">Epid2Params</a>. </p>
  497. <p>Frees the memory and nulls the pointer.</p>
  498. <dl class="params"><dt>Parameters</dt><dd>
  499. <table class="params">
  500. <tr><td class="paramdir">[in,out]</td><td class="paramname">epid_params</td><td>params to be deallocated</td></tr>
  501. </table>
  502. </dd>
  503. </dl>
  504. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga5c396a5ac8a0e5ec1e02330c53420dce" title="Constructs the internal representation of Epid2Params. ">CreateEpid2Params</a> </dd></dl>
  505. </div>
  506. </div>
  507. <a class="anchor" id="ga07c9b47d326ee784aecb78195adffb8b"></a>
  508. <div class="memitem">
  509. <div class="memproto">
  510. <table class="memname">
  511. <tr>
  512. <td class="memname">void DeleteGroupPubKey </td>
  513. <td>(</td>
  514. <td class="paramtype"><a class="el" href="struct_group_pub_key__.html">GroupPubKey_</a> **&#160;</td>
  515. <td class="paramname"><em>pub_key</em></td><td>)</td>
  516. <td></td>
  517. </tr>
  518. </table>
  519. </div><div class="memdoc">
  520. <p>Deallocates storage for internal representation of <a class="el" href="struct_group_pub_key.html" title="Intel(R) EPID 2.0 group public key. ">GroupPubKey</a>. </p>
  521. <p>Frees memory pointed to by Group public key. Nulls the pointer.</p>
  522. <dl class="params"><dt>Parameters</dt><dd>
  523. <table class="params">
  524. <tr><td class="paramdir">[in]</td><td class="paramname">pub_key</td><td>Group public key to be freed</td></tr>
  525. </table>
  526. </dd>
  527. </dl>
  528. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga20a575d3d538b0bac654fd57f20e2b30" title="Constructs internal representation of GroupPubKey. ">CreateGroupPubKey</a> </dd></dl>
  529. </div>
  530. </div>
  531. <a class="anchor" id="ga53db100214e65e362fa426508a240d12"></a>
  532. <div class="memitem">
  533. <div class="memproto">
  534. <table class="memname">
  535. <tr>
  536. <td class="memname">void DeletePrivKey </td>
  537. <td>(</td>
  538. <td class="paramtype"><a class="el" href="struct_priv_key__.html">PrivKey_</a> **&#160;</td>
  539. <td class="paramname"><em>priv_key</em></td><td>)</td>
  540. <td></td>
  541. </tr>
  542. </table>
  543. </div><div class="memdoc">
  544. <p>Deallocate storage for internal representation of <a class="el" href="struct_priv_key.html" title="Intel(R) EPID 2.0 private key. ">PrivKey</a>. </p>
  545. <p>Frees memory pointed to by Member private key. Nulls the pointer.</p>
  546. <dl class="params"><dt>Parameters</dt><dd>
  547. <table class="params">
  548. <tr><td class="paramdir">[in]</td><td class="paramname">priv_key</td><td>Member private key to be freed </td></tr>
  549. </table>
  550. </dd>
  551. </dl>
  552. </div>
  553. </div>
  554. <a class="anchor" id="ga3335a4754825c54840263aa4b2a9bf67"></a>
  555. <div class="memitem">
  556. <div class="memproto">
  557. <table class="memname">
  558. <tr>
  559. <td class="memname">void DeleteStack </td>
  560. <td>(</td>
  561. <td class="paramtype"><a class="el" href="struct_stack.html">Stack</a> **&#160;</td>
  562. <td class="paramname"><em>stack</em></td><td>)</td>
  563. <td></td>
  564. </tr>
  565. </table>
  566. </div><div class="memdoc">
  567. <p>Deallocates memory used for the stack. </p>
  568. <dl class="params"><dt>Parameters</dt><dd>
  569. <table class="params">
  570. <tr><td class="paramdir">[in,out]</td><td class="paramname">stack</td><td><a class="el" href="struct_stack.html" title="Internal representation of a Stack. ">Stack</a> context</td></tr>
  571. </table>
  572. </dd>
  573. </dl>
  574. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga00cb25d52726cef61a9a5266176c2a58" title="Create stack. ">CreateStack</a> </dd></dl>
  575. </div>
  576. </div>
  577. <a class="anchor" id="gada170fd890504b013139f4a33033ae4b"></a>
  578. <div class="memitem">
  579. <div class="memproto">
  580. <table class="memname">
  581. <tr>
  582. <td class="memname">void* EpidAlloc </td>
  583. <td>(</td>
  584. <td class="paramtype">size_t&#160;</td>
  585. <td class="paramname"><em>size</em></td><td>)</td>
  586. <td></td>
  587. </tr>
  588. </table>
  589. </div><div class="memdoc">
  590. <p>Allocates memory of size bytes. </p>
  591. <p>The content of memory is initialized with zeros. Memory must be freed with EpidFree function.</p>
  592. <dl class="params"><dt>Parameters</dt><dd>
  593. <table class="params">
  594. <tr><td class="paramdir">[in]</td><td class="paramname">size</td><td>number of bytes to allocate</td></tr>
  595. </table>
  596. </dd>
  597. </dl>
  598. <dl class="section return"><dt>Returns</dt><dd>pointer to allocated memory. </dd></dl>
  599. </div>
  600. </div>
  601. <a class="anchor" id="gaeae76709e6bfc80c9d79ec4943ccc1ac"></a>
  602. <div class="memitem">
  603. <div class="memproto">
  604. <table class="memname">
  605. <tr>
  606. <td class="memname">void EpidFree </td>
  607. <td>(</td>
  608. <td class="paramtype">void *&#160;</td>
  609. <td class="paramname"><em>ptr</em></td><td>)</td>
  610. <td></td>
  611. </tr>
  612. </table>
  613. </div><div class="memdoc">
  614. <p>Frees memory allocated by EpidAlloc. </p>
  615. <p>Clears information stored in the block of memory.</p>
  616. <dl class="params"><dt>Parameters</dt><dd>
  617. <table class="params">
  618. <tr><td class="paramdir">[in]</td><td class="paramname">ptr</td><td>pointer to allocated memory block </td></tr>
  619. </table>
  620. </dd>
  621. </dl>
  622. </div>
  623. </div>
  624. <a class="anchor" id="ga6911838728d546e4a51d7bcb8404525c"></a>
  625. <div class="memitem">
  626. <div class="memproto">
  627. <table class="memname">
  628. <tr>
  629. <td class="memname">void* EpidRealloc </td>
  630. <td>(</td>
  631. <td class="paramtype">void *&#160;</td>
  632. <td class="paramname"><em>ptr</em>, </td>
  633. </tr>
  634. <tr>
  635. <td class="paramkey"></td>
  636. <td></td>
  637. <td class="paramtype">size_t&#160;</td>
  638. <td class="paramname"><em>new_size</em>&#160;</td>
  639. </tr>
  640. <tr>
  641. <td></td>
  642. <td>)</td>
  643. <td></td><td></td>
  644. </tr>
  645. </table>
  646. </div><div class="memdoc">
  647. <p>Reallocates memory allocated by EpidAlloc. </p>
  648. <p>In case of error NULL pointer is returned and input memory block is not changed. Memory must be freed with EpidFree function.</p>
  649. <dl class="params"><dt>Parameters</dt><dd>
  650. <table class="params">
  651. <tr><td class="paramdir">[in]</td><td class="paramname">ptr</td><td>pointer to memory block to reallocate </td></tr>
  652. <tr><td class="paramdir">[in]</td><td class="paramname">new_size</td><td>number of bytes to reallocate for</td></tr>
  653. </table>
  654. </dd>
  655. </dl>
  656. <dl class="section return"><dt>Returns</dt><dd>pointer to allocated memory. </dd></dl>
  657. </div>
  658. </div>
  659. <a class="anchor" id="gad471f600f6032f432b99432fda97a070"></a>
  660. <div class="memitem">
  661. <div class="memproto">
  662. <table class="memname">
  663. <tr>
  664. <td class="memname">void EpidZeroMemory </td>
  665. <td>(</td>
  666. <td class="paramtype">void *&#160;</td>
  667. <td class="paramname"><em>ptr</em>, </td>
  668. </tr>
  669. <tr>
  670. <td class="paramkey"></td>
  671. <td></td>
  672. <td class="paramtype">size_t&#160;</td>
  673. <td class="paramname"><em>size</em>&#160;</td>
  674. </tr>
  675. <tr>
  676. <td></td>
  677. <td>)</td>
  678. <td></td><td></td>
  679. </tr>
  680. </table>
  681. </div><div class="memdoc">
  682. <p>Clear information stored in block of memory pointer to by ptr. </p>
  683. <dl class="section warning"><dt>Warning</dt><dd>This function may be optimized away by some compilers. If it is, you should consider using a compiler or operating system specific memory sanitization function (e.g. memcpy_s or SecureZeroMemory).</dd></dl>
  684. <dl class="params"><dt>Parameters</dt><dd>
  685. <table class="params">
  686. <tr><td class="paramdir">[in]</td><td class="paramname">ptr</td><td>pointer to memory block </td></tr>
  687. <tr><td class="paramdir">[in]</td><td class="paramname">size</td><td>number of bytes to clear </td></tr>
  688. </table>
  689. </dd>
  690. </dl>
  691. </div>
  692. </div>
  693. <a class="anchor" id="ga23ec3f6c8b89eb63e04d2b1ec6fd2696"></a>
  694. <div class="memitem">
  695. <div class="memproto">
  696. <table class="memname">
  697. <tr>
  698. <td class="memname"><a class="el" href="stdtypes_8h.html#ad5c9d4ba3dc37783a528b0925dc981a0">bool</a> IsSigRlValid </td>
  699. <td>(</td>
  700. <td class="paramtype"><a class="el" href="group___epid_types.html#gada666b48d0cbc301985405fde896f1de">GroupId</a> const *&#160;</td>
  701. <td class="paramname"><em>gid</em>, </td>
  702. </tr>
  703. <tr>
  704. <td class="paramkey"></td>
  705. <td></td>
  706. <td class="paramtype"><a class="el" href="struct_sig_rl.html">SigRl</a> const *&#160;</td>
  707. <td class="paramname"><em>sig_rl</em>, </td>
  708. </tr>
  709. <tr>
  710. <td class="paramkey"></td>
  711. <td></td>
  712. <td class="paramtype">size_t&#160;</td>
  713. <td class="paramname"><em>sig_rl_size</em>&#160;</td>
  714. </tr>
  715. <tr>
  716. <td></td>
  717. <td>)</td>
  718. <td></td><td></td>
  719. </tr>
  720. </table>
  721. </div><div class="memdoc">
  722. <p>Function to verify if signature based revocation list is valid. </p>
  723. <dl class="params"><dt>Parameters</dt><dd>
  724. <table class="params">
  725. <tr><td class="paramdir">[in]</td><td class="paramname">gid</td><td>Group id </td></tr>
  726. <tr><td class="paramdir">[in]</td><td class="paramname">sig_rl</td><td>Signature based revocation list </td></tr>
  727. <tr><td class="paramdir">[in]</td><td class="paramname">sig_rl_size</td><td>Size of signature based revocation list</td></tr>
  728. </table>
  729. </dd>
  730. </dl>
  731. <dl class="section return"><dt>Returns</dt><dd>true if revocation list is valid </dd>
  732. <dd>
  733. false if revocation list is invalid </dd></dl>
  734. </div>
  735. </div>
  736. <a class="anchor" id="ga4856121ac4bce4161a015a8a2b4f5b1c"></a>
  737. <div class="memitem">
  738. <div class="memproto">
  739. <table class="memname">
  740. <tr>
  741. <td class="memname">int memcpy_S </td>
  742. <td>(</td>
  743. <td class="paramtype">void *&#160;</td>
  744. <td class="paramname"><em>dest</em>, </td>
  745. </tr>
  746. <tr>
  747. <td class="paramkey"></td>
  748. <td></td>
  749. <td class="paramtype">size_t&#160;</td>
  750. <td class="paramname"><em>destsz</em>, </td>
  751. </tr>
  752. <tr>
  753. <td class="paramkey"></td>
  754. <td></td>
  755. <td class="paramtype">void const *&#160;</td>
  756. <td class="paramname"><em>src</em>, </td>
  757. </tr>
  758. <tr>
  759. <td class="paramkey"></td>
  760. <td></td>
  761. <td class="paramtype">size_t&#160;</td>
  762. <td class="paramname"><em>count</em>&#160;</td>
  763. </tr>
  764. <tr>
  765. <td></td>
  766. <td>)</td>
  767. <td></td><td></td>
  768. </tr>
  769. </table>
  770. </div><div class="memdoc">
  771. <p>Copies bytes between buffers with security ehancements. </p>
  772. <p>Copies count bytes from src to dest. If the source and destination overlap, the behavior is undefined.</p>
  773. <dl class="params"><dt>Parameters</dt><dd>
  774. <table class="params">
  775. <tr><td class="paramdir">[out]</td><td class="paramname">dest</td><td>pointer to the object to copy to </td></tr>
  776. <tr><td class="paramdir">[in]</td><td class="paramname">destsz</td><td>max number of bytes to modify in the destination (typically the size of the destination object) </td></tr>
  777. <tr><td class="paramdir">[in]</td><td class="paramname">src</td><td>pointer to the object to copy from </td></tr>
  778. <tr><td class="paramdir">[in]</td><td class="paramname">count</td><td>number of bytes to copy</td></tr>
  779. </table>
  780. </dd>
  781. </dl>
  782. <dl class="section return"><dt>Returns</dt><dd>zero on success and non-zero value on error.</dd></dl>
  783. <p>Copies bytes between buffers with security ehancements.</p>
  784. <dl class="section note"><dt>Note</dt><dd>Implementation follows C11 memcpy_s but with checks always enabled </dd></dl>
  785. </div>
  786. </div>
  787. <a class="anchor" id="ga3f3c3b965dd714179cbc2f8d96678ee0"></a>
  788. <div class="memitem">
  789. <div class="memproto">
  790. <table class="memname">
  791. <tr>
  792. <td class="memname"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a> SetCalculatedCommitValues </td>
  793. <td>(</td>
  794. <td class="paramtype"><a class="el" href="struct_g1_elem_str.html">G1ElemStr</a> const *&#160;</td>
  795. <td class="paramname"><em>B</em>, </td>
  796. </tr>
  797. <tr>
  798. <td class="paramkey"></td>
  799. <td></td>
  800. <td class="paramtype"><a class="el" href="struct_g1_elem_str.html">G1ElemStr</a> const *&#160;</td>
  801. <td class="paramname"><em>K</em>, </td>
  802. </tr>
  803. <tr>
  804. <td class="paramkey"></td>
  805. <td></td>
  806. <td class="paramtype"><a class="el" href="struct_g1_elem_str.html">G1ElemStr</a> const *&#160;</td>
  807. <td class="paramname"><em>T</em>, </td>
  808. </tr>
  809. <tr>
  810. <td class="paramkey"></td>
  811. <td></td>
  812. <td class="paramtype"><a class="el" href="group___ec_group_primitives.html#ga85c1d5e106031b385a6e23e598ac98fa">EcPoint</a> const *&#160;</td>
  813. <td class="paramname"><em>R1</em>, </td>
  814. </tr>
  815. <tr>
  816. <td class="paramkey"></td>
  817. <td></td>
  818. <td class="paramtype"><a class="el" href="group___ec_group_primitives.html#gac91c5a7623c17a868dd15b2e9aaf7159">EcGroup</a> *&#160;</td>
  819. <td class="paramname"><em>G1</em>, </td>
  820. </tr>
  821. <tr>
  822. <td class="paramkey"></td>
  823. <td></td>
  824. <td class="paramtype"><a class="el" href="group___finite_field_primitives.html#ga6cff5c7c06b07a87442b810ccc0a86fa">FfElement</a> const *&#160;</td>
  825. <td class="paramname"><em>R2</em>, </td>
  826. </tr>
  827. <tr>
  828. <td class="paramkey"></td>
  829. <td></td>
  830. <td class="paramtype"><a class="el" href="group___finite_field_primitives.html#gab281b24e336a8b3d7d90079d862d969e">FiniteField</a> *&#160;</td>
  831. <td class="paramname"><em>GT</em>, </td>
  832. </tr>
  833. <tr>
  834. <td class="paramkey"></td>
  835. <td></td>
  836. <td class="paramtype"><a class="el" href="struct_commit_values.html">CommitValues</a> *&#160;</td>
  837. <td class="paramname"><em>values</em>&#160;</td>
  838. </tr>
  839. <tr>
  840. <td></td>
  841. <td>)</td>
  842. <td></td><td></td>
  843. </tr>
  844. </table>
  845. </div><div class="memdoc">
  846. <p>Set <a class="el" href="struct_commit_values.html" title="Storage for values to create commitment in Sign and Verify algorithms. ">CommitValues</a> structure fields calculated in algorithm. </p>
  847. <p>Set B, K, T, R1 and R2 fields of values argument.</p>
  848. <dl class="params"><dt>Parameters</dt><dd>
  849. <table class="params">
  850. <tr><td class="paramdir">[in]</td><td class="paramname">B</td><td>Value of B to set </td></tr>
  851. <tr><td class="paramdir">[in]</td><td class="paramname">K</td><td>Value of K to set </td></tr>
  852. <tr><td class="paramdir">[in]</td><td class="paramname">T</td><td>Value of T to set </td></tr>
  853. <tr><td class="paramdir">[in]</td><td class="paramname">R1</td><td>Value of R1 to set </td></tr>
  854. <tr><td class="paramdir">[in]</td><td class="paramname">G1</td><td>EcGroup containing element R1 </td></tr>
  855. <tr><td class="paramdir">[in]</td><td class="paramname">R2</td><td>Value of R2 to set </td></tr>
  856. <tr><td class="paramdir">[in]</td><td class="paramname">GT</td><td>FiniteField containing element R2 </td></tr>
  857. <tr><td class="paramdir">[out]</td><td class="paramname">values</td><td>Pointer to <a class="el" href="struct_commit_values.html" title="Storage for values to create commitment in Sign and Verify algorithms. ">CommitValues</a> structure to fill.</td></tr>
  858. </table>
  859. </dd>
  860. </dl>
  861. <dl class="section return"><dt>Returns</dt><dd><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360" title="Return status for SDK functions. ">EpidStatus</a></dd></dl>
  862. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga23f8ea0f7529e8e7a81bd88e607dda01" title="Calculate Fp.hash(t3 || m) for Sign and Verfiy algorithms. ">CalculateCommitmentHash</a> </dd></dl>
  863. </div>
  864. </div>
  865. <a class="anchor" id="ga2d54f4f222e965222024113c0420602d"></a>
  866. <div class="memitem">
  867. <div class="memproto">
  868. <table class="memname">
  869. <tr>
  870. <td class="memname"><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360">EpidStatus</a> SetKeySpecificCommitValues </td>
  871. <td>(</td>
  872. <td class="paramtype"><a class="el" href="struct_group_pub_key.html">GroupPubKey</a> const *&#160;</td>
  873. <td class="paramname"><em>pub_key</em>, </td>
  874. </tr>
  875. <tr>
  876. <td class="paramkey"></td>
  877. <td></td>
  878. <td class="paramtype"><a class="el" href="struct_commit_values.html">CommitValues</a> *&#160;</td>
  879. <td class="paramname"><em>values</em>&#160;</td>
  880. </tr>
  881. <tr>
  882. <td></td>
  883. <td>)</td>
  884. <td></td><td></td>
  885. </tr>
  886. </table>
  887. </div><div class="memdoc">
  888. <p>Set group public key related fields from <a class="el" href="struct_commit_values.html" title="Storage for values to create commitment in Sign and Verify algorithms. ">CommitValues</a> structure. </p>
  889. <p>Set p, g1, g2, h1, h2 and w fields of values argument.</p>
  890. <dl class="params"><dt>Parameters</dt><dd>
  891. <table class="params">
  892. <tr><td class="paramdir">[in]</td><td class="paramname">pub_key</td><td>Group public key </td></tr>
  893. <tr><td class="paramdir">[out]</td><td class="paramname">values</td><td>Pointer to <a class="el" href="struct_commit_values.html" title="Storage for values to create commitment in Sign and Verify algorithms. ">CommitValues</a> structure to fill.</td></tr>
  894. </table>
  895. </dd>
  896. </dl>
  897. <dl class="section return"><dt>Returns</dt><dd><a class="el" href="group___error_codes.html#gafdb27c77c2c4b32c807e326a8a0da360" title="Return status for SDK functions. ">EpidStatus</a></dd></dl>
  898. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga23f8ea0f7529e8e7a81bd88e607dda01" title="Calculate Fp.hash(t3 || m) for Sign and Verfiy algorithms. ">CalculateCommitmentHash</a> </dd></dl>
  899. </div>
  900. </div>
  901. <a class="anchor" id="gab34066dc882ad63362c43c0790973fdc"></a>
  902. <div class="memitem">
  903. <div class="memproto">
  904. <table class="memname">
  905. <tr>
  906. <td class="memname">size_t StackGetSize </td>
  907. <td>(</td>
  908. <td class="paramtype"><a class="el" href="struct_stack.html">Stack</a> const *&#160;</td>
  909. <td class="paramname"><em>stack</em></td><td>)</td>
  910. <td></td>
  911. </tr>
  912. </table>
  913. </div><div class="memdoc">
  914. <p>Get number of elements in the stack. </p>
  915. <dl class="params"><dt>Parameters</dt><dd>
  916. <table class="params">
  917. <tr><td class="paramdir">[in]</td><td class="paramname">stack</td><td><a class="el" href="struct_stack.html" title="Internal representation of a Stack. ">Stack</a> context</td></tr>
  918. </table>
  919. </dd>
  920. </dl>
  921. <dl class="section return"><dt>Returns</dt><dd>Number of elements in the stack or 0 if stack is NULL</dd></dl>
  922. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga00cb25d52726cef61a9a5266176c2a58" title="Create stack. ">CreateStack</a> </dd></dl>
  923. </div>
  924. </div>
  925. <a class="anchor" id="ga8cdde2b366f4473f0a6965bcfea5b6a6"></a>
  926. <div class="memitem">
  927. <div class="memproto">
  928. <table class="memname">
  929. <tr>
  930. <td class="memname"><a class="el" href="stdtypes_8h.html#ad5c9d4ba3dc37783a528b0925dc981a0">bool</a> StackPopN </td>
  931. <td>(</td>
  932. <td class="paramtype"><a class="el" href="struct_stack.html">Stack</a> *&#160;</td>
  933. <td class="paramname"><em>stack</em>, </td>
  934. </tr>
  935. <tr>
  936. <td class="paramkey"></td>
  937. <td></td>
  938. <td class="paramtype">size_t&#160;</td>
  939. <td class="paramname"><em>n</em>, </td>
  940. </tr>
  941. <tr>
  942. <td class="paramkey"></td>
  943. <td></td>
  944. <td class="paramtype">void *&#160;</td>
  945. <td class="paramname"><em>elements</em>&#160;</td>
  946. </tr>
  947. <tr>
  948. <td></td>
  949. <td>)</td>
  950. <td></td><td></td>
  951. </tr>
  952. </table>
  953. </div><div class="memdoc">
  954. <p>Pop multiple elements from the stack. </p>
  955. <dl class="params"><dt>Parameters</dt><dd>
  956. <table class="params">
  957. <tr><td class="paramdir">[in,out]</td><td class="paramname">stack</td><td><a class="el" href="struct_stack.html" title="Internal representation of a Stack. ">Stack</a> context </td></tr>
  958. <tr><td class="paramdir">[in]</td><td class="paramname">n</td><td>Number of elements to pop from the stack </td></tr>
  959. <tr><td class="paramdir">[out]</td><td class="paramname">elements</td><td>Pointer to a buffer to store elements removed from the stack</td></tr>
  960. </table>
  961. </dd>
  962. </dl>
  963. <dl class="section return"><dt>Returns</dt><dd>true is operation succeed, false otherwise</dd></dl>
  964. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga00cb25d52726cef61a9a5266176c2a58" title="Create stack. ">CreateStack</a> </dd></dl>
  965. </div>
  966. </div>
  967. <a class="anchor" id="ga0b4dedb867504e0148aa0e1fdf642b2b"></a>
  968. <div class="memitem">
  969. <div class="memproto">
  970. <table class="memname">
  971. <tr>
  972. <td class="memname">void* StackPushN </td>
  973. <td>(</td>
  974. <td class="paramtype"><a class="el" href="struct_stack.html">Stack</a> *&#160;</td>
  975. <td class="paramname"><em>stack</em>, </td>
  976. </tr>
  977. <tr>
  978. <td class="paramkey"></td>
  979. <td></td>
  980. <td class="paramtype">size_t&#160;</td>
  981. <td class="paramname"><em>n</em>, </td>
  982. </tr>
  983. <tr>
  984. <td class="paramkey"></td>
  985. <td></td>
  986. <td class="paramtype">void *&#160;</td>
  987. <td class="paramname"><em>elements</em>&#160;</td>
  988. </tr>
  989. <tr>
  990. <td></td>
  991. <td>)</td>
  992. <td></td><td></td>
  993. </tr>
  994. </table>
  995. </div><div class="memdoc">
  996. <p>Push multiple elements to the stack. </p>
  997. <dl class="params"><dt>Parameters</dt><dd>
  998. <table class="params">
  999. <tr><td class="paramdir">[in,out]</td><td class="paramname">stack</td><td><a class="el" href="struct_stack.html" title="Internal representation of a Stack. ">Stack</a> context </td></tr>
  1000. <tr><td class="paramdir">[in]</td><td class="paramname">n</td><td>Number of elements to push to the stack </td></tr>
  1001. <tr><td class="paramdir">[in]</td><td class="paramname">elements</td><td>Array of elements to push to the stack. Can be NULL</td></tr>
  1002. </table>
  1003. </dd>
  1004. </dl>
  1005. <dl class="section return"><dt>Returns</dt><dd>A pointer to an array of new elements in the stack or NULL if stack is empty or push operation were failed.</dd></dl>
  1006. <dl class="section see"><dt>See also</dt><dd><a class="el" href="group___epid_common.html#ga00cb25d52726cef61a9a5266176c2a58" title="Create stack. ">CreateStack</a> </dd></dl>
  1007. </div>
  1008. </div>
  1009. </div><!-- contents -->
  1010. </div><!-- doc-content -->
  1011. <!-- HTML footer for doxygen 1.8.10-->
  1012. <!-- start footer part -->
  1013. <div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  1014. <ul>
  1015. <li class="footer">
  1016. &copy; 2016 Intel Corporation
  1017. </li>
  1018. </ul>
  1019. </div>
  1020. </body>
  1021. </html>