|
Bouncy Castle Cryptography Library 1.84 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.bouncycastle.pkcs.jcajce.JcePBMac1CalculatorBuilder
A builder for RFC 8018 PBE based MAC calculators.
By default the class uses HMAC-SHA256 as the PRF, with an iteration count of 8192. The default salt length is the output size of the MAC being used.
| Field Summary | |
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA224
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA256
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA3_224
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA3_256
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA3_384
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA3_512
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA384
|
static org.bouncycastle.asn1.x509.AlgorithmIdentifier |
PRF_SHA512
|
| Constructor Summary | |
JcePBMac1CalculatorBuilder(org.bouncycastle.asn1.pkcs.PBMAC1Params pbeMacParams)
Base constructor from an ASN.1 parameter set. |
|
JcePBMac1CalculatorBuilder(java.lang.String macAlgorithm,
int keySize)
Base constructor - MAC name and key size. |
|
JcePBMac1CalculatorBuilder(java.lang.String macAlgorithm,
int keySize,
MacAlgorithmIdentifierFinder algIdFinder)
Base constructor - MAC name and key size with a custom AlgorithmIdentifier finder for the MAC algorithm. |
|
| Method Summary | |
MacCalculator |
build(char[] password)
|
JcePBMac1CalculatorBuilder |
setIterationCount(int iterationCount)
|
JcePBMac1CalculatorBuilder |
setPrf(org.bouncycastle.asn1.x509.AlgorithmIdentifier prf)
|
JcePBMac1CalculatorBuilder |
setProvider(java.security.Provider provider)
|
JcePBMac1CalculatorBuilder |
setProvider(java.lang.String providerName)
|
JcePBMac1CalculatorBuilder |
setRandom(java.security.SecureRandom random)
|
JcePBMac1CalculatorBuilder |
setSalt(byte[] salt)
|
JcePBMac1CalculatorBuilder |
setSaltLength(int saltLength)
Set the length of the salt in bytes. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA224
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA256
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA384
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA512
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA3_224
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA3_256
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA3_384
public static final org.bouncycastle.asn1.x509.AlgorithmIdentifier PRF_SHA3_512
| Constructor Detail |
public JcePBMac1CalculatorBuilder(java.lang.String macAlgorithm,
int keySize)
macAlgorithm - name of the MAC algorithm.keySize - the key size in bits.
public JcePBMac1CalculatorBuilder(java.lang.String macAlgorithm,
int keySize,
MacAlgorithmIdentifierFinder algIdFinder)
macAlgorithm - name of the MAC algorithm.keySize - the key size in bits.algIdFinder - an AlgorithmIdentifier finder containing the specified MAC name.public JcePBMac1CalculatorBuilder(org.bouncycastle.asn1.pkcs.PBMAC1Params pbeMacParams)
pbeMacParams - the ASN.1 parameters for the MAC calculator we want to create.| Method Detail |
public JcePBMac1CalculatorBuilder setProvider(java.security.Provider provider)
public JcePBMac1CalculatorBuilder setProvider(java.lang.String providerName)
public JcePBMac1CalculatorBuilder setIterationCount(int iterationCount)
public JcePBMac1CalculatorBuilder setSaltLength(int saltLength)
saltLength -
public JcePBMac1CalculatorBuilder setSalt(byte[] salt)
public JcePBMac1CalculatorBuilder setRandom(java.security.SecureRandom random)
public JcePBMac1CalculatorBuilder setPrf(org.bouncycastle.asn1.x509.AlgorithmIdentifier prf)
public MacCalculator build(char[] password)
throws OperatorCreationException
OperatorCreationException
|
Bouncy Castle Cryptography Library 1.84 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||