Class IntegrityHmac
java.lang.Object
org.apache.xml.security.algorithms.SignatureAlgorithmSpi
org.apache.xml.security.algorithms.implementations.IntegrityHmac
- Direct Known Subclasses:
IntegrityHmac.IntegrityHmacMD5,IntegrityHmac.IntegrityHmacRIPEMD160,IntegrityHmac.IntegrityHmacSHA1,IntegrityHmac.IntegrityHmacSHA224,IntegrityHmac.IntegrityHmacSHA256,IntegrityHmac.IntegrityHmacSHA384,IntegrityHmac.IntegrityHmacSHA512
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classClass IntegrityHmacMD5static classClass IntegrityHmacRIPEMD160static classClass IntegrityHmacSHA1static classClass IntegrityHmacSHA224static classClass IntegrityHmacSHA256static classClass IntegrityHmacSHA384static classClass IntegrityHmacSHA512 -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidengineAddContextToElement(Element element) Method engineAddContextToElementprotected voidengineGetContextFromElement(Element element) Method engineGetContextFromElementprotected StringMethod engineGetJCEAlgorithmString Proxy method forSignature.getAlgorithm()which is executed on the internalSignatureobject.protected StringMethod engineGetJCEAlgorithmString Method engineGetJCEProviderNameabstract StringMethod engineGetURI Returns the URI representation ofTransformation algorithmprotected voidengineInitSign(Key secretKey) Method engineInitSignprotected voidengineInitSign(Key secretKey, SecureRandom secureRandom) Method engineInitSignprotected voidengineInitSign(Key secretKey, AlgorithmParameterSpec algorithmParameterSpec) Method engineInitSignprotected voidengineInitVerify(Key secretKey) Proxy method forSignature.initVerify(java.security.PublicKey)which is executed on the internalSignatureobject.protected voidengineSetHMACOutputLength(int HMACOutputLength) Method engineSetHMACOutputLengthprotected voidProxy method forSignature.setParameter(java.security.spec.AlgorithmParameterSpec)which is executed on the internalSignatureobject.protected byte[]Proxy method forSignature.sign()which is executed on the internalSignatureobject.protected voidengineUpdate(byte input) Proxy method forSignature.update(byte)which is executed on the internalSignatureobject.protected voidengineUpdate(byte[] input) Proxy method forSignature.update(byte[])which is executed on the internalSignatureobject.protected voidengineUpdate(byte[] buf, int offset, int len) Proxy method forSignature.update(byte[], int, int)which is executed on the internalSignatureobject.protected booleanengineVerify(byte[] signature) Proxy method forSignature.verify(byte[])which is executed on the internalSignatureobject.voidreset()
-
Constructor Details
-
IntegrityHmac
Method IntegrityHmac- Throws:
XMLSignatureException
-
-
Method Details
-
engineGetURI
Method engineGetURI Returns the URI representation ofTransformation algorithm- Specified by:
engineGetURIin classSignatureAlgorithmSpi- Returns:
- the URI representation of
Transformation algorithm
-
engineSetParameter
Proxy method forSignature.setParameter(java.security.spec.AlgorithmParameterSpec)which is executed on the internalSignatureobject.- Specified by:
engineSetParameterin classSignatureAlgorithmSpi- Parameters:
params-- Throws:
XMLSignatureException
-
reset
public void reset()- Overrides:
resetin classSignatureAlgorithmSpi
-
engineVerify
Proxy method forSignature.verify(byte[])which is executed on the internalSignatureobject.- Specified by:
engineVerifyin classSignatureAlgorithmSpi- Parameters:
signature-- Returns:
- true if the signature is correct
- Throws:
XMLSignatureException
-
engineInitVerify
Proxy method forSignature.initVerify(java.security.PublicKey)which is executed on the internalSignatureobject.- Specified by:
engineInitVerifyin classSignatureAlgorithmSpi- Parameters:
secretKey-- Throws:
XMLSignatureException
-
engineSign
Proxy method forSignature.sign()which is executed on the internalSignatureobject.- Specified by:
engineSignin classSignatureAlgorithmSpi- Returns:
- the result of the
Signature.sign()method - Throws:
XMLSignatureException
-
engineInitSign
Method engineInitSign- Specified by:
engineInitSignin classSignatureAlgorithmSpi- Parameters:
secretKey-- Throws:
XMLSignatureException
-
engineInitSign
protected void engineInitSign(Key secretKey, AlgorithmParameterSpec algorithmParameterSpec) throws XMLSignatureException Method engineInitSign- Specified by:
engineInitSignin classSignatureAlgorithmSpi- Parameters:
secretKey-algorithmParameterSpec-- Throws:
XMLSignatureException
-
engineInitSign
protected void engineInitSign(Key secretKey, SecureRandom secureRandom) throws XMLSignatureException Method engineInitSign- Specified by:
engineInitSignin classSignatureAlgorithmSpi- Parameters:
secretKey-secureRandom-- Throws:
XMLSignatureException
-
engineUpdate
Proxy method forSignature.update(byte[])which is executed on the internalSignatureobject.- Specified by:
engineUpdatein classSignatureAlgorithmSpi- Parameters:
input-- Throws:
XMLSignatureException
-
engineUpdate
Proxy method forSignature.update(byte)which is executed on the internalSignatureobject.- Specified by:
engineUpdatein classSignatureAlgorithmSpi- Parameters:
input-- Throws:
XMLSignatureException
-
engineUpdate
Proxy method forSignature.update(byte[], int, int)which is executed on the internalSignatureobject.- Specified by:
engineUpdatein classSignatureAlgorithmSpi- Parameters:
buf-offset-len-- Throws:
XMLSignatureException
-
engineGetJCEAlgorithmString
Method engineGetJCEAlgorithmString Proxy method forSignature.getAlgorithm()which is executed on the internalSignatureobject.- Specified by:
engineGetJCEAlgorithmStringin classSignatureAlgorithmSpi- Returns:
- the result of the
Signature.getAlgorithm()method
-
engineGetJCEProviderName
Method engineGetJCEAlgorithmString Method engineGetJCEProviderName- Specified by:
engineGetJCEProviderNamein classSignatureAlgorithmSpi- Returns:
- the JCE ProviderName
-
engineSetHMACOutputLength
protected void engineSetHMACOutputLength(int HMACOutputLength) Method engineSetHMACOutputLength- Specified by:
engineSetHMACOutputLengthin classSignatureAlgorithmSpi- Parameters:
HMACOutputLength-
-
engineGetContextFromElement
Method engineGetContextFromElement- Overrides:
engineGetContextFromElementin classSignatureAlgorithmSpi- Parameters:
element-
-
engineAddContextToElement
Method engineAddContextToElement- Parameters:
element-
-