mirror of
https://e.coding.net/circlecloud/AuthMe.git
synced 2025-11-26 21:46:23 +00:00
17
src/main/java/fr/xephi/authme/security/crypts/WBB4.java
Normal file
17
src/main/java/fr/xephi/authme/security/crypts/WBB4.java
Normal file
@@ -0,0 +1,17 @@
|
||||
package fr.xephi.authme.security.crypts;
|
||||
|
||||
import java.security.NoSuchAlgorithmException;
|
||||
|
||||
public class WBB4 implements EncryptionMethod {
|
||||
|
||||
@Override
|
||||
public boolean comparePassword(String hash, String password, String playerName) throws NoSuchAlgorithmException {
|
||||
return BCRYPT.checkpw(password, hash, 2);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getHash(String password, String salt, String name) throws NoSuchAlgorithmException {
|
||||
return BCRYPT.getDoubleHash(password, salt);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user