Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > d1d38291248b5ff58339d3d2ddb22ecd > files > 1060

lib64beecrypt-devel-4.2.1-13.mga4.x86_64.rpm

\hypertarget{blockmode_8h}{\section{include/beecrypt/blockmode.h File Reference}
\label{blockmode_8h}\index{include/beecrypt/blockmode.\-h@{include/beecrypt/blockmode.\-h}}
}


Blockcipher operation modes.  


{\ttfamily \#include \char`\"{}beecrypt/beecrypt.\-h\char`\"{}}\\*
Include dependency graph for blockmode.\-h\-:
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=350pt]{blockmode_8h__incl}
\end{center}
\end{figure}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
int \hyperlink{blockmode_8h_ae9a56da9dbfaeef5fca3363ad3692830}{block\-Encrypt\-E\-C\-B} (const \hyperlink{structblockCipher}{block\-Cipher} $\ast$bc, \hyperlink{group__BC__m_gaa6f6ba122e489fd3c3923c83cb55dae0}{block\-Cipher\-Param} $\ast$bp, uint32\-\_\-t $\ast$dst, const uint32\-\_\-t $\ast$src, unsigned int nblocks)
\begin{DoxyCompactList}\small\item\em This function encrypts a number of data blocks in Electronic Code Book mode. \end{DoxyCompactList}\item 
int \hyperlink{blockmode_8h_ab7da344f46aa07e72456affa51b30cf0}{block\-Decrypt\-E\-C\-B} (const \hyperlink{structblockCipher}{block\-Cipher} $\ast$bc, \hyperlink{group__BC__m_gaa6f6ba122e489fd3c3923c83cb55dae0}{block\-Cipher\-Param} $\ast$bp, uint32\-\_\-t $\ast$dst, const uint32\-\_\-t $\ast$src, unsigned int nblocks)
\begin{DoxyCompactList}\small\item\em This function decrypts a number of data blocks in Electronic Code Book mode. \end{DoxyCompactList}\item 
int \hyperlink{blockmode_8h_a1d40753747be488d277de1678ec5fa40}{block\-Encrypt\-C\-B\-C} (const \hyperlink{structblockCipher}{block\-Cipher} $\ast$bc, \hyperlink{group__BC__m_gaa6f6ba122e489fd3c3923c83cb55dae0}{block\-Cipher\-Param} $\ast$bp, uint32\-\_\-t $\ast$dst, const uint32\-\_\-t $\ast$src, unsigned int nblocks)
\begin{DoxyCompactList}\small\item\em This function encrypts a number of data blocks in Cipher Block Chaining mode. \end{DoxyCompactList}\item 
int \hyperlink{blockmode_8h_a3d56606cd8cc1278c6a04f0fec060132}{block\-Decrypt\-C\-B\-C} (const \hyperlink{structblockCipher}{block\-Cipher} $\ast$bc, \hyperlink{group__BC__m_gaa6f6ba122e489fd3c3923c83cb55dae0}{block\-Cipher\-Param} $\ast$bp, uint32\-\_\-t $\ast$dst, const uint32\-\_\-t $\ast$src, unsigned int nblocks)
\begin{DoxyCompactList}\small\item\em This function decrypts a number of data blocks in Cipher Block Chaining mode. \end{DoxyCompactList}\item 
int \hyperlink{blockmode_8h_ae6160f7c0cfa3fe4caa7ae6c0fafbb0f}{block\-Encrypt\-C\-T\-R} (const \hyperlink{structblockCipher}{block\-Cipher} $\ast$bc, \hyperlink{group__BC__m_gaa6f6ba122e489fd3c3923c83cb55dae0}{block\-Cipher\-Param} $\ast$bp, uint32\-\_\-t $\ast$dst, const uint32\-\_\-t $\ast$src, unsigned int nblocks)
\item 
int \hyperlink{blockmode_8h_a683d0915b126130e69ff67a72288fadc}{block\-Decrypt\-C\-T\-R} (const \hyperlink{structblockCipher}{block\-Cipher} $\ast$bc, \hyperlink{group__BC__m_gaa6f6ba122e489fd3c3923c83cb55dae0}{block\-Cipher\-Param} $\ast$bp, uint32\-\_\-t $\ast$dst, const uint32\-\_\-t $\ast$src, unsigned int nblocks)
\end{DoxyCompactItemize}


