mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 19:37:16 +02:00
unsufficient privilege checks in GRANT, when a grantor has column-level privileges
This commit is contained in:
parent
4ba981e521
commit
40a0199e77
4 changed files with 55 additions and 55 deletions
|
|
@ -121,7 +121,7 @@ create database mysqltest;
|
|||
create table mysqltest.t1 (a int,b int,c int);
|
||||
grant all on mysqltest.t1 to mysqltest_1@localhost;
|
||||
alter table t1 rename t2;
|
||||
insert command denied to user: 'mysqltest_1@localhost' for table 't2'
|
||||
INSERT,CREATE command denied to user: 'mysqltest_1@localhost' for table 't2'
|
||||
revoke all privileges on mysqltest.t1 from mysqltest_1@localhost;
|
||||
delete from mysql.user where user='mysqltest_1';
|
||||
drop database mysqltest;
|
||||
|
|
|
|||
|
|
@ -198,7 +198,7 @@ GRANT UPDATE (d) ON `mysqltest_2`.`t2` TO 'mysqltest_3'@'localhost'
|
|||
update mysqltest_1.t1, mysqltest_1.t2 set q=10 where b=1;
|
||||
UPDATE command denied to user: 'mysqltest_3@localhost' for column 'q' in table 't1'
|
||||
update mysqltest_1.t1, mysqltest_2.t2 set d=20 where d=1;
|
||||
select command denied to user: 'mysqltest_3@localhost' for table 't1'
|
||||
SELECT command denied to user: 'mysqltest_3@localhost' for table 't1'
|
||||
update mysqltest_2.t1, mysqltest_1.t2 set c=20 where b=1;
|
||||
UPDATE command denied to user: 'mysqltest_3@localhost' for column 'c' in table 't1'
|
||||
update mysqltest_2.t1, mysqltest_2.t2 set d=10 where s=2;
|
||||
|
|
|
|||
|
|
@ -121,7 +121,7 @@ a b c a
|
|||
1 1 1 test.t1
|
||||
2 2 2 test.t1
|
||||
select * from t2;
|
||||
select command denied to user: 'mysqltest_2@localhost' for table 't2'
|
||||
SELECT command denied to user: 'mysqltest_2@localhost' for table 't2'
|
||||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 6
|
||||
|
|
@ -135,7 +135,7 @@ select "user3";
|
|||
user3
|
||||
user3
|
||||
select * from t1;
|
||||
select command denied to user: 'mysqltest_3@localhost' for column 'b' in table 't1'
|
||||
SELECT command denied to user: 'mysqltest_3@localhost' for column 'b' in table 't1'
|
||||
select a from t1;
|
||||
a
|
||||
1
|
||||
|
|
@ -143,7 +143,7 @@ a
|
|||
select c from t1;
|
||||
SELECT command denied to user: 'mysqltest_3@localhost' for column 'c' in table 't1'
|
||||
select * from t2;
|
||||
select command denied to user: 'mysqltest_3@localhost' for table 't2'
|
||||
SELECT command denied to user: 'mysqltest_3@localhost' for table 't2'
|
||||
select mysqltest.t1.c from test.t1,mysqltest.t1;
|
||||
SELECT command denied to user: 'mysqltest_3@localhost' for column 'c' in table 't1'
|
||||
show status like "Qcache_queries_in_cache";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue