Added password authentication as server feature (#8716)

* Added authenticate and setPassword

* Added AuthPopup

* Added auth endpoint to UncivServer

* Fixed merge confict

* Added close button to AuthPopup

+ Fixed crash if no server is available

* Added entries to template properties

* Fixed setting password does not work

if authentication is required

+ Added server check on game startup in case the server has changed its feature set

* Added support for different passwords

on different servers

+ Cleanup for MultiplayerTab

* Added current password as hint

+ removed character hiding in auth popup
+ added popup to indicate auth success on connection check
This commit is contained in:
Leonard Günther
2023-02-25 19:42:36 +01:00
committed by GitHub
parent 5d80f50d93
commit a3f511efd2
16 changed files with 527 additions and 56 deletions

View File

@ -78,7 +78,7 @@ The simple multiplayer host included in the sources can be set up to debug or ru
- In Android Studio, Run > Edit configurations.
- Click "+" to add a new configuration
- Choose "Application" and name the config, e.g. "UncivServer"
- Set the module to `Unciv.server.main` (`Unciv.server` for Studio versions Bumblebee or below), main class to `com.unciv.app.server.DesktopLauncher` and `<repo_folder>/android/assets/` as the Working directory, OK to close the window.
- Set the module to `Unciv.server.main` (`Unciv.server` for Studio versions Bumblebee or below), main class to `com.unciv.app.server.UncivServer` and `<repo_folder>/android/assets/` as the Working directory, OK to close the window.
- Select the UncivServer configuration and click the green arrow button to run! Or start a debug session as above.
To build a jar file, refer to [Without Android Studio](#Without-Android-Studio) and replace 'desktop' with 'server'. That is, run `./gradlew server:dist` and when it's done look for /server/build/libs/UncivServer.jar