From 0c5227b5abcf2bdd8e440bb6c69721ad8a0d9553 Mon Sep 17 00:00:00 2001 From: Gravit Date: Sat, 23 Mar 2019 10:34:46 +0700 Subject: [PATCH] =?UTF-8?q?[FIX]=20=D0=A5=D1=83=D0=BA=D0=B8=20=D0=B0=D0=B2?= =?UTF-8?q?=D1=82=D0=BE=D1=80=D0=B8=D0=B7=D0=B0=D1=86=D0=B8=D0=B8=20=D1=80?= =?UTF-8?q?=D0=B0=D1=81=D0=BF=D1=80=D0=BE=D1=81=D1=82=D1=80=D0=B0=D0=BD?= =?UTF-8?q?=D1=8F=D1=8E=D1=82=D1=81=D1=8F=20=D0=B8=20=D0=BD=D0=B0=20=D1=81?= =?UTF-8?q?=D0=B5=D1=80=D0=B2=D0=B5=D1=80=D0=BD=D1=83=D1=8E=20=D0=B0=D0=B2?= =?UTF-8?q?=D1=82=D0=BE=D1=80=D0=B8=D0=B7=D0=B0=D1=86=D0=B8=D1=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../gravit/launchserver/response/auth/AuthServerResponse.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/LaunchServer/src/main/java/ru/gravit/launchserver/response/auth/AuthServerResponse.java b/LaunchServer/src/main/java/ru/gravit/launchserver/response/auth/AuthServerResponse.java index 48fd0332..52551c15 100644 --- a/LaunchServer/src/main/java/ru/gravit/launchserver/response/auth/AuthServerResponse.java +++ b/LaunchServer/src/main/java/ru/gravit/launchserver/response/auth/AuthServerResponse.java @@ -56,7 +56,9 @@ public void reply() throws Exception { else pair = server.config.getAuthProviderPair(auth_id); if(pair == null) requestError("Auth type not found"); AuthProvider provider = pair.provider; + AuthResponse.AuthContext context = new AuthResponse.AuthContext(session, login, password.length(), null, client, null, ip, true); try { + server.authHookManager.preHook(context, clientData); result = provider.auth(login, password, ip); if (!VerifyHelper.isValidUsername(result.username)) { AuthProvider.authError(String.format("Illegal result: '%s'", result.username)); @@ -77,6 +79,7 @@ public void reply() throws Exception { } clientData.type = Client.Type.SERVER; clientData.username = result.username; + server.authHookManager.postHook(context, clientData); } catch (AuthException | HWIDException e) { requestError(e.getMessage()); return;