|
XML Digital Signature and Encryption, 1.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface EncryptedType
A representation of the XML EncryptedType
element as defined in the
W3C Recommendation for XML-Encryption Syntax and Processing.
Its schema definition is as follows:
Field Summary | |
---|---|
static java.lang.String |
CONTENT
The encrypted element content type URI. |
static java.lang.String |
ELEMENT
The encrypted element type URI. |
static java.lang.String |
XMLNS
The XML Encryption namespace URI |
Method Summary | |
---|---|
java.io.InputStream |
decrypt(XMLDecryptContext context)
Decrypts the CipherData in this EncryptedData . |
void |
encrypt(XMLEncryptContext context)
Encrypts the ToBeEncrypted passed to the construction of this EncryptedType and inserts it in the CipherValue or CipherReference of the CipherData of this
EncryptedData . |
CipherData |
getCipherData()
Returns the cipher data containing the encrypted data. |
java.io.InputStream |
getCipherText()
Returns the encrypted data if the EncryptedType stores the encrypted data as CipherReference. |
java.lang.String |
getEncoding()
Returns a URI identifying the transfer encoding of the data that has been encrypted. |
EncryptionMethod |
getEncryptionMethod()
Returns the encryption method applied to the cipher data. |
EncryptionProperties |
getEncryptionProperties()
Returns the encryption properties associated with this encrypted type. |
java.lang.String |
getId()
Returns the optional ID . |
KeyInfo |
getKeyInfo()
Returns the key info that carries information about the key used to encrypt the data. |
java.lang.String |
getMimeType()
Returns the mime type of the data that has been encrypted. |
ToBeEncrypted |
getToBeEncrypted()
Returns the data to be encrypted if there is any |
java.lang.String |
getType()
Returns a URI identifying the type of the plaintext form of the encrypted content. |
Methods inherited from interface javax.xml.crypto.XMLStructure |
---|
isFeatureSupported |
Field Detail |
---|
static final java.lang.String XMLNS
static final java.lang.String CONTENT
static final java.lang.String ELEMENT
Method Detail |
---|
EncryptionMethod getEncryptionMethod()
null
if not specifiedKeyInfo getKeyInfo()
null
if not specifiedCipherData getCipherData()
null
if the data is a CipherValue
and the data has not been encrypted yetEncryptionProperties getEncryptionProperties()
null
if not specifiedjava.lang.String getId()
ID
.
ID
, or null
if not specifiedjava.lang.String getType()
null
if not specifiedjava.lang.String getMimeType()
null
if not specifiedjava.lang.String getEncoding()
null
if not specifiedvoid encrypt(XMLEncryptContext context) throws XMLEncryptionException, MarshalException
CipherValue
or CipherReference
of the CipherData
of this
EncryptedData
.
The data is assumed to be serialized by the application before invoking this method.
context
- the encryption context
java.lang.NullPointerException
- if context is null
MarshalException
- if an error occurs while marshalling
XMLEncryptionException
- if an error occurs while encryptingjava.io.InputStream decrypt(XMLDecryptContext context) throws XMLEncryptionException
CipherData
in this EncryptedData
.
context
- the decryption context
CipherData
as an InputStream.
java.lang.NullPointerException
- if context is null
XMLEncryptionException
- if an error occurs while decryptingjava.io.InputStream getCipherText()
java.lang.IllegalStateException
- if a CipherData is not a CipherReference;
or this method is called on a unmarshalled EncryptedType.ToBeEncrypted getToBeEncrypted()
|
XML Digital Signature and Encryption, 1.0 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |