public abstract class WSSecDerivedKeyBase extends WSSecSignatureBase
addWSUNamespace, attachmentCallbackHandler, callbackLookup, expandXopInclude, keyIdentifierType, password, storeBytesInAttachment, user| Constructor and Description |
|---|
WSSecDerivedKeyBase(Document doc) |
WSSecDerivedKeyBase(WSSecHeader securityHeader) |
| Modifier and Type | Method and Description |
|---|---|
void |
appendDKElementToHeader() |
void |
clean() |
protected SecretKey |
getDerivedKey(String algorithm) |
protected abstract int |
getDerivedKeyLength()
The derived key will change depending on the sig/encr algorithm.
|
Element |
getdktElement() |
String |
getId()
Get the id generated during
prepare(). |
Element |
getStrElem() |
String |
getTokenIdentifier() |
int |
getWscVersion() |
void |
prepare(byte[] ephemeralKey)
Initialize a WSSec Derived key.
|
void |
prependDKElementToHeader()
Prepend the DerivedKey element to the elements already in the Security
header.
|
void |
setClientLabel(String clientLabel)
Set the label value of the client.
|
void |
setCrypto(Crypto crypto) |
void |
setCustomValueType(String customValueType) |
void |
setServiceLabel(String serviceLabel)
Set the label value of the service.
|
void |
setStrElem(Element strElem) |
void |
setTokenIdDirectId(boolean b) |
void |
setTokenIdentifier(String tokenIdentifier) |
void |
setWscVersion(int wscVersion) |
void |
setX509Certificate(X509Certificate cer)
Set the X509 Certificate to use
|
addReferencesToSign, cleanup, createSTRParameter, getInclusivePrefixes, getInclusivePrefixesgetDocument, getIdAllocator, getKeyIdentifierType, getParts, getSecurityHeader, getWsDocInfo, isExpandXopInclude, setAttachmentCallbackHandler, setBodyID, setCallbackLookup, setExpandXopInclude, setIdAllocator, setKeyIdentifierType, setStoreBytesInAttachment, setUserInfo, setWsDocInfo, setWsuIdpublic WSSecDerivedKeyBase(WSSecHeader securityHeader)
public WSSecDerivedKeyBase(Document doc)
protected abstract int getDerivedKeyLength()
throws WSSecurityException
WSSecurityExceptionpublic Element getStrElem()
public void setStrElem(Element strElem)
public void setTokenIdentifier(String tokenIdentifier)
public String getTokenIdentifier()
public void setX509Certificate(X509Certificate cer)
cer - the X509 Certificate to usepublic String getId()
prepare().
Returns the the value of wsu:Id attribute of the DerivedKeyToken element.prepare()
was not called before.public void setClientLabel(String clientLabel)
clientLabel - public void setServiceLabel(String serviceLabel)
serviceLabel - public void prepare(byte[] ephemeralKey)
throws WSSecurityException
ephemeralKey - The ephemeral key to use for derivationWSSecurityExceptionpublic void prependDKElementToHeader()
prepare(). This
allows to insert the DerivedKey element at any position in the Security
header.public void appendDKElementToHeader()
public void setWscVersion(int wscVersion)
wscVersion - The wscVersion to set.public int getWscVersion()
public Element getdktElement()
public void setCustomValueType(String customValueType)
public void setTokenIdDirectId(boolean b)
public void setCrypto(Crypto crypto)
Copyright © 2004–2021 The Apache Software Foundation. All rights reserved.