aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/net/elytrium/limboauth/migration/MigrationHash.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/net/elytrium/limboauth/migration/MigrationHash.java')
-rw-r--r--src/main/java/net/elytrium/limboauth/migration/MigrationHash.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/main/java/net/elytrium/limboauth/migration/MigrationHash.java b/src/main/java/net/elytrium/limboauth/migration/MigrationHash.java
index add41ca..669a82d 100644
--- a/src/main/java/net/elytrium/limboauth/migration/MigrationHash.java
+++ b/src/main/java/net/elytrium/limboauth/migration/MigrationHash.java
@@ -63,6 +63,14 @@ public enum MigrationHash {
MOON_SHA256((hash, password) -> {
String[] arr = hash.split("\\$"); // $SHA$hash
return arr.length == 3 && arr[2].equals(MigrationHash.getDigest(MigrationHash.getDigest(password, "SHA-256"), "SHA-256"));
+ }),
+ SHA256_NO_SALT((hash, password) -> {
+ String[] arr = hash.split("\\$"); // $SHA$hash
+ return arr.length == 3 && arr[2].equals(MigrationHash.getDigest(password, "SHA-256"));
+ }),
+ SHA512_NO_SALT((hash, password) -> {
+ String[] arr = hash.split("\\$"); // $SHA$hash
+ return arr.length == 3 && arr[2].equals(MigrationHash.getDigest(password, "SHA-512"));
});
final MigrationHashVerifier verifier;