This build adds a killswitch for the 5th, this can be enabled and disabled at will, when enabled it fully blocks login requests from the game, which prevents it's usage. The client will display "Login Failed" due to it being supplied with a fake "Malformed Request" error that is a way to prevent any further attempts.

This commit is contained in:
James Quinley 2022-09-02 19:15:01 -07:00
parent 8316f789c7
commit b097009fd3
2 changed files with 148 additions and 124 deletions

View File

@ -29,6 +29,7 @@ public class delegationServices {
static MongoCollection<Document> RGFilter; static MongoCollection<Document> RGFilter;
public static void connectionInit (Boolean beta) public static void connectionInit (Boolean beta)
{ {
//TODO Send Server Version As Standard.
if (beta == true) if (beta == true)
{ {
scReadconnectionString = new ConnectionString("mongodb+srv://serverClientBeta:Unz6c3I0wjrUVBIf@delegationrequest.qnvfa.mongodb.net/mDelegationRequest?retryWrites=true&w=majority"); scReadconnectionString = new ConnectionString("mongodb+srv://serverClientBeta:Unz6c3I0wjrUVBIf@delegationrequest.qnvfa.mongodb.net/mDelegationRequest?retryWrites=true&w=majority");
@ -913,6 +914,9 @@ public class delegationServices {
} }
} }
if (requesttype == 18) { if (requesttype == 18) {
if ((Boolean)Filter.get("gameActive") == true)
{
//Deprecated, a killswitch has been added under rgcon in the field "gameActive"
//TOKEN LOGIN FOR GAME, DOES NOT SEND EMAIL, LAUNCHER WILL NOT USE THIS. //TOKEN LOGIN FOR GAME, DOES NOT SEND EMAIL, LAUNCHER WILL NOT USE THIS.
System.out.println("Game Login"); System.out.println("Game Login");
int CTOKEN = (int) Lrequest.get("Token"); int CTOKEN = (int) Lrequest.get("Token");
@ -1044,6 +1048,25 @@ public class delegationServices {
//delegationTimer.trigger(); //delegationTimer.trigger();
} }
} }
else
{
System.out.println("Login rejected, game client EOS has been reached.");
BasicDBObject searchQuery = new BasicDBObject();
searchQuery.append("clientid", ClientID);
BasicDBObject updateQuery = new BasicDBObject();
BasicDBObject updateQuery1 = new BasicDBObject();
updateQuery.append("$set",
new BasicDBObject().append("type", 7));
updateQuery1.append("$set",
new BasicDBObject().append("status", true));
dCollection.updateOne(searchQuery, updateQuery);
dCollection.updateOne(searchQuery, updateQuery1);
//delegationTimer.trigger();
delegationTimer.DeleteTargetRequest(ClientID);
}
}
if (requesttype == 10) { if (requesttype == 10) {
System.out.println("Account Creation Request"); System.out.println("Account Creation Request");
Document DServer = dCollection.find(eq("clientid", ClientID)).first(); Document DServer = dCollection.find(eq("clientid", ClientID)).first();

View File

@ -2,5 +2,6 @@ package com.jamesquinley.DelegationServices;
public class status { public class status {
public static boolean betaServer = false; public static boolean betaServer = false;
public static String serverVersion = "1.1";
//Beta server has been discontinued, the database that the server depended on has been shut down. //Beta server has been discontinued, the database that the server depended on has been shut down.
} }