diff options
author | unknown <acurtis@xiphis.org> | 2005-05-17 19:54:20 +0100 |
---|---|---|
committer | unknown <acurtis@xiphis.org> | 2005-05-17 19:54:20 +0100 |
commit | 55171821d238704a8b43a7ba4d150384f9ea70e1 (patch) | |
tree | 09011cb747c8c1ed831bf8ca66668d0aa4f2610a /mysql-test/t/sp-security.test | |
parent | 9b07cafe1e7a1230218c06f85b88f68b5741c9ef (diff) | |
download | mariadb-git-55171821d238704a8b43a7ba4d150384f9ea70e1.tar.gz |
Bug#10246 - Parser: bad syntax for GRANT EXECUTE
Rename some functions
more fine-grained sp privileges
make grant/revoke sp grammar less ambigious
mysql-test/r/sp-security.result:
change test for new syntax
mysql-test/r/system_mysql_db.result:
change test for new syntax
mysql-test/t/sp-security.test:
change test for new syntax
scripts/mysql_create_system_tables.sh:
now store routine_type for procs_priv
scripts/mysql_fix_privilege_tables.sql:
now store routine_type for procs_priv
sql/item_func.cc:
rename of function
sql/mysql_priv.h:
rename of function
sql/sp_head.cc:
extra arg for check_some_routine_access
sql/sql_acl.cc:
rename of function. now handle func/proc acls seperately
sql/sql_acl.h:
rename of function
sql/sql_parse.cc:
rename of function
grants for procs handled distinctly from funcs
sql/sql_show.cc:
check_some_routine_access extra arg
sql/sql_base.cc:
fix for build
sql/sql_yacc.yy:
fix for build
Diffstat (limited to 'mysql-test/t/sp-security.test')
-rw-r--r-- | mysql-test/t/sp-security.test | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/mysql-test/t/sp-security.test b/mysql-test/t/sp-security.test index 5a8dfc54920..e1d8043ccda 100644 --- a/mysql-test/t/sp-security.test +++ b/mysql-test/t/sp-security.test @@ -43,10 +43,10 @@ call stamp(1); select * from t1; select db(); -grant execute on db1_secret.stamp to user1@'%'; -grant execute on db1_secret.db to user1@'%'; -grant execute on db1_secret.stamp to ''@'%'; -grant execute on db1_secret.db to ''@'%'; +grant execute on procedure db1_secret.stamp to user1@'%'; +grant execute on function db1_secret.db to user1@'%'; +grant execute on procedure db1_secret.stamp to ''@'%'; +grant execute on function db1_secret.db to ''@'%'; connect (con2user1,localhost,user1,,); connect (con3anon,localhost,anon,,); @@ -183,10 +183,10 @@ call q(); select * from t2; connection con1root; -grant usage on db2.q to user2@localhost with grant option; +grant usage on procedure db2.q to user2@localhost with grant option; connection con4user2; -grant execute on db2.q to user1@localhost; +grant execute on procedure db2.q to user1@localhost; connection con2user1; use db2; @@ -245,9 +245,9 @@ create database sptest; create table t1 ( u varchar(64), i int ); create procedure sptest.p1(i int) insert into test.t1 values (user(), i); grant insert on t1 to usera@localhost; -grant execute on sptest.p1 to usera@localhost; +grant execute on procedure sptest.p1 to usera@localhost; show grants for usera@localhost; -grant execute on sptest.p1 to userc@localhost with grant option; +grant execute on procedure sptest.p1 to userc@localhost with grant option; show grants for userc@localhost; connect (con2usera,localhost,usera,,); @@ -257,7 +257,7 @@ connect (con4userc,localhost,userc,,); connection con2usera; call sptest.p1(1); --error 1370 -grant execute on sptest.p1 to userb@localhost; +grant execute on procedure sptest.p1 to userb@localhost; --error 1370 drop procedure sptest.p1; @@ -265,32 +265,32 @@ connection con3userb; --error 1370 call sptest.p1(2); --error 1370 -grant execute on sptest.p1 to userb@localhost; +grant execute on procedure sptest.p1 to userb@localhost; --error 1370 drop procedure sptest.p1; connection con4userc; call sptest.p1(3); -grant execute on sptest.p1 to userb@localhost; +grant execute on procedure sptest.p1 to userb@localhost; --error 1370 drop procedure sptest.p1; connection con3userb; call sptest.p1(4); --error 1370 -grant execute on sptest.p1 to userb@localhost; +grant execute on procedure sptest.p1 to userb@localhost; --error 1370 drop procedure sptest.p1; connection con1root; select * from t1; -grant all privileges on sptest.p1 to userc@localhost; +grant all privileges on procedure sptest.p1 to userc@localhost; show grants for userc@localhost; show grants for userb@localhost; connection con4userc; -revoke all privileges on sptest.p1 from userb@localhost; +revoke all privileges on procedure sptest.p1 from userb@localhost; connection con1root; show grants for userb@localhost; |