mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-12-22 16:41:46 +03:00
[FEATURE] Launcher build number
This commit is contained in:
parent
6a057514b2
commit
e0b3f3d6a5
4 changed files with 7 additions and 2 deletions
|
@ -124,7 +124,8 @@ protected void initProps() {
|
|||
properties.put("runtimeconfig.secureCheckSalt", launcherSalt);
|
||||
if (server.runtime.unlockSecret == null) server.runtime.unlockSecret = SecurityHelper.randomStringToken();
|
||||
properties.put("runtimeconfig.unlockSecret", server.runtime.unlockSecret);
|
||||
|
||||
server.runtime.buildNumber++;
|
||||
properties.put("runtimeconfig.buildNumber", server.runtime.buildNumber);
|
||||
}
|
||||
|
||||
public byte[] transformClass(byte[] bytes, String classname, BuildContext context) {
|
||||
|
|
|
@ -11,6 +11,7 @@ public class LaunchServerRuntimeConfig {
|
|||
public String unlockSecret;
|
||||
public String registerApiKey;
|
||||
public String clientCheckSecret;
|
||||
public long buildNumber;
|
||||
|
||||
public void verify() {
|
||||
if (passwordEncryptKey == null) logger.error("[RuntimeConfig] passwordEncryptKey must not be null");
|
||||
|
@ -25,5 +26,6 @@ public void reset() {
|
|||
runtimeEncryptKey = SecurityHelper.randomStringAESKey();
|
||||
registerApiKey = SecurityHelper.randomStringToken();
|
||||
clientCheckSecret = SecurityHelper.randomStringToken();
|
||||
buildNumber = 0;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -48,6 +48,8 @@ public final class LauncherConfig extends StreamObject {
|
|||
public String unlockSecret;
|
||||
@LauncherInject("launchercore.env")
|
||||
public LauncherEnvironment environment;
|
||||
@LauncherInject("runtimeconfig.buildNumber")
|
||||
public long buildNumber;
|
||||
|
||||
|
||||
@LauncherInjectionConstructor
|
||||
|
|
2
modules
2
modules
|
@ -1 +1 @@
|
|||
Subproject commit ed433be234a5d6b4336a6af48194add97b0f2874
|
||||
Subproject commit b9ec7706081097211c4fa9cd7a6669a4dadac6aa
|
Loading…
Reference in a new issue