javax > javax.crypto > javax.crypto.cipher >

Class: javax.crypto.Cipher
    java.lang.Object
       javax.crypto.Cipher


public class Cipher extends Object


FIELDS:
public static final int DECRYPT_MODE : 2
public static final int ENCRYPT_MODE : 1
public static final int PRIVATE_KEY : 2
public static final int PUBLIC_KEY : 1
public static final int SECRET_KEY : 3
public static final int UNWRAP_MODE : 4
public static final int WRAP_MODE : 3

CONSTRUCTORS:
protected Cipher(CipherSpi cipherSpi, Provider provider, String transformation)


METHODS:
public final byte[] doFinal()
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: BadPaddingException

public final byte[] doFinal(byte[] input)
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: BadPaddingException

public final int doFinal(byte[] output, int outputOffset)
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: ShortBufferException
Throws: BadPaddingException

public final byte[] doFinal(byte[] input, int inputOffset, int inputLen)
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: BadPaddingException

public final int doFinal(byte[] input, int inputOffset, int inputLen, byte[] output)
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: ShortBufferException
Throws: BadPaddingException

public final int doFinal(byte[] input, int inputOffset, int inputLen, byte[] output, int outputOffset)
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: ShortBufferException
Throws: BadPaddingException

public final int doFinal(ByteBuffer input, ByteBuffer output)
Throws: IllegalStateException
Throws: IllegalArgumentException
Throws: ReadOnlyBufferException
Throws: IllegalBlockSizeException
Throws: ShortBufferException
Throws: BadPaddingException

public final String getAlgorithm()

public final int getBlockSize()

public final ExemptionMechanism getExemptionMechanism()

public final byte[] getIV()

public static final Cipher getInstance(String transformation)
Throws: NoSuchAlgorithmException
Throws: NoSuchPaddingException

public static final Cipher getInstance(String transformation, String provider)
Throws: NoSuchAlgorithmException
Throws: NoSuchProviderException
Throws: NoSuchPaddingException
Throws: IllegalArgumentException

public static final Cipher getInstance(String transformation, Provider provider)
Throws: NoSuchAlgorithmException
Throws: NoSuchPaddingException
Throws: IllegalArgumentException

public static final int getMaxAllowedKeyLength(String transformation)
Throws: NullPointerException
Throws: NoSuchAlgorithmException

public static final AlgorithmParameterSpec getMaxAllowedParameterSpec(String transformation)
Throws: NullPointerException
Throws: NoSuchAlgorithmException

public final int getOutputSize(int inputLen)
Throws: IllegalStateException

public final AlgorithmParameters getParameters()

public final Provider getProvider()

public final void init(int opmode, Key key)
Throws: InvalidKeyException

public final void init(int opmode, Key key, AlgorithmParameters params)
Throws: InvalidKeyException
Throws: InvalidAlgorithmParameterException

public final void init(int opmode, Key key, AlgorithmParameters params, SecureRandom random)
Throws: InvalidKeyException
Throws: InvalidAlgorithmParameterException

public final void init(int opmode, Key key, SecureRandom random)
Throws: InvalidKeyException

public final void init(int opmode, Key key, AlgorithmParameterSpec params)
Throws: InvalidKeyException
Throws: InvalidAlgorithmParameterException

public final void init(int opmode, Key key, AlgorithmParameterSpec params, SecureRandom random)
Throws: InvalidKeyException
Throws: InvalidAlgorithmParameterException

public final void init(int opmode, Certificate certificate)
Throws: InvalidKeyException

public final void init(int opmode, Certificate certificate, SecureRandom random)
Throws: InvalidKeyException

public final Key unwrap(byte[] wrappedKey, String wrappedKeyAlgorithm, int wrappedKeyType)
Throws: IllegalStateException
Throws: NoSuchAlgorithmException
Throws: InvalidKeyException

public final byte[] update(byte[] input)
Throws: IllegalStateException

public final byte[] update(byte[] input, int inputOffset, int inputLen)
Throws: IllegalStateException

public final int update(byte[] input, int inputOffset, int inputLen, byte[] output)
Throws: IllegalStateException
Throws: ShortBufferException

public final int update(byte[] input, int inputOffset, int inputLen, byte[] output, int outputOffset)
Throws: IllegalStateException
Throws: ShortBufferException

public final int update(ByteBuffer input, ByteBuffer output)
Throws: IllegalStateException
Throws: IllegalArgumentException
Throws: ReadOnlyBufferException
Throws: ShortBufferException

public final byte[] wrap(Key key)
Throws: IllegalStateException
Throws: IllegalBlockSizeException
Throws: InvalidKeyException


INHERITED METHODS:
getClass(), hashCode(), equals(java.lang.Object), clone(), toString(), notify(), notifyAll(), wait(long), wait(long, int), wait(), finalize(),

SUBCLASSES:
NullCipher,





Yazilar kaynak gosterilmeden kopyalanamaz © www.kodcu.net