WorldGuard icon indicating copy to clipboard operation
WorldGuard copied to clipboard

blocked-commands flag won't block commands if player enters command with space after slash

Open PovilasLT opened this issue 3 years ago • 2 comments
trafficstars

WorldEdit Version

7.2.11-beta-01

WorldGuard Version

7.0.8-SNAPSHOT

Platform Version

git-Paper-51 (MC: 1.19) (Implementing API version 1.19-R0.1-SNAPSHOT) (Git: a05e69b)

Confirmations

  • [X] I am using the most recent Minecraft release.
  • [X] I am using a version of WorldEdit compatible with my Minecraft version.
  • [X] I am using a version of WorldGuard compatible with my Minecraft version.
  • [X] I am using the latest or recommended version of my platform software.
  • [X] I am NOT using a hybrid server, e.g. a server that combines Bukkit and Forge. Examples include Arclight, Mohist, and Cardboard.
  • [X] I am NOT using a fork of WorldEdit, such as FastAsyncWorldEdit (FAWE) or AsyncWorldEdit (AWE)

Bug Description

blocked-cmds flag won't block commands if command has space between slash and command (i.e. / home)

Expected Behavior

Flag should block commands with space after slash

Reproduction Steps

  1. Set flag blocked-cmds [/back, /home]
  2. Use command /back - it will be blocked, but you can easily bypass that by typing / home

Optional WorldGuard-Report

No response

Anything Else?

No response

PovilasLT avatar Jul 24 '22 12:07 PovilasLT

IIRC last time this was mentioned, it was found to be a bug in Paper (sending differing information to preprocessing and actual command handling)

me4502 avatar Jul 24 '22 12:07 me4502

yea this is a paper-specific bug. i brought it up to them but didn't get very far. preferably someone should make a bug report to them to get actual input. if they really refuse to fix it we could add a hacky workaround but i'd rather not since it relies on making assumptions about the underlying command flow between preprocess and actual execution.

wizjany avatar Jul 25 '22 14:07 wizjany