Package org.bouncycastle.crypto.fips
Class FipsOutputVerifier<T extends Parameters>
- java.lang.Object
-
- org.bouncycastle.crypto.fips.FipsOutputVerifier<T>
-
- Type Parameters:
T- The parameters class for this verifier.
- All Implemented Interfaces:
OutputVerifier<T>
public abstract class FipsOutputVerifier<T extends Parameters> extends java.lang.Object implements OutputVerifier<T>
Base class for a FIPS signature verifier.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract TgetParameters()Return the parameters for this output verifier.abstract UpdateOutputStreamgetVerifyingStream()Returns a stream that will accept data for the purpose of verifying a previously calculated signature.abstract booleanisVerified(byte[] signature)Return true if the data written to the verifying stream matches the data the signature was calculated against.
-
-
-
Method Detail
-
getParameters
public abstract T getParameters()
Description copied from interface:OutputVerifierReturn the parameters for this output verifier.- Specified by:
getParametersin interfaceOutputVerifier<T extends Parameters>- Returns:
- the verifier's parameters.
-
getVerifyingStream
public abstract UpdateOutputStream getVerifyingStream()
Description copied from interface:OutputVerifierReturns a stream that will accept data for the purpose of verifying a previously calculated signature. Use org.bouncycastle.util.io.TeeOutputStream if you want to accumulate the data on the fly as well.- Specified by:
getVerifyingStreamin interfaceOutputVerifier<T extends Parameters>- Returns:
- an UpdateOutputStream
-
isVerified
public abstract boolean isVerified(byte[] signature) throws InvalidSignatureExceptionDescription copied from interface:OutputVerifierReturn true if the data written to the verifying stream matches the data the signature was calculated against.- Specified by:
isVerifiedin interfaceOutputVerifier<T extends Parameters>- Parameters:
signature- the signature to be confirmed.- Returns:
- true if the data verifies against the signature, false otherwise.
- Throws:
InvalidSignatureException
-
-