diff --git a/Database Updates/004_fix_acc_supporttool_rank.sql b/Database Updates/004_fix_acc_supporttool_rank.sql new file mode 100644 index 00000000..f0dfd371 --- /dev/null +++ b/Database Updates/004_fix_acc_supporttool_rank.sql @@ -0,0 +1,31 @@ +-- ============================================================ +-- Fix: acc_supporttool wrongly granted to VIP / wrongly denied to Super Mod +-- ============================================================ +-- The default permission_definitions seed shipped acc_supporttool +-- with rank pattern (0, 1, 1, 1, 1, 0, 1) — i.e. rank_2 (VIP) and +-- rank_3 (X, junior helper) had ALLOWED, while rank_6 (Super Mod) +-- did NOT. That's two bugs: +-- +-- * VIP users see the ModTools button on the toolbar and can +-- open Room/User info windows. The actual sanction endpoints +-- still gate on ACC_SUPPORTTOOL server-side so they can't +-- actually moderate, but the UI exposure is wrong and lets a +-- VIP request user info / room info / chatlogs they have no +-- business reading. +-- * Super Mod is denied the tool entirely, which is obviously +-- unintended given the rank name. +-- +-- Intended pattern: only Support (4) and up — (0, 0, 0, 1, 1, 1, 1). +-- +-- Run on existing deployments to align with the corrected default +-- seed in `Default Database/FullDatabase.sql`. Idempotent. + +UPDATE `permission_definitions` + SET `rank_1` = 0, + `rank_2` = 0, + `rank_3` = 0, + `rank_4` = 1, + `rank_5` = 1, + `rank_6` = 1, + `rank_7` = 1 + WHERE `permission_key` = 'acc_supporttool'; diff --git a/Default Database/FullDatabase.sql b/Default Database/FullDatabase.sql index 75a3b75b..c7e85d40 100644 --- a/Default Database/FullDatabase.sql +++ b/Default Database/FullDatabase.sql @@ -28598,7 +28598,7 @@ INSERT INTO `permission_definitions` (`permission_key`, `max_value`, `comment`, ('acc_staff_chat', 1, 'Grants access to the in-game Staff Chat group buddy: receives broadcasts from other staff and can broadcast to anyone holding this permission.', 0, 0, 0, 0, 0, 0, 1), ('acc_staff_pick', 1, 'Allows using staff item pick-up actions that bypass normal room ownership restrictions.', 0, 0, 0, 0, 0, 0, 1), ('acc_superwired', 1, 'Allows saving advanced wired data without the normal wordfilter and reward payload restrictions applied to regular users.', 0, 0, 0, 0, 0, 0, 1), - ('acc_supporttool', 1, 'Allows opening and using the support/moderation tool interface.', 0, 1, 1, 1, 1, 0, 1), + ('acc_supporttool', 1, 'Allows opening and using the support/moderation tool interface.', 0, 0, 0, 1, 1, 1, 1), ('acc_trade_anywhere', 1, 'Allows starting trades outside the normal trade-enabled areas.', 0, 0, 0, 0, 0, 0, 1), ('acc_unignorable', 1, 'Prevents the account from being ignored by other users through the ignore system.', 0, 0, 0, 0, 0, 0, 0), ('acc_unkickable', 1, 'Prevents the user from being kicked by normal moderation or room commands.', 0, 0, 0, 0, 0, 0, 1), diff --git a/Emulator/pom.xml b/Emulator/pom.xml index 8376f637..cb774ab9 100644 --- a/Emulator/pom.xml +++ b/Emulator/pom.xml @@ -6,7 +6,7 @@ com.eu.habbo Habbo - 4.2.10 + 4.2.12 UTF-8