NoCheatPlus
Detect and fight the exploitation of various flaws/bugs in Minecraft!
Introduction
NoCheatPlus attempts to prevent cheat clients from exploiting weaknesses of Minecraft or its protocol, making your server more safe. Checks cover a wide range of issues including flying and speeding, fighting hacks, fast block breaking and nukers, inventory hacks, chat spam and other types of malicious behaviour. For a more complete list have a look at the Features Page.
NoCheatPlus puts emphasis on configurability and allows you to customize actions that are carried out when a player fails a check (e.g. silent cancelling, executing commands, just logging). Bypass permissions allow to control what check to apply for which players, all checks can be deactivated in the configuration, also having the option for world-specific configuration files. Many checks allow more detailed configuration to adjust sensitivity.
Certainly NoCheatPlus is not a magical bullet, it uses a lot of heuristics and even guessing, so you will encounter false positives here and there and also not catch every single violation. Example video of how NoCheatPlus blocks cheats (outdated plugin version).
NoCheatPlus was introduced by NeatMonster, building on the code base of NoCheat by Evenprime.
Recommended
The following plugins might be useful to have a look at.
ProtocolLib
Allows NoCheatPlus to activate packet-level checks, covering a range of exploits that can't be monitored using ordinary means. Since roughly Minecraft 1.7.10, the fight.speed check can't work as expected anymore, due to changes in CraftBukkit. With ProtocolLib this can be repaired.
CompatNoCheatPlus (cncp)
Make plugins like mcMMO or MachinaCraft more compatbile with NoCheatPlus. Not all existing plugins are covered (yet), but you can leave a note or create an issue/ticket request for cncp. Phasing out: Citizens 2 should work with NCP out of the box, MagicSpells are working on compatibility too - rest will be integrated into NCP.
Orebfuscator
Orebfuscator fights all sorts of X-ray-hacks by altering the map information that is sent to the players, such that they have to mine blocks to actually reveal what is behind. Virtually a "must have". (Latest versions of Spigot contain features of Orebfuscator.)
Downloads and History of Changes
- Download officially approved versions on the Files page at BukkitDev.
- Development builds have been moved over to the Jenkins at md-5.net.
- Do not download from any other source, do not use jars other people send you.
- Change lists: Wiki (digest) | Jenkins (by build number) | GitHub (all commits).
- Source code
Plugin statistics are no longer reported to mcstats.org.
Support
Documentation Resources
- Consider first: Frequently asked Questions and Known Issues.
- Wiki (Configuration, Permissions, Commands)
- Developers might have a look at the page describing the API of NoCheatPlus.
Contact us
- Quick questions can be asked on this page,
or on IRC (Server: irc.spi.gt | Default-Port: 6667 | SSL-Port: 6697 | Channel: #nocheat | Web client: WebIRC) - For real issues or feature requests please create a new issue/ticket or add to an existing issue/ticket.
- To send information that is not to be seen by all, you can also reach us by PM to @asofold and @MyPictures. @IceAP (IRC: ICE) will also help or redirect the conversation. Please do not contact the user 'NoCheatPlus', it is for administrative purposes only and will likely not be answered in time. Keep to BukkitDev and GitHub for support, do not trust users on other forums or websites, also not if their nick names are the same as NCP staff on BukkitDev.
Please always state the output of the "ncp version" command to let us know versions in use (users of cncp also the "cncp" command).
@asofold
The only config changes involving the checks are new higher-level thresholds to kick people for fight.angle and fight.direction. Nothing involving moving.
This guy was doing a lot of zig-zagging, with the sideways component probably faster than is normally possible. He was also pretty quick in a straight line, maybe 2x the normal speed. The only log messages were involving survivalfly, and he was occasionally kicked for that.
Not sure what you mean by your last question. I'm just using NCP for anti-cheat.
I see that the default config has no logging for net.flyingfrequency.
@Bobcat00
That's certainly interesting.
Of course a debug log would be interesting too, but it might be impossible to debug banned players, or to start when it's needed.
A player came on my server with a hacked client called Vivid. He was able to move around extremely fast, and NCP didn't kick him or prevent his movements. This isn't a big deal, but I'm reporting it in case it helps you improve your plugin. Following is the NCP INFO and VERSION information. Note the flyingfrequency and survivalfly violations.
Full version: http://www.bobcat00.com/ncp.png
@MarkElf2204
Essentially: https://github.com/NoCheatPlus/Issues/issues/22
Only using (positive) y-axis velocity might be interesting, because it can be confined easily, just to catch a couple of simple clients. Client developers will likely adapt to that, because vertical velocity is pretty cheap to use for them (thinking of ordinary pvp combat).
Next step will be they'll probably integrate horizontal velocity too, e.g. not doing friction like vanilla, so they only use velocity once and then move on normally, and further by faking a little more latency/lag, so they'll not fall off some cliff, or at least stay in control by having touched the ground before using hiorizontal velocity (much more friction = fewer effect).
In the meantime it might help sorting out a couple of simple clients.- Not sure it fits into the current "fight checks" iteration.
@FabioZumbi12
That one essentially looks the same. They seem to run asynchronous tasks to teleport players. Those should be primary thread tasks.
@asofold
About this log: http://dev.bukkit.org/paste/14140.txt
I have commented on Televator page about this error and waiting a response from owner: https://www.spigotmc.org/threads/televator.50374/#post-1282357
And about this log on console:
And looking for this id on nocheatplus.log i have this: http://pastebin.com/vADwd1mD
What about this log? And in sometimes, spam on console. Can i turn this off?
As you are currently working on combat checks @asofold, is there a possibility to incorporate a check for anti-knockback once again? Perhaps have NCP check for velocity packets being sent to the player. If the velocity on the y axis is positive, have NCP check if the player moves up. If not, then it increases the player's VL till it triggers whichever preset actions are defined within the configuration.
@uncovery
NCP supports the haste enchantment and also efficiency enchantments.
With a lot of lag (client side / network congestion / possibly a combination with server side lag, there could be many block breaks within very short time. To account for more lag, one could adjust the fastbreak configuration to allow more mining too fast (time per block vs. time mined too fast per ~ 90 seconds or so).
Now the question is which check actually prevents block breaking ... this should be tested, so you don't turn off protection needlessly. There is a chance that the blockbreak.frequency check prevents things here, because it doesn't keep track as long term as fastbreak does, and blockbreak.frequency has hard limits like ~ 40 for survival, and possibly a shortterm limit too. First you should ensure which checks are actually posting trouble ('ncp info player_name' can give a hint, you could also activate the allviolations hook to log to console, to get precise results).
Consider checking out the wiki, like @MarkElf2204 noted, the wiki has a search feature, which at least allows you to search for checks/titles.
@uncovery
I believe this page can assist you till @asofold gets a chance to reply. https://github.com/NoCheatPlus/Docs/wiki/%5BBlockbreak%5D-Fastbreak
I am getting quite some complaints from users saying that the fastbreak is preventing them from breaking blocks when they use eff5 with a mining beacon. Are the default configs set up for that vanilla usage? Or do I have to assume that they just have a laggy connection?
@asofold
Ok! Thank you for your answer :)
@Chevels
Piston + slime is still not fixed. Current focus is fight checks (infrastructure, then starting to make use of it). We're all having pistons in mind, it'll eventually be fixed - so i'm afraid it'll need a little bit of patience till.
Hello, sorry if this is a redundant question, but how can we allow the use of slime block with pistons (propulsion) without disabling the control SurvivalFly? I know you work on this concern, but since the time the members of my server are impatient ^^
Anyway, thank you for your excellent work on NoCheatPlus :) This is definitely a great plugin that I use for years!
@Maxetto
Looks like PlotSquared is teleporting players asynchronously.
Possibly their teleportation method is intended to synch into the main thread: https://github.com/IntellectualSites/PlotSquared/blob/master/src/main/java/com/plotsquared/bukkit/listeners/PlayerEvents.java#L454
Asked on their page: http://dev.bukkit.org/bukkit-plugins/plotsquared/#c66
Currently not sure if that's an issue with CB/Spigot or PlotSquared, or if the task is run in a time slice/slot where tasks run anyway, though this is highly problematic as plugins hardly can know if it's danmgerous to access Bukkit API, so they'd have to cancel off-primary events of those types of events that are usually fired within the primary thread.
@latestduo
It's about to get released. Still need to see which version of Minecraft it supports officially (same as 3.6.4?).
@latestduo
I've modified my configuration with fully custom strings (minus a few). I've never had an issue where I had to update protocol lib to a Dev build.
For anyone having issues with errors after adding custom strings you need to upload ProtocolLib to the latest build (build #222) it will soon be released under the version 3.6.5
@asofold
Sure, here it is: http://pastebin.com/C6ghaCue
@File14
(Not sure you noticed: part of the answer to the error question i might've addressed to @MarkElf2204 part-accidentally.)
Can survivalfly issues be described / confined to any circumstances with NCP build 925?
@asofold
https://i.gyazo.com/ee0b2fbbfa429eaac0af8cffe0b2c566.png
@SmilingSlimeGuy
There exists 'ncp exempt player_name/uuid check_type(s...)' plus unexempt, however it's meant for pinpointing exemption with events or for testing, rather. You could use that, if you don't have other external compatibility hooks. With cncp or external hooks i wouldn't count on the plugins not removing the exemption that you have added, because other plugins might not check for previous exemption.
The most certain way to do it, would be to add them to a permission group temporarily or add transient permissions via you permissions plugin. A transient group would allow combining permissions for that task, and might also perform better due to only recalculating permissions once, if supported. Permission perform worse than exemption, but the duration of validity and the consistency may be easier to control, depending on the permissions plugin.
NoCheatPlus defines a couple of shortcut permissions, such as nocheatplus.shortcut.bypass. (don't mix up with nocheatplus.bypass, and don't ask me why the latter one is there for only one feature). The nocheatplus.shortcut.bypass permission might allow a little too much (bypassing command protection as well), you could also just give the necessary permissions one by one or start with nocheatplus.checks for bypassing most stuff.
@grosse01
I'd really ask the vanish plugin makers first, essentials has vanish features too. Technically i am not sure how they do it, unless minecraft tells them anyway (bug in the vanish implementation?), there could be plugins exposing some things indirectly. Do they see the vanished players directly, or do they just notice that there are vanished players nearby?
@Maxetto
Oh that one :). Do you have the stack trace log (one line!) that should be there with the first time of a specific call? Each stack trace is only printed once, provided you have about build 925.
@asofold
No, it's just a Warning from NCP regarding the way PlotSquared opens Inventories on player's join.
"Off primary thread call to hasByPass for INVENTORY_OPEN."