public class WSSecDKSign extends WSSecDerivedKeyBase
attachmentCallbackHandler, callbackLookup, expandXopInclude, keyIdentifierType, password, storeBytesInAttachment, user| Constructor and Description |
|---|
WSSecDKSign(Document doc) |
WSSecDKSign(Document doc,
Provider provider) |
WSSecDKSign(WSSecHeader securityHeader) |
| Modifier and Type | Method and Description |
|---|---|
List<Reference> |
addReferencesToSign(List<WSEncryptionPart> references)
This method adds references to the Signature.
|
Document |
build() |
void |
computeSignature(List<Reference> referenceList)
Compute the Signature over the references.
|
void |
computeSignature(List<Reference> referenceList,
boolean prepend,
Element siblingElement)
Compute the Signature over the references.
|
protected int |
getDerivedKeyLength()
The derived key will change depending on the sig/encr algorithm.
|
String |
getDigestAlgorithm() |
String |
getSigCanonicalization()
Get the canonicalization method.
|
String |
getSignatureAlgorithm() |
Element |
getSignatureElement()
Returns the SignatureElement.
|
String |
getSignatureId()
Returns the the value of wsu:Id attribute of the Signature element.
|
byte[] |
getSignatureValue() |
boolean |
isAddInclusivePrefixes() |
void |
prepare()
Initialize a WSSec Derived key.
|
void |
setAddInclusivePrefixes(boolean addInclusivePrefixes) |
void |
setDerivedKeyLength(int keyLength) |
void |
setDigestAlgorithm(String algorithm)
Set the digest algorithm to use.
|
void |
setSigCanonicalization(String algo)
Set the canonicalization method to use.
|
void |
setSignatureAlgorithm(String algorithm)
Set the signature algorithm to use.
|
appendDKElementToHeader, getDerivedKey, getdktElement, getId, getTokenIdentifier, getWscVersion, prependDKElementToHeader, setClientLabel, setCrypto, setCustomValueType, setExternalKey, setExternalKey, setServiceLabel, setTokenIdDirectId, setWscVersion, setX509CertificateaddReferencesToSign, cleanup, createSTRParameter, getInclusivePrefixes, getInclusivePrefixesgetDocument, getIdAllocator, getKeyIdentifierType, getParts, getSecurityHeader, getWsDocInfo, isExpandXopInclude, setAttachmentCallbackHandler, setBodyID, setCallbackLookup, setExpandXopInclude, setIdAllocator, setKeyIdentifierType, setStoreBytesInAttachment, setUserInfo, setWsDocInfo, setWsuIdpublic WSSecDKSign(WSSecHeader securityHeader)
public WSSecDKSign(Document doc)
public Document build() throws WSSecurityException
WSSecurityExceptionpublic void prepare()
throws WSSecurityException
WSSecDerivedKeyBaseprepare in class WSSecDerivedKeyBaseWSSecurityExceptionpublic Element getSignatureElement()
prepare().public List<Reference> addReferencesToSign(List<WSEncryptionPart> references) throws WSSecurityException
references - The list of references to signWSSecurityExceptionpublic void computeSignature(List<Reference> referenceList) throws WSSecurityException
addReferencesToSign().WSSecurityExceptionpublic void computeSignature(List<Reference> referenceList, boolean prepend, Element siblingElement) throws WSSecurityException
addReferencesToSign().WSSecurityExceptionprotected int getDerivedKeyLength()
throws WSSecurityException
WSSecDerivedKeyBasegetDerivedKeyLength in class WSSecDerivedKeyBaseWSSecurityExceptionpublic void setDerivedKeyLength(int keyLength)
public void setSignatureAlgorithm(String algorithm)
algorithm - the signature algorithm to use.public String getSignatureAlgorithm()
public String getSignatureId()
public void setDigestAlgorithm(String algorithm)
algorithm - the digest algorithm to use.public String getDigestAlgorithm()
public byte[] getSignatureValue()
public void setSigCanonicalization(String algo)
algo - Is the name of the signature algorithmWSS4JConstants.C14N_OMIT_COMMENTS,
WSS4JConstants.C14N_WITH_COMMENTS,
WSS4JConstants.C14N_EXCL_OMIT_COMMENTS,
WSS4JConstants.C14N_EXCL_WITH_COMMENTSpublic String getSigCanonicalization()
public boolean isAddInclusivePrefixes()
public void setAddInclusivePrefixes(boolean addInclusivePrefixes)
Copyright © 2019 JBoss by Red Hat. All rights reserved.