Class OneStepKDFParameterSpec
java.lang.Object
org.bouncycastle.jcajce.spec.OneStepKDFParameterSpec
- All Implemented Interfaces:
AlgorithmParameterSpec
Derivation parameters for the NIST SP 800-56C Rev. 2 Section 4.1 one-step key derivation function
(
KDF.getInstance("ONESTEP-SHA256"), "ONESTEP-HMACSHA256", "ONESTEP-KMAC128", ...): the shared
secret Z, the FixedInfo, the output length, and for the HMAC and KMAC options an optional salt.-
Constructor Summary
ConstructorsConstructorDescriptionOneStepKDFParameterSpec(byte[] z, byte[] salt, byte[] fixedInfo, int outputLength) OneStepKDFParameterSpec(byte[] z, byte[] fixedInfo, int outputLength) Hash option, or HMAC/KMAC with the standard's default salt. -
Method Summary
-
Constructor Details
-
OneStepKDFParameterSpec
public OneStepKDFParameterSpec(byte[] z, byte[] fixedInfo, int outputLength) Hash option, or HMAC/KMAC with the standard's default salt.- Parameters:
z- the shared secret.fixedInfo- the FixedInfo, may be null.outputLength- the number of bytes to derive.
-
OneStepKDFParameterSpec
public OneStepKDFParameterSpec(byte[] z, byte[] salt, byte[] fixedInfo, int outputLength) - Parameters:
z- the shared secret.salt- the salt keying HMAC or KMAC, or null for the standard's default salt; ignored by the hash option.fixedInfo- the FixedInfo, may be null.outputLength- the number of bytes to derive.
-
-
Method Details
-
getZ
public byte[] getZ() -
getSalt
public byte[] getSalt()- Returns:
- the salt, or null for the default salt.
-
getFixedInfo
public byte[] getFixedInfo() -
getOutputLength
public int getOutputLength()
-