Minor - rename EncryptedPassword to HashedPassword

- We hash passwords; we don't encrypt them
This commit is contained in:
ljacqu
2015-12-30 22:51:59 +01:00
parent e85dbe81e5
commit c0a393b8b3
41 changed files with 175 additions and 175 deletions
+3 -3
View File
@@ -4,7 +4,7 @@ import fr.xephi.authme.AuthMe;
import fr.xephi.authme.cache.auth.PlayerAuth;
import fr.xephi.authme.cache.auth.PlayerCache;
import fr.xephi.authme.security.PasswordSecurity;
import fr.xephi.authme.security.crypts.EncryptedPassword;
import fr.xephi.authme.security.crypts.HashedPassword;
import fr.xephi.authme.util.Utils;
import org.bukkit.Bukkit;
import org.bukkit.Location;
@@ -134,13 +134,13 @@ public class API {
@Deprecated
public static boolean registerPlayer(String playerName, String password) {
String name = playerName.toLowerCase();
EncryptedPassword encryptedPassword = passwordSecurity.computeHash(password, name);
HashedPassword hashedPassword = passwordSecurity.computeHash(password, name);
if (isRegistered(name)) {
return false;
}
PlayerAuth auth = PlayerAuth.builder()
.name(name)
.password(encryptedPassword)
.password(hashedPassword)
.lastLogin(0)
.realName(playerName)
.build();
@@ -3,7 +3,7 @@ package fr.xephi.authme.api;
import fr.xephi.authme.AuthMe;
import fr.xephi.authme.cache.auth.PlayerAuth;
import fr.xephi.authme.cache.auth.PlayerCache;
import fr.xephi.authme.security.crypts.EncryptedPassword;
import fr.xephi.authme.security.crypts.HashedPassword;
import fr.xephi.authme.util.Utils;
import org.bukkit.Bukkit;
import org.bukkit.Location;
@@ -149,7 +149,7 @@ public class NewAPI {
*/
public boolean registerPlayer(String playerName, String password) {
String name = playerName.toLowerCase();
EncryptedPassword result = plugin.getPasswordSecurity().computeHash(password, name);
HashedPassword result = plugin.getPasswordSecurity().computeHash(password, name);
if (isRegistered(name)) {
return false;
}