Author Topic: AdminOnly - For when using a password is just a hassle [1.2.3]  (Read 5990 times)

AdminOnly
Written By: Matthew Padilla

Suggestions go in my email, matthew.p@k.st

Versions:
  • 0.9 - Originally coded on 5/21/13
  • 1.0 - First release 5/22/13
  • 1.1 - 5/22/13
  • 1.2 - 5/23/13 Added support for Moderators
  • 1.2.1 - 5/24/13
  • 1.2.2 - 5/25/13
  • 1.2.3 - 5/26/13

Bug Fixes:
  • 0.9 - Made the autoAdminCheck function inoperable.
  • 1.0 - Function is fixed by Zeblote
  • 1.1 - Removed package on ActivateAO();
  • 1.2 - No bugs
  • 1.2.1 - Removed Tezuni's script inside of AdminOnly, made autocheck
  • 1.2.2 - Added RTB Prefs, 1 is ON 2 is OFF
  • 1.2.3 - Fixed RTB prefs added MessageBox

Commands:
  • /AdminOnlyactivate - Turns AdminOnly on and off
  • RTB Pref - 1 is ON 2 is OFF

Description:
  • This is used when having a password is just too much of a hassle. All of your admins can now join without having to enter that pesky password every single time! Anyone that is not an admin and tries to connect will be kicked. Also supports Tezunis' Moderator script.

« Last Edit: January 14, 2014, 10:23:21 PM by Matthew Padilla »


actually pretty useful, nice.

We seriously need a way to check IDs before the player is considered "connected".

neat, could be useful.

We seriously need a way to check IDs before the player is considered "connected".
Can we not get the bl_id in onConnectRequest?

Can we not get the bl_id in onConnectRequest?
1) it's not available until the function autoAdminCheck is called, which is when the connect message is seen and the player is considered "connected"
2) onConnectRequest is before authentication and checking IDs here wouldn't be full spam-proofing as I could pretend to be have any ID I wanted to have.

1) it's not available until the function autoAdminCheck is called, which is when the connect message is seen and the player is considered "connected"
2) onConnectRequest is before authentication and checking IDs here wouldn't be full spam-proofing as I could pretend to be have any ID I wanted to have.
Well, that sucks. There must be a way to do this. When exactly does authentication happen / what calls it?

Well, that sucks. There must be a way to do this. When exactly does authentication happen / what calls it?
Authentication is done inside by function you can't package. Simply adding a callback called from that protected function would allow add-on makers to do pre-joining ID checks. Right after authentication is finished, the client is "connected" (but no join message appears, as I just realized) but, if it disconnects, it will cause a disconnect message to be heard and seen. It's easy spam.

Authentication is done inside by function you can't package.
Is it an engine function, or a blacklisted torquescript function?

Is it an engine function, or a blacklisted torquescript function?
You can see it being called. You can see it in a trace. You can see the arguments. You can see all the other functions it calls. You can't package it.

You can see it being called. You can see it in a trace. You can see the arguments. You can see all the other functions it calls. You can't package it.
I'm not on my computer so I can't see anything atm :c
I'll look at that tomorrow

You mean the servAuthTCPobj(or similar)::onLine?
« Last Edit: May 22, 2013, 06:51:15 PM by Zeblote »

Why not use the white list addon?

Why not use the white list addon?
cause politics.

Anyways, this is nice. Good job.

cause politics.

Anyways, this is nice. Good job.
Thanks

Why not use the white list addon?
Using a whitelist add-on would result in you changing the whitelist every single time you want a different player to connect. With this just make them admin, much less work for you.