public interface BSDUnixDESCryptPassword extends OneWayPassword
Modifier and Type | Field and Description |
---|---|
static String |
ALGORITHM_BSD_CRYPT_DES
The algorithm name.
|
static int |
BSD_CRYPT_DES_HASH_SIZE
The constant size of the hash, in bytes.
|
static int |
BSD_CRYPT_DES_SALT_SIZE
The constant size of the salt, in bytes.
|
static int |
DEFAULT_ITERATION_COUNT
The default iteration count.
|
serialVersionUID
Modifier and Type | Method and Description |
---|---|
BSDUnixDESCryptPassword |
clone()
Creates and returns a copy of this
Password . |
static BSDUnixDESCryptPassword |
createRaw(String algorithm,
byte[] hash,
int salt,
int iterationCount)
Create a raw implementation of this password type.
|
byte[] |
getHash()
Get the hash segment of this password.
|
int |
getIterationCount()
Get the iteration count of this password.
|
default IteratedSaltedPasswordAlgorithmSpec |
getParameterSpec()
Get the applicable algorithm parameter specification for this password type.
|
int |
getSalt()
Get the salt segment of this password as an
int value. |
default boolean |
impliesParameters(AlgorithmParameterSpec parameterSpec)
Determine if this password is matched by the given parameter specification.
|
castAndApply, castAndApply, castAs, castAs
getAlgorithm, getEncoded, getFormat
static final String ALGORITHM_BSD_CRYPT_DES
static final int BSD_CRYPT_DES_HASH_SIZE
static final int BSD_CRYPT_DES_SALT_SIZE
static final int DEFAULT_ITERATION_COUNT
int getIterationCount()
int getSalt()
int
value.byte[] getHash()
default IteratedSaltedPasswordAlgorithmSpec getParameterSpec()
Password
getParameterSpec
in interface Password
null
if this password type does not support algorithmsdefault boolean impliesParameters(AlgorithmParameterSpec parameterSpec)
Password
impliesParameters
in interface Password
parameterSpec
- the parameter specification (must not be null
)true
if the password is matched by the parameters, false
otherwiseBSDUnixDESCryptPassword clone()
Password
.clone
in interface OneWayPassword
clone
in interface Password
Password
.static BSDUnixDESCryptPassword createRaw(String algorithm, byte[] hash, int salt, int iterationCount)
PasswordFactory
(via the PasswordFactory.translate(Password)
method)
before it can be validated and used to verify guesses.algorithm
- the algorithm namehash
- the hashsalt
- the saltiterationCount
- the iteration countCopyright © 2020 JBoss by Red Hat. All rights reserved.