APIdia Launch Partner
Top Description Inners Fields Constructors Methods
org.jcp.xml.dsig.internal.dom

public abstract Class DOMSignatureMethod

extends AbstractDOMSignatureMethod
Class Inheritance
Known Direct Subclasses
org.jcp.xml.dsig.internal.dom.DOMSignatureMethod.AbstractRSASignatureMethod, org.jcp.xml.dsig.internal.dom.DOMSignatureMethod.AbstractP1363FormatSignatureMethod, org.jcp.xml.dsig.internal.dom.DOMSignatureMethod.AbstractEDDSASignatureMethod
Imports
java.io.IOException, java.security.InvalidAlgorithmParameterException, .InvalidKeyException, .Key, .NoSuchAlgorithmException, .PrivateKey, .Provider, .PublicKey, .SecureRandom, .Signature, .SignatureException, java.security.interfaces.DSAKey, .ECPrivateKey, java.security.spec.AlgorithmParameterSpec, .MGF1ParameterSpec, .PSSParameterSpec, javax.xml.crypto.XMLCryptoContext, .MarshalException, javax.xml.crypto.dsig.SignatureMethod, .SignedInfo, .XMLSignContext, .XMLSignatureException, .XMLValidateContext, javax.xml.crypto.dsig.spec.SignatureMethodParameterSpec, org.jcp.xml.dsig.internal.SignerOutputStream, com.sun.org.apache.xml.internal.security.algorithms.implementations.SignatureECDSA, com.sun.org.apache.xml.internal.security.utils.JavaUtils, org.w3c.dom.Element, sun.security.util.KeyUtil

DOM-based abstract implementation of SignatureMethod.

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv abstract static class
pack-priv abstract static class
pack-priv abstract static class
pack-priv abstract static class
DOMSignatureMethod.AbstractP1363FormatSignatureMethod

Abstract class to support signature algorithms that sign and verify signatures in the IEEE P1363 format.

pack-priv abstract static class
pack-priv abstract static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class
pack-priv static class

Field Summary

Modifier and TypeField and Description
private static final String
private static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
private static final Logger
private SignatureMethodParameterSpec
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
pack-priv static final String
private Signature

Constructor Summary

AccessConstructor and Description
pack-priv
DOMSignatureMethod(AlgorithmParameterSpec
the algorithm-specific params (may be null)
params
)

Creates a DOMSignatureMethod.

pack-priv
DOMSignatureMethod(Element
a SignatureMethod element
smElem
)

Creates a DOMSignatureMethod from an element.

Method Summary

Modifier and TypeMethod and Description
private static void
checkKeySize(XMLCryptoContext
the context
context
,
Key
the key to check
key
)

If secure validation mode is enabled, checks that the key size is restricted.

public final AlgorithmParameterSpec
getParameterSpec()

Implements javax.xml.crypto.dsig.SignatureMethod.getParameterSpec.

Returns the algorithm-specific input parameters of this SignatureMethod.

pack-priv Signature

Returns:

an instance of Signature implementing the algorithm specified by getJCAAlgorithm()
getSignature
(Provider
the Provider to use
p
)

Returns an instance of Signature from the specified Provider.

pack-priv abstract byte[]

Returns:

the formatted signature
postSignFormat
(Key
the key used to sign
key
,
byte[]
the signature returned by Signature.sign()
sig
)

Returns the signature bytes with any additional formatting necessary for the signature algorithm used.

pack-priv abstract byte[]

Returns:

the formatted signature
preVerifyFormat
(Key
the key used to sign
key
,
byte[]
the signature
sig
)

Returns the signature bytes with any conversions that are necessary before the signature can be verified.

pack-priv byte[]
sign(Key key, SignedInfo si, XMLSignContext context)

Implements abstract org.jcp.xml.dsig.internal.dom.AbstractDOMSignatureMethod.sign.

Signs the bytes with the specified key, using the underlying Signature or Mac algorithm.

pack-priv static SignatureMethod
pack-priv boolean
verify(Key key, SignedInfo si, byte[] sig, XMLValidateContext context)

Implements abstract org.jcp.xml.dsig.internal.dom.AbstractDOMSignatureMethod.verify.

Verifies the passed-in signature with the specified key, using the underlying Signature or Mac algorithm.

Inherited from org.jcp.xml.dsig.internal.dom.AbstractDOMSignatureMethod:
checkParamsequalsgetAlgorithmTypegetJCAAlgorithmhashCodemarshalmarshalParamsparamsEqualunmarshalParams