Package org.bouncycastle.crypto.fips
Class FipsKDF.CounterModeParametersBuilder
- java.lang.Object
-
- org.bouncycastle.crypto.fips.FipsParameters
-
- org.bouncycastle.crypto.fips.FipsKDF.CounterModeParametersBuilder
-
- All Implemented Interfaces:
Parameters
- Enclosing class:
- FipsKDF
public static final class FipsKDF.CounterModeParametersBuilder extends FipsParameters
Parameters for the Counter Mode parameters builder.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FipsKDF.CounterModeParametersusing(byte[] ki, boolean isPrefix, byte[] label, byte[] context, int L)Build method for parameters which builds fixed input as outlined in SP 800-108 with the fixed input as a prefix, or suffix, to the counter.FipsKDF.CounterModeParametersusing(byte[] ki, byte[] fixedInputPrefix)Return a new parameter set for ki and a prefix.FipsKDF.CounterModeParametersusing(byte[] ki, byte[] fixedInputPrefix, byte[] fixedInputSuffix)Return a new parameter set for ki and the prefix/suffix data.FipsKDF.CounterModeParametersBuilderwithPRFAndR(FipsKDF.PRF prf, int r)Return a new parameters builder based around the passed in PRF and counter size.-
Methods inherited from class org.bouncycastle.crypto.fips.FipsParameters
getAlgorithm
-
-
-
-
Method Detail
-
withPRFAndR
public FipsKDF.CounterModeParametersBuilder withPRFAndR(FipsKDF.PRF prf, int r)
Return a new parameters builder based around the passed in PRF and counter size.- Parameters:
prf- the PRF to be used in the final KDF.r- the length in bits of the counter to be used.- Returns:
- a new parameters builder.
-
using
public FipsKDF.CounterModeParameters using(byte[] ki, byte[] fixedInputPrefix)
Return a new parameter set for ki and a prefix.- Parameters:
ki- derivation key for the KDF.fixedInputPrefix- prefix data to come before the counter during calculation.- Returns:
- a CounterModeParameters object.
-
using
public FipsKDF.CounterModeParameters using(byte[] ki, byte[] fixedInputPrefix, byte[] fixedInputSuffix)
Return a new parameter set for ki and the prefix/suffix data.- Parameters:
ki- derivation key for the KDF.fixedInputPrefix- prefix data to come before the counter during calculation.fixedInputSuffix- suffix data to come after the counter during calculation.- Returns:
- a CounterModeParameters object.
-
using
public FipsKDF.CounterModeParameters using(byte[] ki, boolean isPrefix, byte[] label, byte[] context, int L)
Build method for parameters which builds fixed input as outlined in SP 800-108 with the fixed input as a prefix, or suffix, to the counter.- Parameters:
ki- input key.isPrefix- is the fixed input a prefix or a suffix.label- label - fixed input component.context- context - fixed input component.L- number of bits per request for the KDF these parameters will initialise - fixed input component.- Returns:
- a CounterModeParameters object.
-
-