Adapt PR#964 breaking changes

This commit is contained in:
xtaodada 2022-05-17 21:12:34 +08:00
parent 5508233001
commit ffeac48b73
Signed by: xtaodada
GPG Key ID: 4CBB3F4FA8C85659
2 changed files with 4 additions and 3 deletions

View File

@ -1,6 +1,7 @@
package me.exzork.gcauth.handler;
import emu.grasscutter.auth.*;
import emu.grasscutter.game.Account;
import emu.grasscutter.server.http.objects.ComboTokenResJson;
import emu.grasscutter.server.http.objects.LoginResultJson;
@ -21,8 +22,8 @@ public class GCAuthAuthenticationHandler implements AuthenticationSystem {
}
@Override
public boolean verifyUser(String s) {
return false;
public Account verifyUser(String s) {
return null;
}
@Override

View File

@ -11,7 +11,7 @@ import org.springframework.security.crypto.scrypt.SCryptPasswordEncoder;
import java.util.HashMap;
public final class Authentication {
public static final HashMap<String,String> tokens = new HashMap<String,String>();
public static final HashMap<String,String> tokens = new HashMap<>();
private static Algorithm key = Algorithm.HMAC256(generateRandomString(32));
public static Algorithm getKey() {
return key;