public final class DOMXMLSignature extends DOMStructure implements javax.xml.crypto.dsig.XMLSignature
Modifier and Type | Class and Description |
---|---|
class |
DOMXMLSignature.DOMSignatureValue |
Constructor and Description |
---|
DOMXMLSignature(org.w3c.dom.Element sigElem,
javax.xml.crypto.XMLCryptoContext context,
java.security.Provider provider)
Creates a
DOMXMLSignature from XML. |
DOMXMLSignature(javax.xml.crypto.dsig.SignedInfo si,
javax.xml.crypto.dsig.keyinfo.KeyInfo ki,
java.util.List<? extends javax.xml.crypto.dsig.XMLObject> objs,
java.lang.String id,
java.lang.String signatureValueId)
Creates a
DOMXMLSignature from the specified components. |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
java.lang.String |
getId() |
javax.xml.crypto.dsig.keyinfo.KeyInfo |
getKeyInfo() |
javax.xml.crypto.KeySelectorResult |
getKeySelectorResult() |
java.util.List |
getObjects() |
javax.xml.crypto.dsig.XMLSignature.SignatureValue |
getSignatureValue() |
javax.xml.crypto.dsig.SignedInfo |
getSignedInfo() |
void |
marshal(org.w3c.dom.Node parent,
org.w3c.dom.Node nextSibling,
java.lang.String dsPrefix,
javax.xml.crypto.dom.DOMCryptoContext context) |
void |
marshal(org.w3c.dom.Node parent,
java.lang.String dsPrefix,
javax.xml.crypto.dom.DOMCryptoContext context) |
void |
sign(javax.xml.crypto.dsig.XMLSignContext signContext) |
boolean |
validate(javax.xml.crypto.dsig.XMLValidateContext vc) |
isFeatureSupported
public DOMXMLSignature(javax.xml.crypto.dsig.SignedInfo si, javax.xml.crypto.dsig.keyinfo.KeyInfo ki, java.util.List<? extends javax.xml.crypto.dsig.XMLObject> objs, java.lang.String id, java.lang.String signatureValueId)
DOMXMLSignature
from the specified components.si
- the SignedInfo
ki
- the KeyInfo
, or null
if not specifiedobjs
- a list of XMLObject
s or null
if not specified. The list is copied to protect against subsequent
modification.id
- an optional id (specify null
to omit)signatureValueId
- an optional id (specify null
to
omit)java.lang.NullPointerException
- if si
is null
public DOMXMLSignature(org.w3c.dom.Element sigElem, javax.xml.crypto.XMLCryptoContext context, java.security.Provider provider) throws javax.xml.crypto.MarshalException
DOMXMLSignature
from XML.sigElem
- Signature elementjavax.xml.crypto.MarshalException
- if XMLSignature cannot be unmarshalledpublic java.lang.String getId()
getId
in interface javax.xml.crypto.dsig.XMLSignature
public javax.xml.crypto.dsig.keyinfo.KeyInfo getKeyInfo()
getKeyInfo
in interface javax.xml.crypto.dsig.XMLSignature
public javax.xml.crypto.dsig.SignedInfo getSignedInfo()
getSignedInfo
in interface javax.xml.crypto.dsig.XMLSignature
public java.util.List getObjects()
getObjects
in interface javax.xml.crypto.dsig.XMLSignature
public javax.xml.crypto.dsig.XMLSignature.SignatureValue getSignatureValue()
getSignatureValue
in interface javax.xml.crypto.dsig.XMLSignature
public javax.xml.crypto.KeySelectorResult getKeySelectorResult()
getKeySelectorResult
in interface javax.xml.crypto.dsig.XMLSignature
public void marshal(org.w3c.dom.Node parent, java.lang.String dsPrefix, javax.xml.crypto.dom.DOMCryptoContext context) throws javax.xml.crypto.MarshalException
marshal
in class DOMStructure
javax.xml.crypto.MarshalException
public void marshal(org.w3c.dom.Node parent, org.w3c.dom.Node nextSibling, java.lang.String dsPrefix, javax.xml.crypto.dom.DOMCryptoContext context) throws javax.xml.crypto.MarshalException
javax.xml.crypto.MarshalException
public boolean validate(javax.xml.crypto.dsig.XMLValidateContext vc) throws javax.xml.crypto.dsig.XMLSignatureException
validate
in interface javax.xml.crypto.dsig.XMLSignature
javax.xml.crypto.dsig.XMLSignatureException
public void sign(javax.xml.crypto.dsig.XMLSignContext signContext) throws javax.xml.crypto.MarshalException, javax.xml.crypto.dsig.XMLSignatureException
sign
in interface javax.xml.crypto.dsig.XMLSignature
javax.xml.crypto.MarshalException
javax.xml.crypto.dsig.XMLSignatureException
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object