|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.xml.security.utils.ElementProxy | +--org.apache.xml.security.algorithms.Algorithm | +--org.apache.xml.security.algorithms.SignatureAlgorithm
Allows selection of digital signature's algorithm, private keys, other security parameters, and algorithm's ID.
The exists no constructor but the #getInstance
methods to obtain instances of this class.
SignatureAlgorithm.getInstance()
Field Summary | |
protected SignatureAlgorithmSpi |
_signatureAlgorithm
Field _signatureAlgorithm |
Fields inherited from class org.apache.xml.security.utils.ElementProxy |
_baseURI, _constructionElement, _doc, _state, MODE_CREATE, MODE_DECRYPT, MODE_ENCRYPT, MODE_PROCESS, MODE_SIGN, MODE_UNKNOWN, MODE_VERIFY |
Constructor Summary | |
SignatureAlgorithm(org.w3c.dom.Document doc,
java.lang.String algorithmURI)
Constructor SignatureAlgorithm |
|
SignatureAlgorithm(org.w3c.dom.Document doc,
java.lang.String algorithmURI,
int HMACOutputLength)
Constructor SignatureAlgorithm |
|
SignatureAlgorithm(org.w3c.dom.Element element,
java.lang.String BaseURI)
Constructor SignatureAlgorithm |
Method Summary | |
java.lang.String |
getBaseLocalName()
Returns the localname of the Elements of the sub-class. |
java.lang.String |
getBaseNamespace()
Method getBaseNamespace |
java.lang.String |
getJCEAlgorithmString()
Proxy method for Signature.getAlgorithm()
which is executed on the internal Signature object. |
java.lang.String |
getJCEProviderName()
Method getJCEProviderName |
java.lang.String |
getURI()
Returns the URI representation of Transformation algorithm |
void |
initSign(java.security.Key secretKey)
Method initSign |
void |
initSign(java.security.Key secretKey,
java.security.spec.AlgorithmParameterSpec algorithmParameterSpec)
Method initSign |
void |
initSign(java.security.PrivateKey privateKey)
Proxy method for Signature.initSign(java.security.PrivateKey)
which is executed on the internal Signature object. |
void |
initSign(java.security.PrivateKey privateKey,
java.security.SecureRandom secureRandom)
Proxy method for Signature.initSign(java.security.PrivateKey)
which is executed on the internal Signature object. |
void |
initVerify(java.security.Key secretkey)
Method initVerify |
void |
initVerify(java.security.PublicKey publickey)
Proxy method for Signature.initVerify(java.security.PublicKey)
which is executed on the internal Signature object. |
static void |
providerInit()
Initalizes for this Transform |
static void |
register(java.lang.String algorithmURI,
java.lang.String implementingClass)
Registers implementing class of the transfrom algorithm with algorithmURI |
void |
setParameter(java.security.spec.AlgorithmParameterSpec params)
Proxy method for Signature.setParameter(java.lang.String, java.lang.Object)
which is executed on the internal Signature object. |
byte[] |
sign()
Proxy method for Signature.sign()
which is executed on the internal Signature object. |
void |
update(byte input)
Proxy method for Signature.update(byte)
which is executed on the internal Signature object. |
void |
update(byte[] input)
Proxy method for Signature.update(byte)
which is executed on the internal Signature object. |
void |
update(byte[] buf,
int offset,
int len)
Proxy method for Signature.update(byte)
which is executed on the internal Signature object. |
boolean |
verify(byte[] signature)
Proxy method for Signature.verify(byte[])
which is executed on the internal Signature object. |
Methods inherited from class org.apache.xml.security.algorithms.Algorithm |
getAlgorithmURI, setAlgorithmURI |
Methods inherited from class org.apache.xml.security.utils.ElementProxy |
addBase64Element, addBase64Text, addBigIntegerElement, addText, addTextElement, createElementForFamily, getBaseURI, getBigIntegerFromChildElement, getBytesFromChildElement, getBytesFromTextChild, getChildElementLocalName, getDefaultPrefix, getDocument, getElement, getElementPlusReturns, getTextFromChildElement, getTextFromTextChild, guaranteeThatElementInCorrectSpace, length, setDefaultPrefix, setElement, setXPathNamespaceContext |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected SignatureAlgorithmSpi _signatureAlgorithm
Constructor Detail |
public SignatureAlgorithm(org.w3c.dom.Document doc, java.lang.String algorithmURI) throws XMLSecurityException
doc
- algorithmURI
-
XMLSecurityException
public SignatureAlgorithm(org.w3c.dom.Document doc, java.lang.String algorithmURI, int HMACOutputLength) throws XMLSecurityException
doc
- algorithmURI
- HMACOutputLength
-
XMLSecurityException
public SignatureAlgorithm(org.w3c.dom.Element element, java.lang.String BaseURI) throws XMLSecurityException
element
- BaseURI
-
XMLSecurityException
Method Detail |
public byte[] sign() throws XMLSignatureException
Signature.sign()
which is executed on the internal Signature
object.
Signature.sign()
method
XMLSignatureException
public java.lang.String getJCEAlgorithmString()
Signature.getAlgorithm()
which is executed on the internal Signature
object.
Signature.getAlgorithm()
methodpublic java.lang.String getJCEProviderName()
public void update(byte[] input) throws XMLSignatureException
Signature.update(byte)
which is executed on the internal Signature
object.
input
-
XMLSignatureException
public void update(byte input) throws XMLSignatureException
Signature.update(byte)
which is executed on the internal Signature
object.
input
-
XMLSignatureException
public void update(byte[] buf, int offset, int len) throws XMLSignatureException
Signature.update(byte)
which is executed on the internal Signature
object.
buf
- offset
- len
-
XMLSignatureException
public void initSign(java.security.PrivateKey privateKey, java.security.SecureRandom secureRandom) throws XMLSignatureException
Signature.initSign(java.security.PrivateKey)
which is executed on the internal Signature
object.
privateKey
- secureRandom
-
XMLSignatureException
public void initSign(java.security.PrivateKey privateKey) throws XMLSignatureException
Signature.initSign(java.security.PrivateKey)
which is executed on the internal Signature
object.
privateKey
-
XMLSignatureException
public void initSign(java.security.Key secretKey) throws XMLSignatureException
secretKey
-
XMLSignatureException
public void initSign(java.security.Key secretKey, java.security.spec.AlgorithmParameterSpec algorithmParameterSpec) throws XMLSignatureException
secretKey
- algorithmParameterSpec
-
XMLSignatureException
public void setParameter(java.security.spec.AlgorithmParameterSpec params) throws XMLSignatureException
Signature.setParameter(java.lang.String, java.lang.Object)
which is executed on the internal Signature
object.
params
-
XMLSignatureException
public void initVerify(java.security.PublicKey publickey) throws XMLSignatureException
Signature.initVerify(java.security.PublicKey)
which is executed on the internal Signature
object.
publickey
-
XMLSignatureException
public void initVerify(java.security.Key secretkey) throws XMLSignatureException
secretkey
-
XMLSignatureException
public boolean verify(byte[] signature) throws XMLSignatureException
Signature.verify(byte[])
which is executed on the internal Signature
object.
signature
-
XMLSignatureException
public final java.lang.String getURI()
public static void providerInit()
Transform
public static void register(java.lang.String algorithmURI, java.lang.String implementingClass) throws AlgorithmAlreadyRegisteredException
algorithmURI
- algorithmURI URI representation of transfrom algorithm
will be specified as parameter of #getInstance
, when generate. implementingClass
- implementingClass
the implementing class of TransformSpi
AlgorithmAlreadyRegisteredException
- if specified algorithmURI is already registeredpublic java.lang.String getBaseNamespace()
getBaseNamespace
in class ElementProxy
public java.lang.String getBaseLocalName()
ElementProxy
getBaseLocalName
in class ElementProxy
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |