PageRenderTime 165ms CodeModel.GetById 18ms app.highlight 121ms RepoModel.GetById 1ms app.codeStats 0ms

/lib/bouncycastle/docs/org/bouncycastle/crypto/modes/GCMBlockCipher.html

https://bitbucket.org/arkban/somersault
HTML | 550 lines | 473 code | 55 blank | 22 comment | 0 complexity | 9db3a692198f62faef6e75a1bfdbb4f6 MD5 | raw file
Possible License(s): LGPL-2.1, BSD-3-Clause, Apache-2.0
  1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2<!--NewPage-->
  3<HTML>
  4<HEAD>
  5<!-- Generated by javadoc (build 1.6.0) on Mon Jan 11 13:46:36 EST 2010 -->
  6<TITLE>
  7GCMBlockCipher (Bouncy Castle Library 1.45 API Specification)
  8</TITLE>
  9
 10<META NAME="date" CONTENT="2010-01-11">
 11
 12<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
 13
 14<SCRIPT type="text/javascript">
 15function windowTitle()
 16{
 17    if (location.href.indexOf('is-external=true') == -1) {
 18        parent.document.title="GCMBlockCipher (Bouncy Castle Library 1.45 API Specification)";
 19    }
 20}
 21</SCRIPT>
 22<NOSCRIPT>
 23</NOSCRIPT>
 24
 25</HEAD>
 26
 27<BODY BGCOLOR="white" onload="windowTitle();">
 28<HR>
 29
 30
 31<!-- ========= START OF TOP NAVBAR ======= -->
 32<A NAME="navbar_top"><!-- --></A>
 33<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
 34<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
 35<TR>
 36<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
 37<A NAME="navbar_top_firstrow"><!-- --></A>
 38<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
 39  <TR ALIGN="center" VALIGN="top">
 40  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
 41  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
 42  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
 43  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
 44  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
 45  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
 46  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
 47  </TR>
 48</TABLE>
 49</TD>
 50<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
 51<b>Bouncy Castle Cryptography Library 1.45</b></EM>
 52</TD>
 53</TR>
 54
 55<TR>
 56<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
 57&nbsp;<A HREF="../../../../org/bouncycastle/crypto/modes/EAXBlockCipher.html" title="class in org.bouncycastle.crypto.modes"><B>PREV CLASS</B></A>&nbsp;
 58&nbsp;<A HREF="../../../../org/bouncycastle/crypto/modes/GOFBBlockCipher.html" title="class in org.bouncycastle.crypto.modes"><B>NEXT CLASS</B></A></FONT></TD>
 59<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
 60  <A HREF="../../../../index.html?org/bouncycastle/crypto/modes/GCMBlockCipher.html" target="_top"><B>FRAMES</B></A>  &nbsp;
 61&nbsp;<A HREF="GCMBlockCipher.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
 62&nbsp;<SCRIPT type="text/javascript">
 63  <!--
 64  if(window==top) {
 65    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
 66  }
 67  //-->
 68</SCRIPT>
 69<NOSCRIPT>
 70  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
 71</NOSCRIPT>
 72
 73
 74</FONT></TD>
 75</TR>
 76<TR>
 77<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
 78  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
 79<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
 80DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
 81</TR>
 82</TABLE>
 83<A NAME="skip-navbar_top"></A>
 84<!-- ========= END OF TOP NAVBAR ========= -->
 85
 86<HR>
 87<!-- ======== START OF CLASS DATA ======== -->
 88<H2>
 89<FONT SIZE="-1">
 90org.bouncycastle.crypto.modes</FONT>
 91<BR>
 92Class GCMBlockCipher</H2>
 93<PRE>
 94java.lang.Object
 95  <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>org.bouncycastle.crypto.modes.GCMBlockCipher</B>
 96</PRE>
 97<DL>
 98<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></DD>
 99</DL>
