Package org.bouncycastle.crypto.fips
Class FipsMACOperatorFactory<T extends AuthenticationParameters>
- java.lang.Object
-
- org.bouncycastle.crypto.fips.FipsMACOperatorFactory<T>
-
- Type Parameters:
T
- the parameters type associated with the final implementation of this factory.
- All Implemented Interfaces:
MACOperatorFactory<T>
- Direct Known Subclasses:
FipsAES.MACOperatorFactory
,FipsSHS.MACOperatorFactory
,FipsTripleDES.MACOperatorFactory
public abstract class FipsMACOperatorFactory<T extends AuthenticationParameters> extends java.lang.Object implements MACOperatorFactory<T>
Base class for the approved mode MACOperatorFactory implementations.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract int
calculateMACSize(T parameters)
protected abstract Mac
createMAC(SymmetricKey key, T parameters)
FipsOutputMACCalculator<T>
createOutputMACCalculator(SymmetricKey key, T parameters)
Create a MAC calculator which provides an OutputStream to write data to.
-
-
-
Method Detail
-
createOutputMACCalculator
public final FipsOutputMACCalculator<T> createOutputMACCalculator(SymmetricKey key, T parameters)
Description copied from interface:MACOperatorFactory
Create a MAC calculator which provides an OutputStream to write data to.- Specified by:
createOutputMACCalculator
in interfaceMACOperatorFactory<T extends AuthenticationParameters>
- Parameters:
key
- the key to use to initialise the MAC.parameters
- any additional parameters.- Returns:
- a MAC calculator.
-
calculateMACSize
protected abstract int calculateMACSize(T parameters)
-
createMAC
protected abstract Mac createMAC(SymmetricKey key, T parameters)
-
-