Authentification plugin - Printable Version +- Cuberite Forum (https://forum.cuberite.org) +-- Forum: Plugins (https://forum.cuberite.org/forum-1.html) +--- Forum: Plugin Requests (https://forum.cuberite.org/forum-3.html) +--- Thread: Authentification plugin (/thread-16.html) Pages:
1
2
|
Authentification plugin - Mastermind - 02-25-2011 Hi everybody , is it possible to make a plugin who player can use a password to stay connected with his Nickname ? ( possibly not in mysql :p plz ) RE: Authentification plugin - Jockie - 02-25-2011 Nope, because it's not possible to kick a player.. yet. oO RE: Authentification plugin - Mastermind - 02-25-2011 (02-25-2011, 06:05 AM)Jockie Wrote: Nope, because it's not possible to kick a player.. yet. oO /kick command dosen't work ? ok but you can make an authentification system . RE: Authentification plugin - Jockie - 02-26-2011 Well, I can, but it's not possible to disallow a player that connects.. yet.. (I hope) Player:BanPlayer/Player:KickPlayer should be installed. :p EDIT: Btw.. If you want it non-MySQL, it would be usefull to install a word compiler, like MD5, else you could see everyone's pass. LUA doesn't normally have MD5 installed. But you should also need then a XML parser... For saving on a save way. :/ RE: Authentification plugin - FakeTruth - 02-26-2011 (02-26-2011, 12:17 AM)Jockie Wrote: Well, I can, but it's not possible to disallow a player that connects.. yet.. (I hope)Yes it is Use the E_PLUGIN_LOGIN hook and the OnLogin( cPacket_Login ) function. Return true to kick the player. (02-26-2011, 12:17 AM)Jockie Wrote: Player:BanPlayer/Player:KickPlayer should be installed. :pYes it should, lol. Better make this my top priority then. (02-26-2011, 12:17 AM)Jockie Wrote: EDIT: Btw.. If you want it non-MySQL, it would be usefull to install a word compiler, like MD5, else you could see everyone's pass.I already have a md5 hasher for MCServer, just not exposed to Lua yet. I don't see why you'd need an XML parser though, you could use the ini files. RE: Authentification plugin - Jockie - 02-26-2011 Hm.. So it would look like this by then? oO Code: [1] Also possible. :p RE: Authentification plugin - Tybor - 02-27-2011 (02-26-2011, 09:27 PM)Jockie Wrote: Hm.. So it would look like this by then? oOYou even can access the user.ini from MCServer and add a password by plugin. This way all user information will be stored at same place, which makes administration easier. greets, Tybor RE: Authentification plugin - FakeTruth - 02-27-2011 What Tybor suggests sounds like the smartest thing to do If you want to use a seperate file, I'd suggest something like this: Code: [AuthenticationPlugin] RE: Authentification plugin - Tim - 03-01-2011 (02-26-2011, 09:59 AM)FakeTruth Wrote:(02-26-2011, 12:17 AM)Jockie Wrote: Well, I can, but it's not possible to disallow a player that connects.. yet.. (I hope)Yes it is Is that sort of like 'cancelling' the event? If so, does that cancel other events too? RE: Authentification plugin - FakeTruth - 03-02-2011 On most (if not all, I think it's all) plugin callbacks you return false to let MCServer do its normal business like nothing ever happened. When you return true you will override default behavior or modify it. When you return true in the OnLogin function MCServer will simply close the connection with the player. |