The Meaning of Life, the Universe, and Everything.
Join Date:
3/10/2013
Posts:
196
Xbox:
f*** Microsoft
Member Details
It's just bad coding design that these commands can accept Minecraft usernames that aren't even valid.
First of all, none of these commands should work if the parameter has spaces. Somehow (probably because of accidentally pasting), I've banned the user "/give bomb56 5 64". It just puts useless entries in the ban/op/ipban lists, creating clutter and very slightly longer search times.
/ban-ip (username) should ban the IP address of the player matching the name who is currently online. For example, if I want to ban meanbeeze's IP address while he's online, "/ban-ip meanbeeze". Currently, typing that in would ban the actual IP address "meanbeeze", which isn't even a valid address. Why would you EVER want to do that??? It should detect whether you're typing in a name and therefore want to ban that user's IP or if you're typing an IPv4 address and want to ban that address (4 numbers separated by periods).
Most of this is minor except for the ban-ip command, which is very inconvenient in its current state because the admin must check the console every time he wants to use it. The rest of this suggestion is just good coding practice. Any new programmer knows that methods should not accept senseless parameters.
P.S. I know that someone could have invalid names by logging into an offline mode server with a name spoofer, but if they are doing that, the name is not even tied to that person, so op/ban commands are useless. If someone really wants to do that for some unknown reason, he can edit the file himself.
Edit: Misread, but I don't understand the problem. Ok, you can ban usernames that aren't valid. But then why are you banning them in the first place? If there is no player named "LOLOLOLOLOLOL1234567890", then why is that name on the ban list in the first place?
Edit: Misread, but I don't understand the problem. Ok, you can ban usernames that aren't valid. But then why are you banning them in the first place? If there is no player named "LOLOLOLOLOLOL1234567890", then why is that name on the ban list in the first place?
By mistake, it is possible and happens sometimes. The main point is that you should be able to ban an IP by the user's ingame name.
Rollback Post to RevisionRollBack
My Bukkit plugin for IP-banning offline players, logging addresses, and more:
First of all, none of these commands should work if the parameter has spaces. Somehow (probably because of accidentally pasting), I've banned the user "/give bomb56 5 64". It just puts useless entries in the ban/op/ipban lists, creating clutter and very slightly longer search times.
/ban-ip (username) should ban the IP address of the player matching the name who is currently online. For example, if I want to ban meanbeeze's IP address while he's online, "/ban-ip meanbeeze". Currently, typing that in would ban the actual IP address "meanbeeze", which isn't even a valid address. Why would you EVER want to do that??? It should detect whether you're typing in a name and therefore want to ban that user's IP or if you're typing an IPv4 address and want to ban that address (4 numbers separated by periods).
Most of this is minor except for the ban-ip command, which is very inconvenient in its current state because the admin must check the console every time he wants to use it. The rest of this suggestion is just good coding practice. Any new programmer knows that methods should not accept senseless parameters.
P.S. I know that someone could have invalid names by logging into an offline mode server with a name spoofer, but if they are doing that, the name is not even tied to that person, so op/ban commands are useless. If someone really wants to do that for some unknown reason, he can edit the file himself.
[quote=Badgerz]You have to keep in mind that people are stupid.
[quote=Catelite]Just because you don't understand how something works, doesn't make it broken or pointless. >_<
By mistake, it is possible and happens sometimes. The main point is that you should be able to ban an IP by the user's ingame name.