\subsection{Detailed Description}
Blockcipher operation modes. \begin{DoxyRefDesc}{Todo}
\item[\hyperlink{todo__todo000001}{Todo}]Additional modes, such as C\-F\-B and O\-F\-B. \end{DoxyRefDesc}
\begin{DoxyAuthor}{Author}
Bob Deblier \href{mailto:bob.deblier@telenet.be}{\tt bob.\-deblier@telenet.\-be} 
\end{DoxyAuthor}


\subsection{Function Documentation}
\hypertarget{blockmode_8h_a3d56606cd8cc1278c6a04f0fec060132}{\index{blockmode.\-h@{blockmode.\-h}!block\-Decrypt\-C\-B\-C@{block\-Decrypt\-C\-B\-C}}
\index{block\-Decrypt\-C\-B\-C@{block\-Decrypt\-C\-B\-C}!blockmode.h@{blockmode.\-h}}
\subsubsection[{block\-Decrypt\-C\-B\-C}]{\setlength{\rightskip}{0pt plus 5cm}int block\-Decrypt\-C\-B\-C (
\begin{DoxyParamCaption}
\item[{const {\bf block\-Cipher} $\ast$}]{bc, }
\item[{{\bf block\-Cipher\-Param} $\ast$}]{bp, }
\item[{uint32\-\_\-t $\ast$}]{dst, }
\item[{const uint32\-\_\-t $\ast$}]{src, }
\item[{unsigned int}]{nblocks}
\end{DoxyParamCaption}
)}}\label{blockmode_8h_a3d56606cd8cc1278c6a04f0fec060132}


This function decrypts a number of data blocks in Cipher Block Chaining mode. 


\begin{DoxyParams}{Parameters}
{\em bc} & The blockcipher. \\
\hline
{\em bp} & The cipher's parameter block. \\
\hline
{\em dst} & The cleartext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em src} & The ciphertext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em nblocks} & The number of blocks to be decrypted. \\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em 0} & on success. \\
\hline
\end{DoxyRetVals}
\hypertarget{blockmode_8h_a683d0915b126130e69ff67a72288fadc}{\index{blockmode.\-h@{blockmode.\-h}!block\-Decrypt\-C\-T\-R@{block\-Decrypt\-C\-T\-R}}
\index{block\-Decrypt\-C\-T\-R@{block\-Decrypt\-C\-T\-R}!blockmode.h@{blockmode.\-h}}
\subsubsection[{block\-Decrypt\-C\-T\-R}]{\setlength{\rightskip}{0pt plus 5cm}int block\-Decrypt\-C\-T\-R (
\begin{DoxyParamCaption}
\item[{const {\bf block\-Cipher} $\ast$}]{bc, }
\item[{{\bf block\-Cipher\-Param} $\ast$}]{bp, }
\item[{uint32\-\_\-t $\ast$}]{dst, }
\item[{const uint32\-\_\-t $\ast$}]{src, }
\item[{unsigned int}]{nblocks}
\end{DoxyParamCaption}
)}}\label{blockmode_8h_a683d0915b126130e69ff67a72288fadc}
\hypertarget{blockmode_8h_ab7da344f46aa07e72456affa51b30cf0}{\index{blockmode.\-h@{blockmode.\-h}!block\-Decrypt\-E\-C\-B@{block\-Decrypt\-E\-C\-B}}
\index{block\-Decrypt\-E\-C\-B@{block\-Decrypt\-E\-C\-B}!blockmode.h@{blockmode.\-h}}
\subsubsection[{block\-Decrypt\-E\-C\-B}]{\setlength{\rightskip}{0pt plus 5cm}int block\-Decrypt\-E\-C\-B (
\begin{DoxyParamCaption}
\item[{const {\bf block\-Cipher} $\ast$}]{bc, }
\item[{{\bf block\-Cipher\-Param} $\ast$}]{bp, }
\item[{uint32\-\_\-t $\ast$}]{dst, }
\item[{const uint32\-\_\-t $\ast$}]{src, }
\item[{unsigned int}]{nblocks}
\end{DoxyParamCaption}
)}}\label{blockmode_8h_ab7da344f46aa07e72456affa51b30cf0}


This function decrypts a number of data blocks in Electronic Code Book mode. 


