⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 cipher.html

📁 JAVA CARD 开发包规格说明,版本为2.2.2
💻 HTML
📖 第 1 页 / 共 4 页
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><!--NewPage--><HTML><HEAD><!-- Generated by javadoc (build 1.5.0_02) on Wed Mar 22 19:19:12 PST 2006 --><TITLE>Cipher (Java Card API and Subsets)</TITLE><META NAME="keywords" CONTENT="javacardx.crypto.Cipher class"><LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"><SCRIPT type="text/javascript">function windowTitle(){    parent.document.title="Cipher (Java Card API and Subsets)";}</SCRIPT><NOSCRIPT></NOSCRIPT></HEAD><BODY BGCOLOR="white" onload="windowTitle();"><!-- ========= START OF TOP NAVBAR ======= --><A NAME="navbar_top"><!-- --></A><A HREF="#skip-navbar_top" title="Skip navigation links"></A><TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""><TR><TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"><A NAME="navbar_top_firstrow"><!-- --></A><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">  <TR ALIGN="center" VALIGN="top">  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/Cipher.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>  </TR></TABLE></TD><TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM><b>Java Card </b><br><font size="-1">v2.2.2</font></EM></TD></TR><TR><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">&nbsp;PREV CLASS&nbsp;&nbsp;<A HREF="../../javacardx/crypto/KeyEncryption.html" title="interface in javacardx.crypto"><B>NEXT CLASS</B></A></FONT></TD><TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">  <A HREF="../../index.html?javacardx/crypto/Cipher.html" target="_top"><B>FRAMES</B></A>  &nbsp;&nbsp;<A HREF="Cipher.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;&nbsp;<SCRIPT type="text/javascript">  <!--  if(window==top) {    document.writeln('<A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>');  }  //--></SCRIPT><NOSCRIPT>  <A HREF="../../allclasses-noframe.html"><B>All Classes</B></A></NOSCRIPT></FONT></TD></TR><TR><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD><TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD></TR></TABLE><A NAME="skip-navbar_top"></A><!-- ========= END OF TOP NAVBAR ========= --><HR><!-- ======== START OF CLASS DATA ======== --><H2><FONT SIZE="-1">javacardx.crypto</FONT><BR>Class Cipher</H2><PRE><A HREF="../../java/lang/Object.html" title="class in java.lang">java.lang.Object</A>  <IMG SRC="../../resources/inherit.gif" ALT="extended by "><B>javacardx.crypto.Cipher</B></PRE><HR><DL><DT><PRE>public abstract class <B>Cipher</B><DT>extends <A HREF="../../java/lang/Object.html" title="class in java.lang">Object</A></DL></PRE><P>The <code>Cipher</code> class is the abstract base class for Cipher algorithms. Implementations of Cipher algorithms must extend this class and implement all the abstract methods. <p>The term "pad" is used in the public key cipher algorithms below to refer to all the operations specified in the referenced scheme to transform the message block into the cipher block size. <p> The asymmetric key algorithms encrypt using either a public key (to cipher) or a private key (to sign). In addition they decrypt using the either a private key (to decipher) or a public key (to verify). <p> A tear or card reset event resets an initialized  <code>Cipher</code> object to the state it was in when previously initialized via a call to <code>init()</code>. For algorithms which support keys with transient key data sets, such as DES, triple DES and AES, and Korean SEED the <code>Cipher</code> object key becomes uninitialized on clear events associated with the <code>Key</code> object used to initialize the <code>Cipher</code> object. <p> Even if a transaction is in progress, update of intermediate result state in the implementation instance shall not participate in the transaction.<br> <p>Note:<ul> <li><em>On a tear or card reset event, the AES, DES, triple DES and Korean SEED algorithms in CBC mode reset the initial vector(IV) to 0. The initial vector(IV) can be re-initialized using the </em><code>init(Key, byte, byte[], short, short)</code><em> method.</em> </ul><P><P><HR><P><!-- =========== FIELD SUMMARY =========== --><A NAME="field_summary"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"><B>Field Summary</B></FONT></TH></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_AES_BLOCK_128_CBC_NOPAD">ALG_AES_BLOCK_128_CBC_NOPAD</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_AES_BLOCK_128_CBC_NOPAD</code> provides a cipher using AES with block size 128 in CBC mode and   does not pad input data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_AES_BLOCK_128_ECB_NOPAD">ALG_AES_BLOCK_128_ECB_NOPAD</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_AES_BLOCK_128_ECB_NOPAD</code> provides a cipher using AES with block size 128 in ECB mode and   does not pad input data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_CBC_ISO9797_M1">ALG_DES_CBC_ISO9797_M1</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_CBC_ISO9797_M1</code> provides a cipher using DES in CBC mode or triple DES in outer CBC mode, and pads  input data according to the ISO 9797 method 1 scheme.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_CBC_ISO9797_M2">ALG_DES_CBC_ISO9797_M2</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_CBC_ISO9797_M2</code> provides a cipher using DES in CBC mode or triple DES in outer CBC mode, and pads   input data according to the ISO 9797 method 2 (ISO 7816-4, EMV'96) scheme.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_CBC_NOPAD">ALG_DES_CBC_NOPAD</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_CBC_NOPAD</code> provides a cipher using DES in CBC mode  or triple DES in outer CBC mode, and  does not pad input data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_CBC_PKCS5">ALG_DES_CBC_PKCS5</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm </code>ALG_DES_CBC_PKCS5</code> provides a cipher using DES in CBC mode or triple DES in outer CBC mode, and pads   input data according to the PKCS#5 scheme.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_ECB_ISO9797_M1">ALG_DES_ECB_ISO9797_M1</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_ECB_ISO9797_M1</code> provides a cipher using DES in ECB mode, and pads  input data according to the ISO 9797 method 1 scheme.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_ECB_ISO9797_M2">ALG_DES_ECB_ISO9797_M2</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_ECB_ISO9797_M2</code> provides a cipher using DES in ECB mode, and pads   input data according to the ISO 9797 method 2 (ISO 7816-4, EMV'96) scheme.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_ECB_NOPAD">ALG_DES_ECB_NOPAD</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_ECB_NOPAD</code> provides a cipher using DES in ECB mode, and does not pad input data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_DES_ECB_PKCS5">ALG_DES_ECB_PKCS5</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_DES_ECB_PKCS5</code> provides a cipher using DES in ECB mode, and pads  input data according to the PKCS#5 scheme.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_KOREAN_SEED_CBC_NOPAD">ALG_KOREAN_SEED_CBC_NOPAD</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_KOREAN_SEED_CBC_NOPAD</code> provides a cipher using the Korean SEED algorithm specified in the Korean SEED Algorithm specification provided by KISA, Korea Information Security Agency in ECB mode and   does not pad input data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_KOREAN_SEED_ECB_NOPAD">ALG_KOREAN_SEED_ECB_NOPAD</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_KOREAN_SEED_ECB_NOPAD</code> provides a cipher using the Korean SEED algorithm specified in the Korean SEED Algorithm specification provided by KISA, Korea Information Security Agency in ECB mode and   does not pad input data.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static&nbsp;byte</CODE></FONT></TD><TD><CODE><B><A HREF="../../javacardx/crypto/Cipher.html#ALG_RSA_ISO14888">ALG_RSA_ISO14888</A></B></CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cipher algorithm <code>ALG_RSA_ISO14888</code> provides a cipher using RSA, and pads  

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -