From 953575abfa631b9c58d8a8acc1fc8a37359f6fa6 Mon Sep 17 00:00:00 2001 From: Spp Date: Tue, 10 Sep 2013 15:35:10 +0200 Subject: Core/RBAC: Remove obsolete generic command permissions Note: If you have any custom command, CHECK THE SQLS BEFORE APPLYING --- sql/updates/auth/2013_09_10_14_auth_misc.sql | 4 ++++ sql/updates/world/2013_09_10_15_world_command.sql | 1 - sql/updates/world/2013_09_10_16_world_command.sql | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 sql/updates/auth/2013_09_10_14_auth_misc.sql create mode 100644 sql/updates/world/2013_09_10_16_world_command.sql (limited to 'sql/updates') diff --git a/sql/updates/auth/2013_09_10_14_auth_misc.sql b/sql/updates/auth/2013_09_10_14_auth_misc.sql new file mode 100644 index 00000000000..0f24f96ca99 --- /dev/null +++ b/sql/updates/auth/2013_09_10_14_auth_misc.sql @@ -0,0 +1,4 @@ +-- Remove obsolete permissions + +DELETE FROM `rbac_role_permissions` WHERE `permissionId` IN (7, 8, 9, 10, 12); +DELETE FROM `rbac_permissions` WHERE `id` IN (7, 8, 9, 10, 12); diff --git a/sql/updates/world/2013_09_10_15_world_command.sql b/sql/updates/world/2013_09_10_15_world_command.sql index f3601a3041b..ff70ba9b18d 100644 --- a/sql/updates/world/2013_09_10_15_world_command.sql +++ b/sql/updates/world/2013_09_10_15_world_command.sql @@ -3,7 +3,6 @@ SET @id = 761; -- Update command table with new RBAC permissions -UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'tele'; UPDATE `command` SET `permission` = @id+0 WHERE `name` = 'ticket'; UPDATE `command` SET `permission` = @id+1 WHERE `name` = 'ticket assign'; UPDATE `command` SET `permission` = @id+2 WHERE `name` = 'ticket close'; diff --git a/sql/updates/world/2013_09_10_16_world_command.sql b/sql/updates/world/2013_09_10_16_world_command.sql new file mode 100644 index 00000000000..3a3baf206b8 --- /dev/null +++ b/sql/updates/world/2013_09_10_16_world_command.sql @@ -0,0 +1,2 @@ +-- Update command table and remove obsolete permissions (0 = non existent permission) +UPDATE `command` SET `permission` = 0 WHERE `permission` IN (7, 8, 9, 10, 12); -- cgit v1.2.3