public static final class KTSParameterSpec.Builder
extends java.lang.Object
Constructor and Description |
---|
Builder(java.lang.String algorithmName,
int keySizeInBits)
Basic builder.
|
Builder(java.lang.String algorithmName,
int keySizeInBits,
byte[] otherInfo)
Basic builder.
|
Modifier and Type | Method and Description |
---|---|
KTSParameterSpec |
build()
Build the new parameter spec.
|
KTSParameterSpec.Builder |
withKdfAlgorithm(AlgorithmIdentifier kdfAlgorithm)
Set the KDF algorithm and digest algorithm for wrap key generation.
|
KTSParameterSpec.Builder |
withKdfAlgorithm(FipsKDF.AgreementKDFParametersBuilder kdfSource)
Set the KDF algorithm and digest algorithm for wrap key generation.
|
KTSParameterSpec.Builder |
withParameterSpec(java.security.spec.AlgorithmParameterSpec parameterSpec)
Set the algorithm parameter spec to be used with the wrapper.
|
public Builder(java.lang.String algorithmName, int keySizeInBits)
algorithmName
- the algorithm name for the secret key we use for wrapping.keySizeInBits
- the size of the wrapping key we want to produce in bits.public Builder(java.lang.String algorithmName, int keySizeInBits, byte[] otherInfo)
algorithmName
- the algorithm name for the secret key we use for wrapping.keySizeInBits
- the size of the wrapping key we want to produce in bits.otherInfo
- the otherInfo/IV encoding to be applied to the KDF.public KTSParameterSpec.Builder withParameterSpec(java.security.spec.AlgorithmParameterSpec parameterSpec)
parameterSpec
- the algorithm parameter spec to be used in wrapping/unwrapping.public KTSParameterSpec.Builder withKdfAlgorithm(FipsKDF.AgreementKDFParametersBuilder kdfSource)
kdfSource
- the KDF algorithm to apply.public KTSParameterSpec.Builder withKdfAlgorithm(AlgorithmIdentifier kdfAlgorithm)
kdfAlgorithm
- the KDF algorithm to apply.public KTSParameterSpec build()