HomeJavaModsSovietLogin
SovietLogin

Description:
My plugin is made for login onto server, to the work needs sql.



Features:
- Login by ip
- Custom message's
- Hashed password by bCrypt
- Custom join/leave message ("" in config, turns off message)

- Block player, until he log in
- Spawn teleport
- Block fight between 2 players with same ip( default off)
- Sends all player message to the database


Code (Text):

#Database configuration
SQL:
 HOST: "localhost"
 DATABASENAME: "SovietLogin"
 PORT: 3306
 PASSWORD: ""
 USERNAME: "root"
DATABASECONFIG:
 CHARACTER: "utf8"
 COLLATE: "utf8_general_ci"

#Here, you can change plugin message's, remember to reload server or use /sovietreload command
MESSAGE:
 REGISTERFAILD: "&4You can not register!"
 LOGINREPETMESSAGE: "&eWelcome to server! \nUse \\l or \\login to login onto server."
 REGISTERREPEATMESSAGE: "&eWelcome to server! \nUse \\Register <password> <password> to register onto server."
 LOGINSUCCES: "&aLogged successfully!"
 LOGINFAILD: "&4Wrong password!"
 REGISTERSUCCES: "&aRegistered successfully!"
 CHANGEPWDSUCCES: "&aPassword changed successfully!"
 CHANGEPWDFAILD: "&4Wrong current password!"
 PLAYEREXIST: "&4Can not register, player exist!"
 KICKMESSAGE: "&4Log in took too long!"
 PVPSAMEIPMESSAGE: "&4You can not attack player with same IP"
 CMDSBLOCED: "&4You can not use that command, log in!"
 LOGIPASSWORDNNULL: "&4Type your password!"
 REGISTERPASSWORDNULL: "&4Type your password!"
 CHANEGPWDPASSWORDNULL: "&4Type your password <current> <new>"
 MESSAGE_CANCELED_WHILE_LOGIN: "&4You can not sendmessage"
 SPAWNSETUP: "&aSpawn set up!"
 PLAYERLOGGED: "&4You are logged in!"
#%timez% is replaced to teleport left time
 SPAWN_TELEPORT_REPEAT_MESSAGE: "&aLeft,&4%time% &ato teleport! Do not move!"
 SPAWN_TELEPORT_CANCEL: "&4Spawn teleport canceled!"
     
DELAY:      
 WAITFORPLAYERTOLOGIN_IN_SECONDS: 30
 SPAWN_TELEPORT_COUNTDOWN: 10
 REPEAT_OF_LOGINMESSAGE_IN_SECONDS: 1
     
LOGIN:
 LOGIN_WITH_IP: true
 LOGIN_EXPIRE_IN_DAYS: 2
#Set your own join/leave message!      
JOIN_LEAVE_CONFIG:
 SET_CUSTOM_PLAYER_JOIN_MESSAGE: true
#%player% is replaced to player nick
 JOIN_MESSAGE: ""
 SET_CUSTOM_PLAYER_LEAVE_MESSAGE: true
#%player% is replaced to player nick
 LEAVE_MESSAGE: "&e%player% disconnected!"
     
CONFIGURATION:
 PLAYER_IS_UNABLE_TO_MOVE_UNTIL_LOGIN_IN: true
 BLOCK_PVP_FOR_PLAYERS_WITH_SAME_IP: false
 SETSPAWN_COMMAND_ON: true
 SPAWN_COMMAND_ON: true


 
BCrypt example

Code (Text):
<html>
<body>
#For some reason, I can't post it with "scri$pt", delete $ before usage of #this code
<scri$pt sr$c="bCrypt.js"></scr$ipt>

<link href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css" rel="stylesheet" type="text/css"/>
<scr$ipt
src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.3/jquery.min.js" type="text/javascript"></scr$ipt>
<scr$ipt src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></scr$ipt>
<sc$ript type="text/javascript">
    //Link for bCrypt.jar https://codeload.github.com/nevins-b/javascript-bcrypt/zip/master

    var password = "testpassword";
    var hashedpassword = "$2a$12$QeERCU0KHMxqQArvPPbhmOdCREcRvlyw7F/6idlnRs5/hSZfF7r8e"; //Generated in SovietLogin
    function result(newhash){
        if(newhash==true)
        {
            document.write("Password correct");
        }
        else
        {
            document.write("Password incorrect");
        }

    }

checkpw(password,hashedpassword,result, function() {});

   var password_to_hash = "testpasswordfromwebsite";

   function gen(hash)
   {
     document.write(hash);
   }

   hashpw(password_to_hash,gensalt(12),gen,function() {});




</script>
</body>
</html>
Permissions:
-SovietLogin.spawn
-SovietLogin.setspawn
-SovietLogin.reload

Commands:
/login <current password>
/l <current password>
/register <password> <password>
/changepwd <current password> <new password>
/SovietReload (Reloads config)
/spawn (can be turn off)
/setspawn (setsworldspawn,can be turn off)

Discord Link:
https://discordapp.com/invite/kGg8ba7 My Nick: Joseph Hans Goebbels

Commands

Plugin details

Read from the plugin's own plugin.yml.

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

SovietLogin is a free Minecraft Java mod. Compatible with Minecraft 1.13, 1.14. Downloaded 747 times (via Spigot). Download it and open it directly in the game.

Explore more