Updated-NoCheatPlus / NoCheatPlus

Anti-cheating plugin for Minecraft (1.5-1.20, Bukkit/Spigot)
https://ci.codemc.io/job/Updated-NoCheatPlus/job/Updated-NoCheatPlus/
GNU General Public License v3.0
482 stars 100 forks source link

(1.17+) Redundant position packet + UseItem packet inversion (move->useitem) #150

Closed MinesAndValleys closed 2 years ago

MinesAndValleys commented 3 years ago

Full output of /ncp version

https://paste.lucko.me/gPU5D3dfro

Describe the issue

I cannot jump while using right click in all cases.

How to reproduce the issue

Using right-click when jumping, especially when jumping to place a block below, it rubber bands back. Players have reported the water disappearing when they try to place water as they land to stop fall damage.

Extra links: video and/or debug log (instructions: https://github.com/Updated-NoCheatPlus/Docs/blob/master/Development/Debugging.md#on-the-fly-debug-output-for-individual-players)

https://paste.lucko.me/jHjipKnprV

Any possible config options changed or plugins that may cause interference?

MinesAndValleys commented 3 years ago

@Lysandr0 here's a video of me reproducing it. It's actually not every time, but more often when I right-click closer to when I jump.

https://cloudup.com/cINhAsSTxhP

Lysandr0 commented 3 years ago

Does it happen with noslow off? (checks.moving.survivalfly.extended.noslow).

MinesAndValleys commented 3 years ago

I can still reproduce it with that disabled.

Lysandr0 commented 3 years ago

Managed to reproduce it myself after a swift test. Should be tackled on Spigot/MC side, rather, but for now it looks like we'll need to add more convoluted workarounds to account for another vanilla bug (yet again). Similarly to lostground :) (Edit: Seems to be intended behaviour actually: apparently Mojang attempted to fix a bucket place desync issue by resending the player's position when right clicking(!?)).

https://user-images.githubusercontent.com/20213873/130325189-9bbbceec-e025-4444-8199-f3da9a8ed444.mov

compieter-gh commented 3 years ago

I think i also have a similar when attacking mobs/monsters

Lysandr0 commented 3 years ago

It happens with left clicks as well? ... Haven't tested it personally.

compieter-gh commented 3 years ago

I'll make an video bout the issue.

compieter-gh commented 3 years ago

https://youtu.be/Vy1Nx3kTfy8 -- With hacks I can't seem to reproduce it without hacks although all the fight check are disabled so it shouldn't happen either way

compieter-gh commented 3 years ago

config.yml.zip

Also viaversion is on the proxy on a 1.17.1 server and the client 1.16.5

Lysandr0 commented 3 years ago

The video doesn't tell much unfortunately. The setbacks you're experiencing are probably(if not for sure) due to the Criticals module which can trigger either MorePackets, if attacking too quickly the entity while moving, or SurvivalFly, depending on how the cheat is implemented :)

Lysandr0 commented 3 years ago

Minor update for onlookers :p As stated in Discord by CaptainObvious, every time the client sends a use item packet it will also send a flying packet with the same position as before (since 1.17). This will result in a duplicate flying packet which we should skip/ignore somehow.

Update: from further observation, this also concerns MorePackets, not only SurvivalFly. Due to the extra position packet, it'll trigger if you keep the button pressed for long enough.

ghost commented 3 years ago

Preview: https://streamable.com/bo3x2h

GunacP40 commented 2 years ago

Are there any updates on this? It's been a couple of months now. I'm having this issue as well.

Lysandr0 commented 2 years ago

Unfortunately, Xaw3ep seems to be on hiatus right now, so we likely have to wait for a while... Unless someone wants to PR, of course. :p

Lysandr0 commented 2 years ago

Fixed, hopefully this won't cause any new exploit/bypass to arise.