diff options
author | Sergei Golubchik <serg@mariadb.org> | 2018-09-26 20:49:51 +0200 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2018-09-28 16:37:06 +0200 |
commit | 57e0da50bbef8164635317785b67dd468a908327 (patch) | |
tree | 89d1ed179afce8b040c8f2dfcfe179042ff27b2e /mysql-test/main/sp-security.test | |
parent | 7aba6f8f8853acd18d471793f8b72aa1412b8151 (diff) | |
parent | dcbd51cee628d8d8fec9ff5476a6afc855b007aa (diff) | |
download | mariadb-git-57e0da50bbef8164635317785b67dd468a908327.tar.gz |
Merge branch '10.2' into 10.3
Diffstat (limited to 'mysql-test/main/sp-security.test')
-rw-r--r-- | mysql-test/main/sp-security.test | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/mysql-test/main/sp-security.test b/mysql-test/main/sp-security.test index 73d0263dd69..4f645ce2cd3 100644 --- a/mysql-test/main/sp-security.test +++ b/mysql-test/main/sp-security.test @@ -973,6 +973,34 @@ disconnect con2; DROP USER user2@localhost; DROP DATABASE db1; +# +# Bug#27407480: AUTOMATIC_SP_PRIVILEGES REQUIRES NEED THE INSERT PRIVILEGES FOR MYSQL.USER TABLE +# +create user foo@local_ost; +# +# Create a user with an authentification plugin 'foobar'. +# Instead of using a normal "CREATE USER <user> IDENTIFIED VIA <plugin>" +# we do CREATE (without VIA) followed by UPDATE and FLUSH. +# This is to avoid installing a real plugin and thus avoid the test dependency. +# We won't login under this user in the below test, so this is fine. +# +create user foo@`local\_ost`; +update mysql.user set plugin='foobar' where host='local\\_ost'; +flush privileges; +create database foodb; +grant create routine on foodb.* to foo@local_ost; +connect con1,localhost,foo; +select user(), current_user(); +show grants; +create procedure fooproc() select 'i am fooproc'; +show grants; +disconnect con1; +connection default; +drop user foo@local_ost; +drop user foo@`local\_ost`; +drop procedure fooproc; +drop database foodb; + --echo # --echo # Test for bug#12602983 - User without privilege on routine can discover --echo # its existence by executing "select non_existing_func();" or by |