diff --git a/.gitignore b/.gitignore index 785144dc2..0d5a6375e 100644 --- a/.gitignore +++ b/.gitignore @@ -74,5 +74,6 @@ config.json hotfix.json *.mv *.exe +*.p12 BuildConfig.java Test.java \ No newline at end of file diff --git a/README.md b/README.md index 4aab7048a..317a1b178 100644 --- a/README.md +++ b/README.md @@ -38,8 +38,7 @@ ### Connecting with the client (Fiddler method) 1. **Log in with the client to an official server and Hoyoverse account at least once to download game data.** 2. Install and have [Fiddler Classic](https://www.telerik.com/fiddler) running. -3. Set fiddler to decrypt https traffic. (Tools -> Options -> HTTPS -> Decrypt HTTPS traffic) Make sure `ignore server certificate errors` is checked as well. -4. Copy and paste the following code into the Fiddlerscript tab of Fiddler Classic: +3. Copy and paste the following code into the Fiddlerscript tab of Fiddler Classic. Remember to save the fiddler script after you copy and paste it: ``` import System; @@ -51,14 +50,15 @@ class Handlers { static function OnBeforeRequest(oS: Session) { if (oS.host.EndsWith(".starrails.com") || oS.host.EndsWith(".hoyoverse.com") || oS.host.EndsWith(".mihoyo.com") || oS.host.EndsWith(".bhsr.com")) { + oS.oRequest.headers.UriScheme = "http"; oS.host = "localhost"; // This can also be replaced with another IP address. } } }; ``` -5. If `autoCreateAccount` is set to true in the config, then you can skip this step. Otherwise, type `/account create [account name]` in the server console to create an account. -6. Login with your account name, the password field is ignored by the server and can be set to anything. +4. If `autoCreateAccount` is set to true in the config, then you can skip this step. Otherwise, type `/account create [account name]` in the server console to create an account. +5. Login with your account name, the password field is ignored by the server and can be set to anything. ### Server commands Server commands can be run in the server console or in-game. There is a dummy user named "Server" in every player's friends list that you can message to use in-game commands. diff --git a/keystore.p12 b/keystore.p12 deleted file mode 100644 index 063766340..000000000 Binary files a/keystore.p12 and /dev/null differ diff --git a/src/main/java/emu/lunarcore/Config.java b/src/main/java/emu/lunarcore/Config.java index 448e454b4..3563b9e3c 100644 --- a/src/main/java/emu/lunarcore/Config.java +++ b/src/main/java/emu/lunarcore/Config.java @@ -18,7 +18,7 @@ public class Config { public KeystoreInfo keystore = new KeystoreInfo(); - public HttpServerConfig httpServer = new HttpServerConfig(443); + public HttpServerConfig httpServer = new HttpServerConfig(80); public GameServerConfig gameServer = new GameServerConfig(23301); public ServerOptions serverOptions = new ServerOptions(); @@ -46,7 +46,7 @@ public static class InternalMongoInfo { @Getter public static class KeystoreInfo { public String path = "./keystore.p12"; - public String password = "lunar"; + public String password = ""; } @Getter @@ -83,7 +83,7 @@ public int getPublicPort() { @Getter public static class HttpServerConfig extends ServerConfig { - public boolean useSSL = true; + public boolean useSSL = false; public long regionListRefresh = 60_000; // Time in milliseconds to wait before refreshing region list cache again public HttpServerConfig(int port) {