|
Oracle Fusion Middleware Crypto FIPS Java API Reference for Oracle Security Developer Tools 11g Release 1 (11.1.1) E10696-04 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.security.crypto.core.Coder
oracle.security.crypto.core.Cipher
oracle.security.crypto.core.BlockCipher
oracle.security.crypto.core.DES
public final class DES
The Digital Encryption Standard (DES), as defined in FIPS 46-3 and FIPS 81.
DES is a symmetric cipher using a 56-bit key (plus 8 parity bits) for encryption and decryption of 64-bit blocks.
DES_EDE
Field Summary |
---|
Fields inherited from class oracle.security.crypto.core.BlockCipher |
---|
blockSize, iv, paddingID |
Fields inherited from class oracle.security.crypto.core.Cipher |
---|
CBC, ECB, key, mode, rbs |
Constructor Summary | |
---|---|
DES() Creates an uninitialized DES instance. |
Method Summary | |
---|---|
java.lang.String |
algName() Returns the name of this algorithm: DES |
protected void |
decryptBlock(byte[] input, int inOff, byte[] output, int outOff) Performs the block cipher's basic decryption operation on one block of ciphertext placing the result in the output buffer. |
protected void |
encryptBlock(byte[] input, int inOff, byte[] output, int outOff) Performs the block cipher's basic encryption operation on one block of plaintext placing the result in the output buffer. |
void |
erase() Erases any sensitive information stored in this BlockCipher object. |
AlgorithmIdentifier |
getAlgID() Builds an AlgorithmIdentifier that is a "snapshot" of the Cipher's current configuration. |
void |
initialize(AlgorithmIdentifier algID, SymmetricKey key, Padding.ID paddingID, RandomBitsSource rbs) This method verifies the AlgorithmIdentifier's Object ID and configures the DES instance appropriately with the params of the AlgorithmIdentifier in addition to the SymmetricKey and padding identifier. |
java.lang.String |
toString() Returns the algorithm name of this cipher. |
Methods inherited from class oracle.security.crypto.core.BlockCipher |
---|
decrypt, decrypt, encrypt, encrypt, getBlockSize, getIV, getPaddingID, initialize, setIV, unwrapPrivateKey, unwrapSymmetricKey, wrapKey, wrapKey |
Methods inherited from class oracle.security.crypto.core.Cipher |
---|
assertDecryption, assertEncryption, assertKeyUnwrap, assertKeyWrap, cloneKey, decodeOp, decrypt, decrypt, decrypt, encodeOp, encrypt, encrypt, encrypt, finalize, getInstance, getInstance, getInstance, getInstance, getInstance, getInstance, getMode, initialize, initialize, releaseOp |
Methods inherited from class oracle.security.crypto.core.Coder |
---|
decode, decode, encode, encode |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public DES()
Method Detail |
---|
public void initialize(AlgorithmIdentifier algID, SymmetricKey key, Padding.ID paddingID, RandomBitsSource rbs) throws AlgorithmIdentifierException, InvalidKeyException, CipherException
initialize
in class Cipher
algID
- The AlgorithmIdentifier whose params will be used to configure the cipher.key
- The SymmetricKey instance that will be used by the cipher internally.paddingID
- Used to indicate the type of padding that the Cipher should use. Options are Padding.NONE or Padding.PKCS5. A Cipher must be re-initialized before being used with the other Padding type.rbs
- The RandomBitsSourfce to use in this cipher.AlgorithmIdentifierException
- If the algID's OID isn't valid for the Cipher instance being initialized or if the params are not valid for the algID's OID.InvalidKeyException
- If there is a problem with the Key instance the Cipher is being initialized with.CipherException
- If there's a problem initializing the Cipher with the given parameters.protected void decryptBlock(byte[] input, int inOff, byte[] output, int outOff) throws CipherException
BlockCipher
decryptBlock
in class BlockCipher
input
- Buffer in which data to be decrypted is stored.inOff
- Offset within input buffer of the start of data.output
- Buffer to place the decrypted bytes inoutOff
- Offset within output buffer where the encrypted bytes will be stored.CipherException
- If the Cipher is not initialized, length of data is not equal to the block size, etc.protected void encryptBlock(byte[] input, int inOff, byte[] output, int outOff) throws CipherException
BlockCipher
encryptBlock
in class BlockCipher
input
- Buffer in which data to be encrypted is storedinOff
- Offset within input buffer of the start of dataoutput
- Buffer to place the encrypted bytes inoutOff
- Offset within output buffer where the encrypted bytes will be storedCipherException
- If the Cipher is not initialized, length of data is not equal to the block size, etc.public java.lang.String algName()
algName
in class Coder
public void erase()
BlockCipher
erase
in class BlockCipher
public AlgorithmIdentifier getAlgID()
Cipher
Altering this AlgorithmIdentifier will have no effect on the state of the Cipher.
getAlgID
in class Cipher
public java.lang.String toString()
toString
in class java.lang.Object
|
Oracle Fusion Middleware Crypto FIPS Java API Reference for Oracle Security Developer Tools 11g Release 1 (11.1.1) E10696-04 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |