Inactive [ADMN] BanHammer v2.0.2 Bans, kicks and records [1.3.1-R2.0]

Discussion in 'Inactive/Unsupported Plugins' started by grandwazir, Jun 26, 2011.

  1. Offline



    BanHammer is a plugin that allows adminstrators and other trusted users to ban and kick players. The basic idea is to have a lightweight banning solution that includes all the features you help manage your server. Additionally the plugin stores all bans using the Bukkit persistance system, using permissions for all commands and is simple to configure.

    • Simple and easy to configure.
    • Supports permenant as well as temporary bans.
    • Custom configurable limits to prevent moderators banning for too long.
    • Ban offline and online players.
    • Player name matching when kicking or banning players (no need to type every letter)
    • Can broadcast notifications to other players.
    • Review previous bans of a player, even after they have expired.
    • Review recent bans to see what has been happening while you have been away.
    • Banned names are cached for quick logins.
    • Reload the banned name cache on command (useful if you alter the database outside the plugin)
    • Uses Bukkit persistence for data storage; you choose what is best for you.
    • Supports built in Bukkit permissions, operators have all commands by default.
    • Command help system, simply type /bh.
    • Bukkit Persistence needs to be configured in bukkit.yml
    • If using MySQL for Persistence, you need a MySQL database

    Ensure you are using the latest recommended build.

    Before installing, you need to make sure you are running at least the latest recommended build for Bukkit. Support is only given for problems when using a recommended build. This does not mean that the plugin will not work on other versions of Bukkit, the likelihood is it will, but it is not supported.

    Getting BanHammer

    The best way to install BanHammer is to use the symbolic link to the latest version. This link always points to the latest version of BanHammer, so is safe to use in scripts or update plugins. Additionally you can to use the RSS feed provided by BukkitDev as this also includes a version changelog.

    Alternatively older versions are available as well, however they are not supported. If you are forced to use an older version for whatever reason, please let me know why by opening a issue on GitHub.

    1. Configure permissions if necessary.
    2. Optionally configure your ban limits (config.yml) and assign them to moderators.
    All documentation for BanHammer is available on the GitHub wiki, including example usage.

    Reporting issues

    If you encounter any problems using BanHammer, and you believe it is due to a bug in BanHammer, report the issue on the issue tracker. Please do not report issues in this thread as I will not see them as quickly as if you place them on the tracker.
    klarnet, PatrickFreed and fromgate like this.
  2. Offline


    If you get banned and try to log-in does it shows this message: The BanHammer has spoken!
  3. Offline


    Does this plugin support IPbans?
  4. Offline


    Is that possible to make Banlist using this plugin? I want to put it on website for users, to see for what are they banned.
  5. Offline


    ummm wheres the download link srry :/
  6. Offline


    Hmmm this plugin doesn't seem to work with PermissionsEx. It says I have to add perm, but it's already done. Any help?
  7. I get this error when i use /bh recent:

    01:05:54 [INFO] [BanHammer] 123 has been banned by########.
    01:06:02 [SEVERE] null
    org.bukkit.command.CommandException: Unhandled exception executing command 'bh' in plugin BanHammer v1.8.0
        at org.bukkit.command.PluginCommand.execute(
        at org.bukkit.command.SimpleCommandMap.dispatch(
        at org.bukkit.craftbukkit.CraftServer.dispatchCommand(
        at net.minecraft.server.NetServerHandler.handleCommand(
        at net.minecraft.server.NetServerHandler.a(
        at org.getspout.spout.SpoutNetServerHandler.a(
        at net.minecraft.server.Packet3Chat.handle(
        at net.minecraft.server.NetworkManager.b(
        at net.minecraft.server.NetServerHandler.a(
        at org.getspout.spout.SpoutNetServerHandler.a(
        at net.minecraft.server.NetworkListenThread.a(
        at net.minecraft.server.MinecraftServer.w(
    Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
        at name.richardson.james.bukkit.banhammer.ban.RecentCommand.execute(
        at name.richardson.james.bukkit.util.command.PlayerCommand.onCommand(
        at name.richardson.james.bukkit.util.command.CommandManager.onCommand(
        at org.bukkit.command.PluginCommand.execute(
        ... 14 more
  8. Offline


    toon7 I am aware of this one. Will be fixed in next release.
  9. ok thx :D
  10. Offline


    Download link is broken

    I was wrong
  11. Offline


    Where is the IP ban?
  12. Offline


    I'm using BK 1.1 R3.
    And I can See that, when BH start
    [SEVERE] Error occurred while enabling BanHammer v1.8.1 (Is it up to date?): The permission banhammer.* is already defined!
    java.lang.IllegalArgumentException: The permission banhammer.* is already defined!
  13. Offline


    Are you sure you are not trying to load two copies of BanHammer?
  14. Offline


    I don't know how to use your API. Where should I put getBanHammer() method? When I try it in main class "banHammerHandler" is underlined.
    grandwazir likes this.
  15. Offline


    Nope there is only one copy og BH,
    i forgot to say, we want to use it with plugin TOWNY ( RPG )
  16. Offline

    Cpt. Brenner

    I'm having a bit of trouble here, after setting up the permission nodes under PermissionEx (1.1.8). I'll try to ban/kick my test player(s) and get an error in-game saying...
    "You do not have permission to do this.
    You require banhammer.[ban/kick] to do this."

    The red line is from PermissionEx and the purple line is from banhammer. The interesting thing is that the nodes are correctly placed in Pex and will work if I place myself in OP.txt

    I've updated PermissionEx to the latest build, no go.
    I've looked at console when tying in the command and get "10:37:11 [INFO] [BanHammer] 5000"
    During the boot up the server, the banhammer immediately goes to OP style of permission.

    Any info would be marvelous.
    [Note: I will not give my permission.yml or my console report unless asked, if then it will be submitted via PM]

    -Signed Cpt. Brenner
    NoobGalore Minecraft DEV Team
  17. Offline


    Can you please add ban broadcasts? with reason/time
  18. Offline


    same thing here, my mods cant ban
    couldnt you just make it use bukkitperms?
  19. Offline


    You need to add the BanHammer.jar to your build path like you did with Bukkit. Once you have done that, if you are using my example function, you should place it in your main class. It does not have to go their but the example expects that is where it would be placed. You can then use the methods as described here.

    The first line isn't from PEX, it is generated from BanHammer when you do not have a permission. The second line is only generated if you are running with debugging on. Making yourself an OP will make it work since player.hasPermission always returns true when a player is an OP.

    If you are attempting to ban a player permanently, you require both banhammer.ban and banhammer.ban.* to do so. The wildcard enables you to skip over the ban limit check. If you have defined no limits and you attempt to ban without banhammer.ban.* you will receive this error message. I have updated the documentation on the ExampleUsage page to reflect this.

    The 5000 is coming from the time in milliseconds that you want to ban someone for and should not be outputted to the log and will be removed in the next release.

    This is already added to the plugin. Give players who should receive these messages the banhammer.notify permission. Also for your permission problems look at the link above that I gave Cpt. Brenner.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: May 17, 2016
  20. Offline


    Well, I think its problem with PEX, my mods have "banhammer.ban" permission, and they cant even ban for one minute (max temp ban is set to 3 days)
  21. Offline

    Cpt. Brenner

    Ah, I figured it out now, its confusing at first since your wiki doesn't fully explain it in full detail as to how to add a temp ban system to mods other than just stating the node. Read the spoiler for more info on temp bans
    Show Spoiler
    To add a temp ban node of lets say long (7 day ban), you need to add the following nodes:
    - banhammer.ban
    - banhammer.ban.[short/medium/long] (depending on the time frame you want it set too)

    Then from there they can only ban to the highest time they have to them (which in our case is long), same thing goes for the specific time bans too (i.e. /ban [name] [reason] t:6d14m7s). If they try to go over their limit it refuses that command.

    Now you can also change the length of the bans to a custom length of your choice. Read spoiler for more info.
    Show Spoiler
    To add more configured banning times lets say 1day, 7day, 9day, and 14day. First go into your config file and rename your length bans to whatever you wish (NOTE: They need to be words so having 5short will work whereas 5m will not.) For example, here is what my config looks like:
    - 1long: 1d
    - 7long: 7d
    - 9long: 9d
    - 14long: 14d

    The program will read them like that and will accept it. I stay with the [short], [medium], and [long] just because its easier to remember that way but you can change it to anything you want. If setting custom time limits for mods to use, the same rule applies so lets pick 9 days for our example, our permissions would look like:
    - banhammer.ban
    - banhammer.ban.9long (this the same as above, make sure its exactly how it's spelled otherwise it'll complain or worse crash)

    Now your mods can ban up to 9 day and cannot go over. You can always add additional times to the config as long as its typed the same was as the others (if not it'll not work).
    There you go, its pretty much straight forward for the most part, if at any times please feel free to ask me here or at

    -Signed Cpt. Brenner
    NoobGalore Minecraft DEV Team
  22. Offline


    Hey, will these plugin be updated to 1.2? Sorry to ask-It's pretty essential for our server.
  23. Offline


    This is the only kick/ban plugin I enjoy using. Many of the other ones don't work properly or are over-featured. Please update :)
  24. Offline


    Thanks for the feedback. BanHammer has been ready for the update since 28th of January. As long as you are using a version >= 1.70 it will work fine.
  25. Offline


    I'm using RB1.1-R7 with PEX1.19.

    Just installed BanHammer 1.8.1 and the following appears on server launch. (See end for error)

    10:57:25 [INFO] [BanHammer] Enabling BanHammer v1.8.1
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammerConfiguration> Registering ban limits
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammerConfiguration> Creating new ban limit warning with a maximum time of 1h (3600000).
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammerConfiguration> Creating new ban limit short with a maximum time of 1d (86400000).
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammerConfiguration> Creating new ban limit medium with a maximum time of 3d (259200000).
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammerConfiguration> Creating new ban limit long with a maximum time of 7d (604800000).
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.DatabaseHandler> Attempting to return records matching the class: name.richardson.james.bukkit.banhammer.BanRecord
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.DatabaseHandler> class name.richardson.james.bukkit.banhammer.BanRecord
    10:57:25 [INFO] [BanHammer] 0 banned names loaded.
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.ban (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.ban.* (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.ban.warning (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.ban.short (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.ban.medium (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.ban.long (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.kick (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.pardon (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.pardon.* (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.pardon.all (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.check (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.export (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.history (default: true)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.history.* (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.history.others (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.import (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.limits (default: true)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.purge (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.recent (default: op)
    10:57:25 [FINE] <name.richardson.james.bukkit.banhammer.BanHammer> Adding permission: banhammer.reload (default: op)
    10:57:25 [SEVERE] Error occurred while enabling BanHammer v1.8.1 (Is it up to date?)
            at name.richardson.james.bukkit.banhammer.BanHammer.registerCommands(
            at name.richardson.james.bukkit.banhammer.BanHammer.onEnable(
            at org.bukkit.plugin.SimplePluginManager.enablePlugin(
            at org.bukkit.craftbukkit.CraftServer.loadPlugin(
            at org.bukkit.craftbukkit.CraftServer.enablePlugins(
            at net.minecraft.server.MinecraftServer.t(
            at net.minecraft.server.MinecraftServer.a(
            at net.minecraft.server.MinecraftServer.init(
  26. Offline


    Hi, can you add ip to mysql with ban of name ??
  27. Offline


    Hey,can you update this to 1.2 please? Thanks!
  28. Offline


    Also works with my R5 bukkit. Great job by the way ;)

    It works with R5 bro'

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
    Last edited by a moderator: May 17, 2016
  29. Offline


    I can not duplicate this on my server using the latest beta build. I will test and see if this happens with R7.
  30. Offline

    IOn Vash

    Is there a way to have this also ban by ip and not just by name?
  31. Offline


    I've got a self-made kick plugin, but this one overrides it. Can you show me where the kick-code is so I can remove it, or create an options to disable it?

Share This Page