Sophie

Sophie

distrib > Mageia > 1 > i586 > by-pkgid > e8773dc1178a3ee82e29ab36424dc729 > files > 318

libbeecrypt-devel-4.2.1-6.mga1.i586.rpm

<!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"/>
<title>BeeCrypt: include/beecrypt/blockmode.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.7.3 -->
<div id="top">
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">BeeCrypt&#160;<span id="projectnumber">4.2.1</span></div>
  </td>
 </tr>
 </tbody>
</table>
</div>
  <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><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<h1>include/beecrypt/blockmode.h File Reference<div class="ingroups"><a class="el" href="group__BC__m.html">Block ciphers</a></div></h1>  </div>
</div>
<div class="contents">

<p>Blockcipher operation modes.  
<a href="#_details">More...</a></p>
<div class="textblock"><code>#include &quot;beecrypt/beecrypt.h&quot;</code><br/>
</div><div class="textblock"><div class="dynheader">
Include dependency graph for blockmode.h:</div>
<div class="dyncontent">
<div class="center"><img src="blockmode_8h__incl.png" border="0" usemap="#include_2beecrypt_2blockmode_8h" alt=""/></div>
<map name="include_2beecrypt_2blockmode_8h" id="include_2beecrypt_2blockmode_8h">
</map>
</div>
</div>
<p><a href="blockmode_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="func-members"></a>
Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="blockmode_8h.html#ae9a56da9dbfaeef5fca3363ad3692830">blockEncryptECB</a> (const <a class="el" href="structblockCipher.html">blockCipher</a> *bc, <a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">This function encrypts a number of data blocks in Electronic Code Book mode.  <a href="#ae9a56da9dbfaeef5fca3363ad3692830"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="blockmode_8h.html#ab7da344f46aa07e72456affa51b30cf0">blockDecryptECB</a> (const <a class="el" href="structblockCipher.html">blockCipher</a> *bc, <a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">This function decrypts a number of data blocks in Electronic Code Book mode.  <a href="#ab7da344f46aa07e72456affa51b30cf0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="blockmode_8h.html#a1d40753747be488d277de1678ec5fa40">blockEncryptCBC</a> (const <a class="el" href="structblockCipher.html">blockCipher</a> *bc, <a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">This function encrypts a number of data blocks in Cipher Block Chaining mode.  <a href="#a1d40753747be488d277de1678ec5fa40"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="blockmode_8h.html#a3d56606cd8cc1278c6a04f0fec060132">blockDecryptCBC</a> (const <a class="el" href="structblockCipher.html">blockCipher</a> *bc, <a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">This function decrypts a number of data blocks in Cipher Block Chaining mode.  <a href="#a3d56606cd8cc1278c6a04f0fec060132"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="blockmode_8h.html#ae6160f7c0cfa3fe4caa7ae6c0fafbb0f">blockEncryptCTR</a> (const <a class="el" href="structblockCipher.html">blockCipher</a> *bc, <a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="blockmode_8h.html#a683d0915b126130e69ff67a72288fadc">blockDecryptCTR</a> (const <a class="el" href="structblockCipher.html">blockCipher</a> *bc, <a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)</td></tr>
</table>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Blockcipher operation modes. </p>
<dl class="todo"><dt><b><a class="el" href="todo.html#_todo000001">Todo:</a></b></dt><dd>Additional modes, such as CFB and OFB. </dd></dl>
<dl class="author"><dt><b>Author:</b></dt><dd>Bob Deblier &lt;<a href="mailto:bob.deblier@telenet.be">bob.deblier@telenet.be</a>&gt; </dd></dl>
</div><hr/><h2>Function Documentation</h2>
<a class="anchor" id="a3d56606cd8cc1278c6a04f0fec060132"></a><!-- doxytag: member="blockmode.h::blockDecryptCBC" ref="a3d56606cd8cc1278c6a04f0fec060132" args="(const blockCipher *bc, blockCipherParam *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int blockDecryptCBC </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structblockCipher.html">blockCipher</a> *&#160;</td>
          <td class="paramname"><em>bc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *&#160;</td>
          <td class="paramname"><em>bp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint32_t *&#160;</td>
          <td class="paramname"><em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nblocks</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>This function decrypts a number of data blocks in Cipher Block Chaining mode. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">bc</td><td>The blockcipher. </td></tr>
    <tr><td class="paramname">bp</td><td>The cipher's parameter block. </td></tr>
    <tr><td class="paramname">dst</td><td>The cleartext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">src</td><td>The ciphertext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">nblocks</td><td>The number of blocks to be decrypted. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">0</td><td>on success. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a683d0915b126130e69ff67a72288fadc"></a><!-- doxytag: member="blockmode.h::blockDecryptCTR" ref="a683d0915b126130e69ff67a72288fadc" args="(const blockCipher *bc, blockCipherParam *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int blockDecryptCTR </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structblockCipher.html">blockCipher</a> *&#160;</td>
          <td class="paramname"><em>bc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *&#160;</td>
          <td class="paramname"><em>bp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint32_t *&#160;</td>
          <td class="paramname"><em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nblocks</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<a class="anchor" id="ab7da344f46aa07e72456affa51b30cf0"></a><!-- doxytag: member="blockmode.h::blockDecryptECB" ref="ab7da344f46aa07e72456affa51b30cf0" args="(const blockCipher *bc, blockCipherParam *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int blockDecryptECB </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structblockCipher.html">blockCipher</a> *&#160;</td>
          <td class="paramname"><em>bc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *&#160;</td>
          <td class="paramname"><em>bp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint32_t *&#160;</td>
          <td class="paramname"><em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nblocks</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>This function decrypts a number of data blocks in Electronic Code Book mode. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">bc</td><td>The blockcipher. </td></tr>
    <tr><td class="paramname">bp</td><td>The cipher's parameter block. </td></tr>
    <tr><td class="paramname">dst</td><td>The cleartext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">src</td><td>The ciphertext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">nblocks</td><td>The number of blocks to be decrypted. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">0</td><td>on success. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a1d40753747be488d277de1678ec5fa40"></a><!-- doxytag: member="blockmode.h::blockEncryptCBC" ref="a1d40753747be488d277de1678ec5fa40" args="(const blockCipher *bc, blockCipherParam *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int blockEncryptCBC </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structblockCipher.html">blockCipher</a> *&#160;</td>
          <td class="paramname"><em>bc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *&#160;</td>
          <td class="paramname"><em>bp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint32_t *&#160;</td>
          <td class="paramname"><em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nblocks</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>This function encrypts a number of data blocks in Cipher Block Chaining mode. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">bc</td><td>The blockcipher. </td></tr>
    <tr><td class="paramname">bp</td><td>The cipher's parameter block. </td></tr>
    <tr><td class="paramname">dst</td><td>The ciphertext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">src</td><td>The cleartext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">nblocks</td><td>The number of blocks to be encrypted. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">0</td><td>on success. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ae6160f7c0cfa3fe4caa7ae6c0fafbb0f"></a><!-- doxytag: member="blockmode.h::blockEncryptCTR" ref="ae6160f7c0cfa3fe4caa7ae6c0fafbb0f" args="(const blockCipher *bc, blockCipherParam *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int blockEncryptCTR </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structblockCipher.html">blockCipher</a> *&#160;</td>
          <td class="paramname"><em>bc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *&#160;</td>
          <td class="paramname"><em>bp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint32_t *&#160;</td>
          <td class="paramname"><em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nblocks</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

</div>
</div>
<a class="anchor" id="ae9a56da9dbfaeef5fca3363ad3692830"></a><!-- doxytag: member="blockmode.h::blockEncryptECB" ref="ae9a56da9dbfaeef5fca3363ad3692830" args="(const blockCipher *bc, blockCipherParam *bp, uint32_t *dst, const uint32_t *src, unsigned int nblocks)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int blockEncryptECB </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="structblockCipher.html">blockCipher</a> *&#160;</td>
          <td class="paramname"><em>bc</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__BC__m.html#gaa6f6ba122e489fd3c3923c83cb55dae0">blockCipherParam</a> *&#160;</td>
          <td class="paramname"><em>bp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint32_t *&#160;</td>
          <td class="paramname"><em>dst</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const uint32_t *&#160;</td>
          <td class="paramname"><em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned int&#160;</td>
          <td class="paramname"><em>nblocks</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>This function encrypts a number of data blocks in Electronic Code Book mode. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">bc</td><td>The blockcipher. </td></tr>
    <tr><td class="paramname">bp</td><td>The cipher's parameter block. </td></tr>
    <tr><td class="paramname">dst</td><td>The ciphertext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">src</td><td>The cleartext data; should be aligned on a 32-bit boundary. </td></tr>
    <tr><td class="paramname">nblocks</td><td>The number of blocks to be encrypted. </td></tr>
  </table>
  </dd>
</dl>
<dl><dt><b>Return values:</b></dt><dd>
  <table class="retval">
    <tr><td class="paramname">0</td><td>on success. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
</div>
<hr class="footer"/><address class="footer"><small>Generated on Sun Apr 10 2011 20:49:30 for BeeCrypt by&#160;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </small></address>
</body>
</html>