\begin{DoxyParams}{Parameters}
{\em bc} & The blockcipher. \\
\hline
{\em bp} & The cipher's parameter block. \\
\hline
{\em dst} & The cleartext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em src} & The ciphertext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em nblocks} & The number of blocks to be decrypted. \\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em 0} & on success. \\
\hline
\end{DoxyRetVals}
\hypertarget{blockmode_8h_a1d40753747be488d277de1678ec5fa40}{\index{blockmode.\-h@{blockmode.\-h}!block\-Encrypt\-C\-B\-C@{block\-Encrypt\-C\-B\-C}}
\index{block\-Encrypt\-C\-B\-C@{block\-Encrypt\-C\-B\-C}!blockmode.h@{blockmode.\-h}}
\subsubsection[{block\-Encrypt\-C\-B\-C}]{\setlength{\rightskip}{0pt plus 5cm}int block\-Encrypt\-C\-B\-C (
\begin{DoxyParamCaption}
\item[{const {\bf block\-Cipher} $\ast$}]{bc, }
\item[{{\bf block\-Cipher\-Param} $\ast$}]{bp, }
\item[{uint32\-\_\-t $\ast$}]{dst, }
\item[{const uint32\-\_\-t $\ast$}]{src, }
\item[{unsigned int}]{nblocks}
\end{DoxyParamCaption}
)}}\label{blockmode_8h_a1d40753747be488d277de1678ec5fa40}


This function encrypts a number of data blocks in Cipher Block Chaining mode. 


\begin{DoxyParams}{Parameters}
{\em bc} & The blockcipher. \\
\hline
{\em bp} & The cipher's parameter block. \\
\hline
{\em dst} & The ciphertext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em src} & The cleartext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em nblocks} & The number of blocks to be encrypted. \\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em 0} & on success. \\
\hline
\end{DoxyRetVals}
\hypertarget{blockmode_8h_ae6160f7c0cfa3fe4caa7ae6c0fafbb0f}{\index{blockmode.\-h@{blockmode.\-h}!block\-Encrypt\-C\-T\-R@{block\-Encrypt\-C\-T\-R}}
\index{block\-Encrypt\-C\-T\-R@{block\-Encrypt\-C\-T\-R}!blockmode.h@{blockmode.\-h}}
\subsubsection[{block\-Encrypt\-C\-T\-R}]{\setlength{\rightskip}{0pt plus 5cm}int block\-Encrypt\-C\-T\-R (
\begin{DoxyParamCaption}
\item[{const {\bf block\-Cipher} $\ast$}]{bc, }
\item[{{\bf block\-Cipher\-Param} $\ast$}]{bp, }
\item[{uint32\-\_\-t $\ast$}]{dst, }
\item[{const uint32\-\_\-t $\ast$}]{src, }
\item[{unsigned int}]{nblocks}
\end{DoxyParamCaption}
)}}\label{blockmode_8h_ae6160f7c0cfa3fe4caa7ae6c0fafbb0f}
\hypertarget{blockmode_8h_ae9a56da9dbfaeef5fca3363ad3692830}{\index{blockmode.\-h@{blockmode.\-h}!block\-Encrypt\-E\-C\-B@{block\-Encrypt\-E\-C\-B}}
\index{block\-Encrypt\-E\-C\-B@{block\-Encrypt\-E\-C\-B}!blockmode.h@{blockmode.\-h}}
\subsubsection[{block\-Encrypt\-E\-C\-B}]{\setlength{\rightskip}{0pt plus 5cm}int block\-Encrypt\-E\-C\-B (
\begin{DoxyParamCaption}
\item[{const {\bf block\-Cipher} $\ast$}]{bc, }
\item[{{\bf block\-Cipher\-Param} $\ast$}]{bp, }
\item[{uint32\-\_\-t $\ast$}]{dst, }
\item[{const uint32\-\_\-t $\ast$}]{src, }
\item[{unsigned int}]{nblocks}
\end{DoxyParamCaption}
)}}\label{blockmode_8h_ae9a56da9dbfaeef5fca3363ad3692830}


This function encrypts a number of data blocks in Electronic Code Book mode. 


\begin{DoxyParams}{Parameters}
{\em bc} & The blockcipher. \\
\hline
{\em bp} & The cipher's parameter block. \\
\hline
{\em dst} & The ciphertext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em src} & The cleartext data; should be aligned on a 32-\/bit boundary. \\
\hline
{\em nblocks} & The number of blocks to be encrypted. \\
\hline
\end{DoxyParams}

\begin{DoxyRetVals}{Return values}
{\em 0} & on success. \\
\hline
\end{DoxyRetVals}