A Minecraft Bukkit/Spigot plugin and Fabric mod designed to limit bot intrusion!
Explore the docs »
Report Bug
·
Request Feature
Table of Contents
BotBlocker is a solution for Minecraft servers designed to limit bot intrusion. It is available for both Bukkit/Spigot Minecraft servers and as a Fabric mod. If a user logs out too quickly after joining (indicating they might be a bot), the user is banned. This approach limits the number of login attempts from each UUID, effectively mitigating the consequences of a bot attack.
As of version 1.4.0 BotBlocker supports integration with:
When the server starts, BotBlocker initializes its configuration files (config.yml
and players.yml
). The initial default time limit for joining and leaving is set to 5 seconds. A message indicating the mod has successfully loaded with the set time limit is logged to the console.
When a player joins, if BotBlocker is enabled and the player is not already exempt from BotBlocker's checks, the mod/plugin records the player's UUID and the current time.
When a player quits, BotBlocker calculates the duration of their connection. If this time is less than the set time limit and BotBlocker is enabled, the player is considered a bot. They get banned and a ban entry is added to the players.yml
file. A disconnect message is sent to the player and a message is logged to the console. If the player stays longer than the time limit, they are deemed a legitimate player. Their UUID is added to the players.yml
file as exempt.
/BotBlocker enable
- Enable the BotBlocker plugin./BotBlocker disable
- Disable the BotBlocker plugin./BotBlocker status
- Show wether BotBlocker is enabled or disabled./BotBlocker setTimeLimit [seconds]
- Set the time limit for detecting bots. Default is 5 seconds./BotBlocker getTimeLimit
- Display the configured time limit for detecting bots./BotBlocker setBanMessage [message]
- Set the ban message./BotBlocker getBanMessage
- Display the configured ban message.
botblocker.enable
- Allows the user to enable the BotBlocker plugin.botblocker.disable
- Allows the user to disable the BotBlocker plugin.botblocker.status
- Allows the user to see whether BotBlocker is enabled or disabled.botblocker.settimelimit
- Allows the user to set the time limit for detecting bots.botblocker.gettimelimit
- Allows the user to display the configured time limit for detecting bots.botblocker.setbanmessage
- Allows the user to set the ban message.botblocker.getbanmessage
- Allows the user to display the configured ban message.
BotBlocker maintains its configuration and the list of player UUIDs in config.yml
and players.yml
files, respectively.
Note
Players identified as legitimate are marked as such in the players.yml
file and are not checked again in the future. If BotBlocker is disabled, it stops checking players for potential bot activity.
To get this plugin up and running on your server, follow these steps:
- Java 18 or later
- A Bukkit/Spigot server
- Download the latest BotBlocker
.jar
file from the releases page. - Move the downloaded
.jar
file to theplugins/
directory in your server. - Restart your server. This will generate a default configuration file.
Once installed and enabled, BotBlocker works in the background without any intervention. If needed, you can adjust the bot protection parameters in the generated config.yml
file.
To compile BotBlocker for Bukkit/Spigot yourself, follow these steps:
-
Make sure you have Maven installed on your system. You can download it from https://maven.apache.org/download.cgi and find installation instructions at https://maven.apache.org/install.html.
-
Clone this repository.
-
Open your terminal or command prompt.
-
Navigate to the root directory of the cloned repository.
cd path/to/BotBlocker
-
Execute the Maven build command:
mvn clean package
- The
clean
command will remove any previous build outputs to ensure a fresh build. - The
package
command will compile your code and package it into a JAR file.
- The
-
After the build completes, you can find the compiled JAR file in the
target
directory of the project. -
The JAR file will be named following the convention
BotBlocker-M.m.p.jar
, whereM.m.p
is the version number following Semantic Versioning. -
You can now deploy this JAR file to your Bukkit/Spigot server's
plugins
folder.
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the GNU General Public License v3.0. See LICENSE
for more information.
Aitor Astorga Saez de Vicuña - a.astorga.sdv@gmail.com
Project Link: https://github.com/BotBlocker-Minecraft