aboutsummaryrefslogtreecommitdiff
path: root/sql/updates/auth
diff options
context:
space:
mode:
authorSpp <spp@jorge.gr>2013-08-30 16:26:52 +0200
committerSpp <spp@jorge.gr>2013-08-30 16:26:52 +0200
commit9bea4fc4515b556fc69412cccc3c3f186553fe7b (patch)
tree541894972436b1b0a4166f18889e21dd58b59b62 /sql/updates/auth
parent2b69f83823af84da08be5888185b6da14742c387 (diff)
Core/RBAC: Move ban commands to RBAC (using individual permissions)
Diffstat (limited to 'sql/updates/auth')
-rw-r--r--sql/updates/auth/2013_08_30_03_auth_misc.sql43
1 files changed, 43 insertions, 0 deletions
diff --git a/sql/updates/auth/2013_08_30_03_auth_misc.sql b/sql/updates/auth/2013_08_30_03_auth_misc.sql
new file mode 100644
index 00000000000..a6495a2de6e
--- /dev/null
+++ b/sql/updates/auth/2013_08_30_03_auth_misc.sql
@@ -0,0 +1,43 @@
+-- Add new permissions
+DELETE FROM `rbac_permissions` WHERE `id` BETWEEN 239 AND 256;
+INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
+(239, 'ban'),
+(240, 'ban account'),
+(241, 'ban character'),
+(242, 'ban ip'),
+(243, 'ban playeraccount'),
+(244, 'baninfo'),
+(245, 'baninfo account'),
+(246, 'baninfo character'),
+(247, 'baninfo ip'),
+(248, 'banlist'),
+(249, 'banlist account'),
+(250, 'banlist character'),
+(251, 'banlist ip'),
+(252, 'unban'),
+(253, 'unban account'),
+(254, 'unban character'),
+(255, 'unban ip'),
+(256, 'unban playeraccount');
+
+-- Add Permissions to "corresponding Commands Role"
+DELETE FROM `rbac_role_permissions` WHERE `permissionId` BETWEEN 239 AND 256;
+INSERT INTO `rbac_role_permissions` (`roleId`, `permissionId`) VALUES
+(4, 239),
+(4, 240),
+(4, 241),
+(4, 242),
+(4, 243),
+(4, 244),
+(4, 245),
+(4, 246),
+(4, 247),
+(4, 248),
+(4, 249),
+(4, 250),
+(4, 251),
+(4, 252),
+(4, 253),
+(4, 254),
+(4, 255),
+(4, 256);