public class WSSecDKEncrypt extends WSSecDerivedKeyBase
| Modifier and Type | Field and Description |
|---|---|
protected String |
symEncAlgo |
clientLabel, derivedKeyBytes, derivedKeyLength, dkt, dktId, document, envelope, ephemeralKey, serviceLabel, strElem, tokenIdDirectId, tokenIdentifier| Constructor and Description |
|---|
WSSecDKEncrypt() |
| Modifier and Type | Method and Description |
|---|---|
void |
addExternalRefElement(org.w3c.dom.Element referenceList,
WSSecHeader secHeader)
Adds (prepends) the external Reference element to the Security header.
|
org.w3c.dom.Document |
build(org.w3c.dom.Document doc,
WSSecHeader secHeader) |
static org.w3c.dom.Element |
createDataRefList(org.w3c.dom.Document doc,
org.w3c.dom.Element referenceList,
Vector encDataRefs) |
org.w3c.dom.Element |
encryptForExternalRef(org.w3c.dom.Element dataRef,
Vector references)
Encrypt one or more parts or elements of the message (external).
|
protected int |
getDerivedKeyLength()
The derived key will change depending on the sig/encr algorithm.
|
void |
setSymmetricEncAlgorithm(String algo) |
appendDKElementToHeader, getdktElement, getId, getTokenIdentifier, prepare, prependDKElementToHeader, setClientLabel, setCustomValueType, setDerivedKeyLength, setExternalKey, setExternalKey, setServiceLabel, setTokenIdDirectId, setWscVersiongetKeyIdentifierType, setBodyID, setKeyIdentifierType, setParts, setUserInfo, setWsConfig, setWsuIdprotected String symEncAlgo
public org.w3c.dom.Document build(org.w3c.dom.Document doc,
WSSecHeader secHeader)
throws WSSecurityException,
ConversationException
public org.w3c.dom.Element encryptForExternalRef(org.w3c.dom.Element dataRef,
Vector references)
throws WSSecurityException
WSEncryptionPart object that
contain information about the elements to encrypt. The method call the
encryption method, takes the reference information generated during
encryption and add this to the xenc:Reference element.
This method can be called after prepare() and can be
called multiple times to encrypt a number of parts or elements.
The method generates a xenc:Reference element that must
be added to the SecurityHeader. See addExternalRefElement().
If the dataRef parameter is null the method
creates and initializes a new Reference element.dataRef - A xenc:Reference element or nullreferences - A vector containing WSEncryptionPart objectsxenc:Reference elementWSSecurityExceptionpublic void addExternalRefElement(org.w3c.dom.Element referenceList,
WSSecHeader secHeader)
encryptForExternalRef() method. The method adds the
reference element in the SecurityHeader.referenceList - The external enc:Reference elementsecHeader - The security header.public static org.w3c.dom.Element createDataRefList(org.w3c.dom.Document doc,
org.w3c.dom.Element referenceList,
Vector encDataRefs)
public void setSymmetricEncAlgorithm(String algo)
protected int getDerivedKeyLength()
throws WSSecurityException
WSSecDerivedKeyBasegetDerivedKeyLength in class WSSecDerivedKeyBaseWSSecurityExceptionWSSecDerivedKeyBase.getDerivedKeyLength()Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.