|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.xml.ws.security.opt.impl.enc.CryptoProcessor
public class CryptoProcessor
| Field Summary | |
|---|---|
protected javax.crypto.Cipher |
cipher
|
protected javax.xml.crypto.Data |
data
|
protected java.security.Key |
key
|
| Constructor Summary | |
|---|---|
CryptoProcessor()
|
|
CryptoProcessor(int mode,
java.lang.String algo,
javax.xml.crypto.Data ed,
java.security.Key key)
Creates a new instance of EncryptionProcessor |
|
CryptoProcessor(int mode,
java.lang.String algo,
java.security.Key key)
|
|
CryptoProcessor(int mode,
java.lang.String algo,
java.security.Key dk,
java.security.Key key)
|
|
| Method Summary | |
|---|---|
protected java.lang.String |
convertAlgURIToTransformation(java.lang.String algorithmURI)
Convert algorithm URI to actual transformation (DES/CBC/PKCS5Padding) |
byte[] |
decryptData(byte[] encryptedContent)
decrypts the encryptedContent which a byte[] |
java.io.InputStream |
decryptData(java.io.InputStream is)
decrypts the given data which is of the form InputStream |
java.security.Key |
decryptKey(byte[] encryptedKey,
java.lang.String encAlgo)
decrypts the encrypted key which is a byte[] with encAlgo algorithm |
void |
encrypt(java.io.OutputStream outputStream)
encrypts outputStream |
byte[] |
encryptData(byte[] cipherInput)
initialises the Cipher and encrypts the data which is a byte[] and returns the encrypted data |
void |
encryptData(java.io.OutputStream eos)
initialises the Cipher and encrypts the data which is a OutputStream and writes the encrypted data into the data member |
void |
encryptKey(java.io.OutputStream outputStream)
wraps the data encryption key to byte[] and writes it to output stream |
protected java.lang.String |
getAlgorithm()
|
byte[] |
getCipherValueOfEK()
wraps the data encryption key . |
protected java.security.Key |
getKey()
|
protected void |
initCipher()
creates an instance of javax.crypto.Cipher class and inits it . |
void |
setEncryptedDataCV(byte[] cv)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected javax.crypto.Cipher cipher
protected java.security.Key key
protected javax.xml.crypto.Data data
| Constructor Detail |
|---|
public CryptoProcessor()
public CryptoProcessor(int mode,
java.lang.String algo,
javax.xml.crypto.Data ed,
java.security.Key key)
throws XWSSecurityException
XWSSecurityException
public CryptoProcessor(int mode,
java.lang.String algo,
java.security.Key dk,
java.security.Key key)
throws XWSSecurityException
XWSSecurityException
public CryptoProcessor(int mode,
java.lang.String algo,
java.security.Key key)
throws XWSSecurityException
XWSSecurityException| Method Detail |
|---|
protected void initCipher()
throws java.security.NoSuchAlgorithmException,
javax.crypto.NoSuchPaddingException,
java.security.InvalidKeyException
java.security.NoSuchAlgorithmException
javax.crypto.NoSuchPaddingException
java.security.InvalidKeyExceptionprotected java.lang.String getAlgorithm()
protected java.lang.String convertAlgURIToTransformation(java.lang.String algorithmURI)
algorithmURI -
protected java.security.Key getKey()
public void encrypt(java.io.OutputStream outputStream)
throws java.io.IOException
outputStream -
java.io.IOExceptionpublic byte[] getCipherValueOfEK()
public void encryptKey(java.io.OutputStream outputStream)
throws java.io.IOException
outputStream - OutputStream
java.io.IOExceptionpublic void setEncryptedDataCV(byte[] cv)
public byte[] encryptData(byte[] cipherInput)
cipherInput - byte[]
public void encryptData(java.io.OutputStream eos)
throws java.io.IOException
eos - OutputStream
java.io.IOException
public java.security.Key decryptKey(byte[] encryptedKey,
java.lang.String encAlgo)
throws java.io.IOException
encryptedKey - byte[]encAlgo - String
java.io.IOException
public java.io.InputStream decryptData(java.io.InputStream is)
throws java.io.IOException
is - InputStream
java.io.IOException
public byte[] decryptData(byte[] encryptedContent)
throws java.io.IOException
encryptedContent - byte[]
java.io.IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||