Mods / Server Authentication

Tags: #Utility
Author: BoboDev
Side: Server
Created: Apr 6th 2024 at 11:16 PM
Last modified: Feb 16th at 12:13 AM
Downloads: 881
Follow Unfollow 15

Latest release (for outdated Vintage Story v1.20.0 - v1.20.4):
serverauth_1.0.9.zip  1-click install


Server Auth

Increase the security for your server by adding a new account register and login on player connections, totally server side,

Version to choose

Game Version Mod Version
1.x.x RSA Encryption (Both)
1.x.x-rc Simple (Server Only)

warning

In the last version the configuration uidAuthentication is removed, if this is used as false in previous versions, updating the mod will make all players need to register again!!

Features:

  • Register account system ex: /register 123
  • Login account system ex: /login 123
  • Change password system ex: /changepassword 321
  • Admin change password system ex: /forcechangepassword test 321
  • Configuration files
  • RSA Encryption for passwords
  • Passwords saved is hashed using SHA256

Player unlogged cannot:

  • Drop items
  • Execute commands
  • Break blocks
  • Get dropped items
  • Use inventory
  • Deal damage
  • Receive damage
  • Lose saturation
  • Move

Observations

Players not registered will not count as unlogged player. (Configurable)

Players has 20 seconds to login, if player not logged will be automatically disconnected from the server. (Configurable)

Too many wrongs password will kick user and ban for some seconds. (Configurable)

Entering too many times in server and not logging will ban the user for some seconds. (Configurable)

When a player enters in the server all the inventory is saved locally and the player inventory is clear, so the unlogged players will not have access to the inventory, when the player successfully login in, the inventory is restored.

Unfurtunally you can view the players passwords in servers log if you have acess to it, this is because the native code logs all commands from players, you know how to disable it? feel free to pull request.

The players password is saved based in the player UID (you can force to use player name instead but this is UNSECURE), if the player changes the name the password for login will be the same.

Changing authentication to uid and player name will cause incosistences with players needing register again, be carefull changing it in mid game

Considerations

This mod change a lot of native code, and can break easily throught updates, please make a backup in your world before adding it.

Performance can be a impacted on the server, because of authentication verification.

To much unlogged players can cause performances leaks because of forcing stop moviment.

About Server Auth

Server Auth is open source project and can easily be accessed on the github, all contents from this mod is completly free.

If you want to contribute into the project you can access the project github and make your pull request.

You are free to fork the project and make your own version of Server Auth, as long the name is changed

Version For Game version Downloads Release date Changelog Download 1-click mod install*
v1.0.9 139 Feb 16th at 12:13 AM Show serverauth_1.0.9.zip 1-click install
v1.0.9-rc.1 28 Feb 16th at 12:13 AM Show serverauth_1.0.9-rc.1.zip 1-click install
v1.0.8
66 Jan 6th at 10:20 AM Show serverauth_1.0.8.zip
v1.0.7
39 Jan 6th at 2:07 AM Show serverauth_1.0.7.zip
v1.0.6
162 Apr 27th 2024 at 4:25 PM Show serverauth_1.0.6.zip
v1.0.5
117 Apr 15th 2024 at 1:01 PM Show serverauth_1.0.5.zip
v1.0.4
115 Apr 9th 2024 at 11:33 AM Show serverauth_1.0.4.zip
v1.0.3
116 Apr 9th 2024 at 12:58 AM Show serverauth_1.0.3.zip
v1.0.2
99 Apr 6th 2024 at 11:19 PM Show serverauth.zip

18 Comments (oldest first | newest first)

💬 Nicolayka, Apr 22nd at 9:12 PM

When you log on to the server for the first time, the character selection window does not allow you to register on the server - the chat does not open. You can't open a chat or create a character. Is there anything we can do about it?

💬 Nicolayka, Apr 17th at 2:39 PM

@BoboDev Thanks! It's working! 😘😍

💬 BoboDev , Apr 17th at 12:39 AM

Nicolayka Yes, you need to change the "freezeNonRegisteredPlayer" to true in ModConfig

💬 Nicolayka, Apr 16th at 9:22 AM

When logging into the server, the mod does not offer to register! What should I do? I did not find the configuration file.....

____

При входе на сервер, мод не предлагает зарегистрироваться! Как быть? Конфигурационный файл не нашёл.....

💬 WickedSchnitzel, Feb 16th at 9:57 AM

Maybe you could add a country ip blacklist/ whitelist.

💬 BoboDev , Feb 2nd at 1:30 PM

Soggylithe Yeah, true i should make that in the future

💬 Soggylithe, Jan 22nd at 11:10 PM

Neat mod, I like the idea

"Unfurtunally you can view the players password in servers log"

I think you could use a client side command (eg. .login 123) and hash the password before sending the login message to the server though it would have to be a 'Both' mod then.

💬 BoboDev , Jan 6th at 2:07 AM

MurlokReal Fixed

💬 MurlokReal, Jan 5th at 12:20 PM
If a player dies, he can leave the server, log in again, log in and find himself at the place of his death, and not at the place of rebirth!
💬 BoboDev , Apr 27th 2024 at 4:26 PM

Lumvik Fixed

💬 Lumvik, Apr 26th 2024 at 11:04 PM

Hi, Bobo!
When the setting to freeze unregistered players is turned on, a new player appears outside the world.
As far as I can tell, the mod keeps their inventory until they choose a class and create a character in the game.
The player creates a Seraph, but after registering, the Seraph immediately dies and loses their clothes.

💬 The_True_Goo, Apr 23rd 2024 at 7:18 PM

@bobodev server website didn't save the fact that I deleted it ^^" I was paniced for a second. 

 

💬 BoboDev , Apr 22nd 2024 at 11:18 PM

The_True_Goo Just remove it from the mods folder, its not possible the mod run without files

💬 The_True_Goo, Apr 22nd 2024 at 5:17 PM

help... how do I remove this from my server? I deleted the file. but tt's still being picked up

 

💬 Lumvik, Apr 14th 2024 at 8:42 PM

BoboDev
Sounds great. Good luck with the development and have a great day!

💬 BoboDev , Apr 14th 2024 at 7:50 PM

MATVII
At the moment this mod still doesn't have a config file, i intend to do it this week, and about the player not getting stuck when they don't have an account yet, it's something normal because the player doesn't have an account to block the moviment and inventory, but i understand that some people might want this option and i also have it in mind for this week

💬 Lumvik, Apr 14th 2024 at 11:37 AM

Hi BoboDev! Сould you tell me if it's possible to increase the player's waiting time for authorization? Perhaps up to 60 seconds.

I would like to translate the chat messages displayed to the language of my server. Are you planning to add support for other languages in your mod?

Additionally, I noticed that the mod does not freeze players who have not yet created a password. Is that supposed to happen? After creating a password, the mod works correctly.

💬 Ruyeex, Apr 8th 2024 at 7:27 AM

It could be great for the same reason as minecraft has.
But currently it's not the most concerning, but it's neat.

 (edit comment delete)