1
0
mirror of https://github.com/taigrr/arduinolibs synced 2025-01-18 04:33:12 -08:00
arduinolibs/classKeccakCore.html
Rhys Weatherley ba61fb1e01 Update docs
2015-03-14 15:47:44 +10:00

379 lines
24 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://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.6"/>
<title>ArduinoLibs: KeccakCore 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="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
$(document).ready(function() { searchBox.OnSelectItem(0); });
</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 style="padding-left: 0.5em;">
<div id="projectname">ArduinoLibs
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.6 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
<li>
<div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<img id="MSearchSelect" src="search/mag_sel.png"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
alt=""/>
<input type="text" id="MSearchField" value="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
</span>
</div>
</li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class&#160;List</span></a></li>
<li><a href="classes.html"><span>Class&#160;Index</span></a></li>
<li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class&#160;Members</span></a></li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Pages</a></div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classKeccakCore-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">KeccakCore Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Keccak core sponge function.
<a href="classKeccakCore.html#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="KeccakCore_8h_source.html">KeccakCore.h</a>&gt;</code></p>
<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:a850c8e85bdb6b347411239716535d9c9"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#a850c8e85bdb6b347411239716535d9c9">KeccakCore</a> ()</td></tr>
<tr class="memdesc:a850c8e85bdb6b347411239716535d9c9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a new Keccak sponge function. <a href="#a850c8e85bdb6b347411239716535d9c9">More...</a><br/></td></tr>
<tr class="separator:a850c8e85bdb6b347411239716535d9c9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4579e3a9b24f1d615fa8d660c23e77a4"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4579e3a9b24f1d615fa8d660c23e77a4"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#a4579e3a9b24f1d615fa8d660c23e77a4">~KeccakCore</a> ()</td></tr>
<tr class="memdesc:a4579e3a9b24f1d615fa8d660c23e77a4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destroys this Keccak sponge function after clearing all sensitive information. <br/></td></tr>
<tr class="separator:a4579e3a9b24f1d615fa8d660c23e77a4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a804b895121a4e04bc491f41a5821a13e"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#a804b895121a4e04bc491f41a5821a13e">capacity</a> () const </td></tr>
<tr class="memdesc:a804b895121a4e04bc491f41a5821a13e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the capacity of the sponge function in bits. <a href="#a804b895121a4e04bc491f41a5821a13e">More...</a><br/></td></tr>
<tr class="separator:a804b895121a4e04bc491f41a5821a13e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab3c1905f2002e49aca085d6f0b5546f7"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#ab3c1905f2002e49aca085d6f0b5546f7">setCapacity</a> (size_t <a class="el" href="classKeccakCore.html#a804b895121a4e04bc491f41a5821a13e">capacity</a>)</td></tr>
<tr class="memdesc:ab3c1905f2002e49aca085d6f0b5546f7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the capacity of the Keccak sponge function in bits. <a href="#ab3c1905f2002e49aca085d6f0b5546f7">More...</a><br/></td></tr>
<tr class="separator:ab3c1905f2002e49aca085d6f0b5546f7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3742ed39151811b5d1c263c75ee5b20a"><td class="memItemLeft" align="right" valign="top">size_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a">blockSize</a> () const </td></tr>
<tr class="memdesc:a3742ed39151811b5d1c263c75ee5b20a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the input block size for the sponge function in bytes. <a href="#a3742ed39151811b5d1c263c75ee5b20a">More...</a><br/></td></tr>
<tr class="separator:a3742ed39151811b5d1c263c75ee5b20a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5a322eb7e3b5c1eaad127c9c6e6a529b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#a5a322eb7e3b5c1eaad127c9c6e6a529b">reset</a> ()</td></tr>
<tr class="memdesc:a5a322eb7e3b5c1eaad127c9c6e6a529b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Resets the Keccak sponge function ready for a new session. <a href="#a5a322eb7e3b5c1eaad127c9c6e6a529b">More...</a><br/></td></tr>
<tr class="separator:a5a322eb7e3b5c1eaad127c9c6e6a529b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aaaa0355ccec0f469ac8eb577bdf853ed"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#aaaa0355ccec0f469ac8eb577bdf853ed">update</a> (const void *data, size_t size)</td></tr>
<tr class="memdesc:aaaa0355ccec0f469ac8eb577bdf853ed"><td class="mdescLeft">&#160;</td><td class="mdescRight">Updates the Keccak sponge function with more input data. <a href="#aaaa0355ccec0f469ac8eb577bdf853ed">More...</a><br/></td></tr>
<tr class="separator:aaaa0355ccec0f469ac8eb577bdf853ed"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a97852ee4381ced17ee6d21704cf0b4d7"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#a97852ee4381ced17ee6d21704cf0b4d7">pad</a> (uint8_t tag)</td></tr>
<tr class="memdesc:a97852ee4381ced17ee6d21704cf0b4d7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Pads the last block of input data to <a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a" title="Returns the input block size for the sponge function in bytes. ">blockSize()</a>. <a href="#a97852ee4381ced17ee6d21704cf0b4d7">More...</a><br/></td></tr>
<tr class="separator:a97852ee4381ced17ee6d21704cf0b4d7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aad83ece853c0cc15fcab947fdcba924f"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#aad83ece853c0cc15fcab947fdcba924f">extract</a> (void *data, size_t size)</td></tr>
<tr class="memdesc:aad83ece853c0cc15fcab947fdcba924f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Extracts data from the Keccak sponge function. <a href="#aad83ece853c0cc15fcab947fdcba924f">More...</a><br/></td></tr>
<tr class="separator:aad83ece853c0cc15fcab947fdcba924f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aeff1df56e4a3103c99c1fe4307e60c66"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aeff1df56e4a3103c99c1fe4307e60c66"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classKeccakCore.html#aeff1df56e4a3103c99c1fe4307e60c66">clear</a> ()</td></tr>
<tr class="memdesc:aeff1df56e4a3103c99c1fe4307e60c66"><td class="mdescLeft">&#160;</td><td class="mdescRight">Clears all sensitive data from this object. <br/></td></tr>
<tr class="separator:aeff1df56e4a3103c99c1fe4307e60c66"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Keccak core sponge function. </p>
<p><a class="el" href="classKeccakCore.html" title="Keccak core sponge function. ">KeccakCore</a> provides the core sponge function for different capacities. It is used to implement <a class="el" href="classHash.html" title="Abstract base class for cryptographic hash algorithms. ">Hash</a> algorithms such as SHA3.</p>
<p>References: <a href="http://en.wikipedia.org/wiki/SHA-3">http://en.wikipedia.org/wiki/SHA-3</a></p>
<dl class="section see"><dt>See Also</dt><dd>SHA3 </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8h_source.html#l00029">29</a> of file <a class="el" href="KeccakCore_8h_source.html">KeccakCore.h</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a850c8e85bdb6b347411239716535d9c9"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">KeccakCore::KeccakCore </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a new Keccak sponge function. </p>
<p>The <a class="el" href="classKeccakCore.html#a804b895121a4e04bc491f41a5821a13e" title="Returns the capacity of the sponge function in bits. ">capacity()</a> will initially be set to 1536, which normally won't be of much use to the caller. The constructor should be followed by a call to <a class="el" href="classKeccakCore.html#ab3c1905f2002e49aca085d6f0b5546f7" title="Sets the capacity of the Keccak sponge function in bits. ">setCapacity()</a> to select the capacity of interest. </p>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00049">49</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a3742ed39151811b5d1c263c75ee5b20a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">size_t KeccakCore::blockSize </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">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the input block size for the sponge function in bytes. </p>
<p>The block size is (1600 - <a class="el" href="classKeccakCore.html#a804b895121a4e04bc491f41a5821a13e" title="Returns the capacity of the sponge function in bits. ">capacity()</a>) / 8.</p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#a804b895121a4e04bc491f41a5821a13e" title="Returns the capacity of the sponge function in bits. ">capacity()</a> </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8h_source.html#l00038">38</a> of file <a class="el" href="KeccakCore_8h_source.html">KeccakCore.h</a>.</p>
</div>
</div>
<a class="anchor" id="a804b895121a4e04bc491f41a5821a13e"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">size_t KeccakCore::capacity </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the capacity of the sponge function in bits. </p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#ab3c1905f2002e49aca085d6f0b5546f7" title="Sets the capacity of the Keccak sponge function in bits. ">setCapacity()</a>, <a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a" title="Returns the input block size for the sponge function in bytes. ">blockSize()</a> </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00071">71</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<a class="anchor" id="aad83ece853c0cc15fcab947fdcba924f"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void KeccakCore::extract </td>
<td>(</td>
<td class="paramtype">void *&#160;</td>
<td class="paramname"><em>data</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t&#160;</td>
<td class="paramname"><em>size</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Extracts data from the Keccak sponge function. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">data</td><td>The data buffer to fill with extracted data. </td></tr>
<tr><td class="paramname">size</td><td>The number number of bytes of extracted data that are required.</td></tr>
</table>
</dd>
</dl>
<p>If more than <a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a" title="Returns the input block size for the sponge function in bytes. ">blockSize()</a> bytes are required, the sponge function will be invoked to generate additional data.</p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#aaaa0355ccec0f469ac8eb577bdf853ed" title="Updates the Keccak sponge function with more input data. ">update()</a>, <a class="el" href="classKeccakCore.html#a5a322eb7e3b5c1eaad127c9c6e6a529b" title="Resets the Keccak sponge function ready for a new session. ">reset()</a>, extractHash() </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00201">201</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<a class="anchor" id="a97852ee4381ced17ee6d21704cf0b4d7"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void KeccakCore::pad </td>
<td>(</td>
<td class="paramtype">uint8_t&#160;</td>
<td class="paramname"><em>tag</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Pads the last block of input data to <a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a" title="Returns the input block size for the sponge function in bytes. ">blockSize()</a>. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">tag</td><td>The tag byte to add to the padding to identify SHA3 (0x06), SHAKE (0x1F), or the plain pre-standardized version of Keccak (0x01).</td></tr>
</table>
</dd>
</dl>
<p>The sponge function will be invoked to process the completed padding block.</p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#aaaa0355ccec0f469ac8eb577bdf853ed" title="Updates the Keccak sponge function with more input data. ">update()</a>, <a class="el" href="classKeccakCore.html#aad83ece853c0cc15fcab947fdcba924f" title="Extracts data from the Keccak sponge function. ">extract()</a> </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00174">174</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<a class="anchor" id="a5a322eb7e3b5c1eaad127c9c6e6a529b"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void KeccakCore::reset </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Resets the Keccak sponge function ready for a new session. </p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#aaaa0355ccec0f469ac8eb577bdf853ed" title="Updates the Keccak sponge function with more input data. ">update()</a>, <a class="el" href="classKeccakCore.html#aad83ece853c0cc15fcab947fdcba924f" title="Extracts data from the Keccak sponge function. ">extract()</a> </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00109">109</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<a class="anchor" id="ab3c1905f2002e49aca085d6f0b5546f7"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void KeccakCore::setCapacity </td>
<td>(</td>
<td class="paramtype">size_t&#160;</td>
<td class="paramname"><em>capacity</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the capacity of the Keccak sponge function in bits. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">capacity</td><td>The capacity of the Keccak sponge function in bits which should be a multiple of 64 and between 64 and 1536.</td></tr>
</table>
</dd>
</dl>
<dl class="section note"><dt>Note</dt><dd>It is possible to create a sponge function with this constructor that doesn't strictly conform with the capacity and hash size constraints defined in the relevant standards. It is the responsibility of callers to only use standard parameter combinations.</dd></dl>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#a804b895121a4e04bc491f41a5821a13e" title="Returns the capacity of the sponge function in bits. ">capacity()</a>, <a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a" title="Returns the input block size for the sponge function in bytes. ">blockSize()</a> </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00089">89</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<a class="anchor" id="aaaa0355ccec0f469ac8eb577bdf853ed"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void KeccakCore::update </td>
<td>(</td>
<td class="paramtype">const void *&#160;</td>
<td class="paramname"><em>data</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t&#160;</td>
<td class="paramname"><em>size</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Updates the Keccak sponge function with more input data. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">data</td><td>The extra input data to incorporate. </td></tr>
<tr><td class="paramname">size</td><td>The size of the new data to incorporate.</td></tr>
</table>
</dd>
</dl>
<p>This function will invoke the sponge function whenever a full <a class="el" href="classKeccakCore.html#a3742ed39151811b5d1c263c75ee5b20a" title="Returns the input block size for the sponge function in bytes. ">blockSize()</a> bytes of input data have been accumulated. Call <a class="el" href="classKeccakCore.html#a97852ee4381ced17ee6d21704cf0b4d7" title="Pads the last block of input data to blockSize(). ">pad()</a> after the last block to finalize the input before calling <a class="el" href="classKeccakCore.html#aad83ece853c0cc15fcab947fdcba924f" title="Extracts data from the Keccak sponge function. ">extract()</a>.</p>
<dl class="section see"><dt>See Also</dt><dd><a class="el" href="classKeccakCore.html#a97852ee4381ced17ee6d21704cf0b4d7" title="Pads the last block of input data to blockSize(). ">pad()</a>, <a class="el" href="classKeccakCore.html#aad83ece853c0cc15fcab947fdcba924f" title="Extracts data from the Keccak sponge function. ">extract()</a>, <a class="el" href="classKeccakCore.html#a5a322eb7e3b5c1eaad127c9c6e6a529b" title="Resets the Keccak sponge function ready for a new session. ">reset()</a> </dd></dl>
<p>Definition at line <a class="el" href="KeccakCore_8cpp_source.html#l00128">128</a> of file <a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="KeccakCore_8h_source.html">KeccakCore.h</a></li>
<li><a class="el" href="KeccakCore_8cpp_source.html">KeccakCore.cpp</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated on Sat Mar 14 2015 15:47:30 for ArduinoLibs by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.6
</small></address>
</body>
</html>