#494 Fix conversion plaintext to SHA256
- Make sure database is set up before attempting to perform the migration
This commit is contained in:
@@ -113,7 +113,7 @@ public class PasswordSecurity {
|
||||
*/
|
||||
private static EncryptionMethod initializeEncryptionMethodWithoutEvent(HashAlgorithm algorithm) {
|
||||
try {
|
||||
return HashAlgorithm.CUSTOM.equals(algorithm)
|
||||
return HashAlgorithm.CUSTOM.equals(algorithm) || HashAlgorithm.PLAINTEXT.equals(algorithm)
|
||||
? null
|
||||
: algorithm.getClazz().newInstance();
|
||||
} catch (InstantiationException | IllegalAccessException e) {
|
||||
|
||||
@@ -11,7 +11,7 @@ import fr.xephi.authme.security.crypts.description.Usage;
|
||||
* and store the salt with the hash itself.
|
||||
*/
|
||||
@Recommendation(Usage.ACCEPTABLE)
|
||||
@HasSalt(SaltType.TEXT) // See saltLength() for length
|
||||
@HasSalt(SaltType.TEXT) // See getSaltLength() for length
|
||||
public abstract class HexSaltedMethod implements EncryptionMethod {
|
||||
|
||||
public abstract int getSaltLength();
|
||||
|
||||
Reference in New Issue
Block a user