electric.soap.security.encryption.xml.crypto
Class TripleDESCBC

java.lang.Object
  extended byelectric.soap.security.encryption.xml.crypto.TripleDESCBC
All Implemented Interfaces:
IEncryptionAlgorithm

public class TripleDESCBC
extends java.lang.Object
implements IEncryptionAlgorithm

TripleDESCBC implements a wrapper around the Java JCE DEDede cipher implementation. See the XML Encryption spec, section 5.1, "Block Encryption". Triple DES is a required algorithm. There is currently a hard coded 8 byte all-zero intitialization vector.

Author:
webMethods

Constructor Summary
TripleDESCBC()
           
 
Method Summary
 byte[] decrypt(byte[] cipherData, byte[] secretKeyBytes)
           
 byte[] encrypt(byte[] plainTextBytes, byte[] secretKeyBytes)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TripleDESCBC

public TripleDESCBC()
Method Detail

encrypt

public byte[] encrypt(byte[] plainTextBytes,
                      byte[] secretKeyBytes)
               throws java.lang.Exception
Specified by:
encrypt in interface IEncryptionAlgorithm
Parameters:
plainTextBytes -
secretKeyBytes -
Returns:
encrypted bytes.
Throws:
java.lang.Exception

decrypt

public byte[] decrypt(byte[] cipherData,
                      byte[] secretKeyBytes)
               throws java.lang.Exception
Specified by:
decrypt in interface IEncryptionAlgorithm
Parameters:
cipherData -
secretKeyBytes -
Returns:
decrypted bytes.
Throws:
java.lang.Exception


copyright© 2001-2004 by webMethods All Rights Reserved.