100<HR>
101<DL>
102<DT><PRE>public class <B>GCMBlockCipher</B><DT>extends java.lang.Object<DT>implements <A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></DL>
103</PRE>
104
105<P>
106Implements the Galois/Counter mode (GCM) detailed in
107 NIST Special Publication 800-38D.
108<P>
109
110<P>
111<HR>
112
113<P>
114
115<!-- ======== CONSTRUCTOR SUMMARY ======== -->
116
117<A NAME="constructor_summary"><!-- --></A>
118<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
119<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
120<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
121<B>Constructor Summary</B></FONT></TH>
122</TR>
123<TR BGCOLOR="white" CLASS="TableRowColor">
124<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#GCMBlockCipher(org.bouncycastle.crypto.BlockCipher)">GCMBlockCipher</A></B>(<A HREF="../../../../org/bouncycastle/crypto/BlockCipher.html" title="interface in org.bouncycastle.crypto">BlockCipher</A>&nbsp;c)</CODE>
125
126<BR>
127&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
128</TR>
129<TR BGCOLOR="white" CLASS="TableRowColor">
130<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#GCMBlockCipher(org.bouncycastle.crypto.BlockCipher, org.bouncycastle.crypto.modes.gcm.GCMMultiplier)">GCMBlockCipher</A></B>(<A HREF="../../../../org/bouncycastle/crypto/BlockCipher.html" title="interface in org.bouncycastle.crypto">BlockCipher</A>&nbsp;c,
131               <A HREF="../../../../org/bouncycastle/crypto/modes/gcm/GCMMultiplier.html" title="interface in org.bouncycastle.crypto.modes.gcm">GCMMultiplier</A>&nbsp;m)</CODE>
132
133<BR>
134&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
135</TR>
136</TABLE>
137&nbsp;
138<!-- ========== METHOD SUMMARY =========== -->
139
140<A NAME="method_summary"><!-- --></A>
141<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
142<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
143<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
144<B>Method Summary</B></FONT></TH>
145</TR>
146<TR BGCOLOR="white" CLASS="TableRowColor">
147<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
148<CODE>&nbsp;int</CODE></FONT></TD>
149<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#doFinal(byte[], int)">doFinal</A></B>(byte[]&nbsp;out,
150        int&nbsp;outOff)</CODE>
151
152<BR>
153&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Finish the operation either appending or verifying the MAC at the end of the data.</TD>
154</TR>
155<TR BGCOLOR="white" CLASS="TableRowColor">
156<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
157<CODE>&nbsp;java.lang.String</CODE></FONT></TD>
158<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#getAlgorithmName()">getAlgorithmName</A></B>()</CODE>
159
160<BR>
161&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the name of the algorithm.</TD>
162</TR>
163<TR BGCOLOR="white" CLASS="TableRowColor">
164<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
165<CODE>&nbsp;byte[]</CODE></FONT></TD>
166<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#getMac()">getMac</A></B>()</CODE>
167
168<BR>
169&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the value of the MAC associated with the last stream processed.</TD>
170</TR>
171<TR BGCOLOR="white" CLASS="TableRowColor">
172<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
173<CODE>&nbsp;int</CODE></FONT></TD>
174<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#getOutputSize(int)">getOutputSize</A></B>(int&nbsp;len)</CODE>
175
176<BR>
177&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return the size of the output buffer required for a processBytes plus a
178 doFinal with an input of len bytes.</TD>
179</TR>
180<TR BGCOLOR="white" CLASS="TableRowColor">
181<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
182<CODE>&nbsp;<A HREF="../../../../org/bouncycastle/crypto/BlockCipher.html" title="interface in org.bouncycastle.crypto">BlockCipher</A></CODE></FONT></TD>
183<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#getUnderlyingCipher()">getUnderlyingCipher</A></B>()</CODE>
184
185<BR>
186&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return the cipher this object wraps.</TD>
187</TR>
188<TR BGCOLOR="white" CLASS="TableRowColor">
189<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
190<CODE>&nbsp;int</CODE></FONT></TD>
191<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#getUpdateOutputSize(int)">getUpdateOutputSize</A></B>(int&nbsp;len)</CODE>
192
193<BR>
194&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return the size of the output buffer required for a processBytes
195 an input of len bytes.</TD>
196</TR>
197<TR BGCOLOR="white" CLASS="TableRowColor">
198<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
199<CODE>&nbsp;void</CODE></FONT></TD>
200<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#init(boolean, org.bouncycastle.crypto.CipherParameters)">init</A></B>(boolean&nbsp;forEncryption,
201     <A HREF="../../../../org/bouncycastle/crypto/CipherParameters.html" title="interface in org.bouncycastle.crypto">CipherParameters</A>&nbsp;params)</CODE>
202
203<BR>
204&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;initialise the underlying cipher.</TD>
205</TR>
206<TR BGCOLOR="white" CLASS="TableRowColor">
207<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
208<CODE>&nbsp;int</CODE></FONT></TD>
209<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#processByte(byte, byte[], int)">processByte</A></B>(byte&nbsp;in,
210            byte[]&nbsp;out,
211            int&nbsp;outOff)</CODE>
212
213<BR>
214&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;encrypt/decrypt a single byte.</TD>
215</TR>
216<TR BGCOLOR="white" CLASS="TableRowColor">
217<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
218<CODE>&nbsp;int</CODE></FONT></TD>
219<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#processBytes(byte[], int, int, byte[], int)">processBytes</A></B>(byte[]&nbsp;in,
220             int&nbsp;inOff,
221             int&nbsp;len,
222             byte[]&nbsp;out,
223             int&nbsp;outOff)</CODE>
224
225<BR>
226&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;process a block of bytes from in putting the result into out.</TD>
227</TR>
228<TR BGCOLOR="white" CLASS="TableRowColor">
229<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
230<CODE>&nbsp;void</CODE></FONT></TD>
231<TD><CODE><B><A HREF="../../../../org/bouncycastle/crypto/modes/GCMBlockCipher.html#reset()">reset</A></B>()</CODE>
232
233<BR>
234&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reset the cipher.</TD>
235</TR>
236</TABLE>
237&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
238<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
239<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
240<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
241</TR>
242<TR BGCOLOR="white" CLASS="TableRowColor">
243<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
244</TR>
245</TABLE>
246&nbsp;
247<P>
248
249<!-- ========= CONSTRUCTOR DETAIL ======== -->
250
251<A NAME="constructor_detail"><!-- --></A>
252<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
253<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
254<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
255<B>Constructor Detail</B></FONT></TH>
256</TR>
257</TABLE>
258
259<A NAME="GCMBlockCipher(org.bouncycastle.crypto.BlockCipher)"><!-- --></A><H3>
260GCMBlockCipher</H3>
261<PRE>
262public <B>GCMBlockCipher</B>(<A HREF="../../../../org/bouncycastle/crypto/BlockCipher.html" title="interface in org.bouncycastle.crypto">BlockCipher</A>&nbsp;c)</PRE>
263<DL>
264</DL>
265<HR>
266
267<A NAME="GCMBlockCipher(org.bouncycastle.crypto.BlockCipher, org.bouncycastle.crypto.modes.gcm.GCMMultiplier)"><!-- --></A><H3>
268GCMBlockCipher</H3>
269<PRE>
270public <B>GCMBlockCipher</B>(<A HREF="../../../../org/bouncycastle/crypto/BlockCipher.html" title="interface in org.bouncycastle.crypto">BlockCipher</A>&nbsp;c,
271                      <A HREF="../../../../org/bouncycastle/crypto/modes/gcm/GCMMultiplier.html" title="interface in org.bouncycastle.crypto.modes.gcm">GCMMultiplier</A>&nbsp;m)</PRE>
272<DL>
273</DL>
274
275<!-- ============ METHOD DETAIL ========== -->
276
277<A NAME="method_detail"><!-- --></A>
278<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
279<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
280<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
281<B>Method Detail</B></FONT></TH>
282</TR>
283</TABLE>
284
285<A NAME="getUnderlyingCipher()"><!-- --></A><H3>
286getUnderlyingCipher</H3>
287<PRE>
288public <A HREF="../../../../org/bouncycastle/crypto/BlockCipher.html" title="interface in org.bouncycastle.crypto">BlockCipher</A> <B>getUnderlyingCipher</B>()</PRE>
289<DL>
290<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getUnderlyingCipher()">AEADBlockCipher</A></CODE></B></DD>
291<DD>return the cipher this object wraps.
292<P>
293<DD><DL>
294<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getUnderlyingCipher()">getUnderlyingCipher</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
295</DD>
296<DD><DL>
297
298<DT><B>Returns:</B><DD>the cipher this object wraps.</DL>
299</DD>
300</DL>
301<HR>
302
303<A NAME="getAlgorithmName()"><!-- --></A><H3>
304getAlgorithmName</H3>
305<PRE>
306public java.lang.String <B>getAlgorithmName</B>()</PRE>
307<DL>
308<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getAlgorithmName()">AEADBlockCipher</A></CODE></B></DD>
309<DD>Return the name of the algorithm.
310<P>
311<DD><DL>
312<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getAlgorithmName()">getAlgorithmName</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
313</DD>
314<DD><DL>
315
316<DT><B>Returns:</B><DD>the algorithm name.</DL>
317</DD>
318</DL>
319<HR>
320
321<A NAME="init(boolean, org.bouncycastle.crypto.CipherParameters)"><!-- --></A><H3>
322init</H3>
323<PRE>
324public void <B>init</B>(boolean&nbsp;forEncryption,
325                 <A HREF="../../../../org/bouncycastle/crypto/CipherParameters.html" title="interface in org.bouncycastle.crypto">CipherParameters</A>&nbsp;params)
326          throws java.lang.IllegalArgumentException</PRE>
327<DL>
328<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#init(boolean, org.bouncycastle.crypto.CipherParameters)">AEADBlockCipher</A></CODE></B></DD>
329<DD>initialise the underlying cipher. Parameter can either be an AEADParameters or a ParametersWithIV object.
330<P>
331<DD><DL>
332<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#init(boolean, org.bouncycastle.crypto.CipherParameters)">init</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
333</DD>
334<DD><DL>
335<DT><B>Parameters:</B><DD><CODE>forEncryption</CODE> - true if we are setting up for encryption, false otherwise.<DD><CODE>params</CODE> - the necessary parameters for the underlying cipher to be initialised.
336<DT><B>Throws:</B>
337<DD><CODE>java.lang.IllegalArgumentException</CODE> - if the params argument is inappropriate.</DL>
338</DD>
339</DL>
340<HR>
341
342<A NAME="getMac()"><!-- --></A><H3>
343getMac</H3>
344<PRE>
345public byte[] <B>getMac</B>()</PRE>
346<DL>
347<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getMac()">AEADBlockCipher</A></CODE></B></DD>
348<DD>Return the value of the MAC associated with the last stream processed.
349<P>
350<DD><DL>
351<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getMac()">getMac</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
352</DD>
353<DD><DL>
354
355<DT><B>Returns:</B><DD>MAC for plaintext data.</DL>
356</DD>
357</DL>
358<HR>
359
360<A NAME="getOutputSize(int)"><!-- --></A><H3>
361getOutputSize</H3>
362<PRE>
363public int <B>getOutputSize</B>(int&nbsp;len)</PRE>
364<DL>
365<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getOutputSize(int)">AEADBlockCipher</A></CODE></B></DD>
366<DD>return the size of the output buffer required for a processBytes plus a
367 doFinal with an input of len bytes.
368<P>
369<DD><DL>
370<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getOutputSize(int)">getOutputSize</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
371</DD>
372<DD><DL>
373<DT><B>Parameters:</B><DD><CODE>len</CODE> - the length of the input.
374<DT><B>Returns:</B><DD>the space required to accommodate a call to processBytes and doFinal
375 with len bytes of input.</DL>
376</DD>
377</DL>
378<HR>
379
380<A NAME="getUpdateOutputSize(int)"><!-- --></A><H3>
381getUpdateOutputSize</H3>
382<PRE>
383public int <B>getUpdateOutputSize</B>(int&nbsp;len)</PRE>
384<DL>
385<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getUpdateOutputSize(int)">AEADBlockCipher</A></CODE></B></DD>
386<DD>return the size of the output buffer required for a processBytes
387 an input of len bytes.
388<P>
389<DD><DL>
390<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#getUpdateOutputSize(int)">getUpdateOutputSize</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
391</DD>
392<DD><DL>
393<DT><B>Parameters:</B><DD><CODE>len</CODE> - the length of the input.
394<DT><B>Returns:</B><DD>the space required to accommodate a call to processBytes
395 with len bytes of input.</DL>
396</DD>
397</DL>
398<HR>
399
400<A NAME="processByte(byte, byte[], int)"><!-- --></A><H3>
401processByte</H3>
402<PRE>
403public int <B>processByte</B>(byte&nbsp;in,
404                       byte[]&nbsp;out,
405                       int&nbsp;outOff)
406                throws <A HREF="../../../../org/bouncycastle/crypto/DataLengthException.html" title="class in org.bouncycastle.crypto">DataLengthException</A></PRE>
407<DL>
408<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#processByte(byte, byte[], int)">AEADBlockCipher</A></CODE></B></DD>
409<DD>encrypt/decrypt a single byte.
410<P>
411<DD><DL>
412<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#processByte(byte, byte[], int)">processByte</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
413</DD>
414<DD><DL>
415<DT><B>Parameters:</B><DD><CODE>in</CODE> - the byte to be processed.<DD><CODE>out</CODE> - the output buffer the processed byte goes into.<DD><CODE>outOff</CODE> - the offset into the output byte array the processed data starts at.
416<DT><B>Returns:</B><DD>the number of bytes written to out.
417<DT><B>Throws:</B>
418<DD><CODE><A HREF="../../../../org/bouncycastle/crypto/DataLengthException.html" title="class in org.bouncycastle.crypto">DataLengthException</A></CODE> - if the output buffer is too small.</DL>
419</DD>
420</DL>
421<HR>
422
423<A NAME="processBytes(byte[], int, int, byte[], int)"><!-- --></A><H3>
424processBytes</H3>
425<PRE>
426public int <B>processBytes</B>(byte[]&nbsp;in,
427                        int&nbsp;inOff,
428                        int&nbsp;len,
429                        byte[]&nbsp;out,
430                        int&nbsp;outOff)
431                 throws <A HREF="../../../../org/bouncycastle/crypto/DataLengthException.html" title="class in org.bouncycastle.crypto">DataLengthException</A></PRE>
432<DL>
433<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#processBytes(byte[], int, int, byte[], int)">AEADBlockCipher</A></CODE></B></DD>
434<DD>process a block of bytes from in putting the result into out.
435<P>
436<DD><DL>
437<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#processBytes(byte[], int, int, byte[], int)">processBytes</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
438</DD>
439<DD><DL>
440<DT><B>Parameters:</B><DD><CODE>in</CODE> - the input byte array.<DD><CODE>inOff</CODE> - the offset into the in array where the data to be processed starts.<DD><CODE>len</CODE> - the number of bytes to be processed.<DD><CODE>out</CODE> - the output buffer the processed bytes go into.<DD><CODE>outOff</CODE> - the offset into the output byte array the processed data starts at.
441<DT><B>Returns:</B><DD>the number of bytes written to out.
442<DT><B>Throws:</B>
443<DD><CODE><A HREF="../../../../org/bouncycastle/crypto/DataLengthException.html" title="class in org.bouncycastle.crypto">DataLengthException</A></CODE> - if the output buffer is too small.</DL>
444</DD>
445</DL>
446<HR>
447
448<A NAME="doFinal(byte[], int)"><!-- --></A><H3>
449doFinal</H3>
450<PRE>
451public int <B>doFinal</B>(byte[]&nbsp;out,
452                   int&nbsp;outOff)
453            throws java.lang.IllegalStateException,
454                   <A HREF="../../../../org/bouncycastle/crypto/InvalidCipherTextException.html" title="class in org.bouncycastle.crypto">InvalidCipherTextException</A></PRE>
455<DL>
456<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#doFinal(byte[], int)">AEADBlockCipher</A></CODE></B></DD>
457<DD>Finish the operation either appending or verifying the MAC at the end of the data.
458<P>
459<DD><DL>
460<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#doFinal(byte[], int)">doFinal</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
461</DD>
462<DD><DL>
463<DT><B>Parameters:</B><DD><CODE>out</CODE> - space for any resulting output data.<DD><CODE>outOff</CODE> - offset into out to start copying the data at.
464<DT><B>Returns:</B><DD>number of bytes written into out.
465<DT><B>Throws:</B>
466<DD><CODE>java.lang.IllegalStateException</CODE> - if the cipher is in an inappropriate state.
467<DD><CODE><A HREF="../../../../org/bouncycastle/crypto/InvalidCipherTextException.html" title="class in org.bouncycastle.crypto">InvalidCipherTextException</A></CODE> - if the MAC fails to match.</DL>
468</DD>
469</DL>
470<HR>
471
472<A NAME="reset()"><!-- --></A><H3>
473reset</H3>
474<PRE>
475public void <B>reset</B>()</PRE>
476<DL>
477<DD><B>Description copied from interface: <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#reset()">AEADBlockCipher</A></CODE></B></DD>
478<DD>Reset the cipher. After resetting the cipher is in the same state
479 as it was after the last init (if there was one).
480<P>
481<DD><DL>
482<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html#reset()">reset</A></CODE> in interface <CODE><A HREF="../../../../org/bouncycastle/crypto/modes/AEADBlockCipher.html" title="interface in org.bouncycastle.crypto.modes">AEADBlockCipher</A></CODE></DL>
483</DD>
484<DD><DL>
485</DL>
486</DD>
487</DL>
488<!-- ========= END OF CLASS DATA ========= -->
489<HR>
490
491
492<!-- ======= START OF BOTTOM NAVBAR ====== -->
493<A NAME="navbar_bottom"><!-- --></A>
494<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
495<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
496<TR>
497<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
498<A NAME="navbar_bottom_firstrow"><!-- --></A>
499<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
500  <TR ALIGN="center" VALIGN="top">
501  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
502  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
503  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
504  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
505  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
506  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
507  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
508  </TR>
509</TABLE>
510</TD>
511<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
512<b>Bouncy Castle Cryptography Library 1.45</b></EM>
513</TD>
514</TR>
515
516<TR>
517<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
518&nbsp;<A HREF="../../../../org/bouncycastle/crypto/modes/EAXBlockCipher.html" title="class in org.bouncycastle.crypto.modes"><B>PREV CLASS</B></A>&nbsp;
519&nbsp;<A HREF="../../../../org/bouncycastle/crypto/modes/GOFBBlockCipher.html" title="class in org.bouncycastle.crypto.modes"><B>NEXT CLASS</B></A></FONT></TD>
520<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
521  <A HREF="../../../../index.html?org/bouncycastle/crypto/modes/GCMBlockCipher.html" target="_top"><B>FRAMES</B></A>  &nbsp;
522&nbsp;<A HREF="GCMBlockCipher.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
523&nbsp;<SCRIPT type="text/javascript">
524  <!--
525  if(window==top) {
526    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
527  }
528  //-->
529</SCRIPT>
530<NOSCRIPT>
531  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
532</NOSCRIPT>
533
534
535</FONT></TD>
536</TR>
537<TR>
538<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
539  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
540<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
541DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
542</TR>
543</TABLE>
544<A NAME="skip-navbar_bottom"></A>
545<!-- ======== END OF BOTTOM NAVBAR ======= -->
546
547<HR>
548
549</BODY>
550</HTML>