diff options
author | unknown <iggy@mysql.com> | 2006-06-27 20:10:49 -0400 |
---|---|---|
committer | unknown <iggy@mysql.com> | 2006-06-27 20:10:49 -0400 |
commit | 0f9725ad1fb99385ab0d184cf0851670fee37bbe (patch) | |
tree | 6daf13b3703255dfea62af64bc035bcd630eb4a0 /mysql-test/t/grant2.test | |
parent | f4a07612efd66a559fe06810deee5e38cd96d03c (diff) | |
download | mariadb-git-0f9725ad1fb99385ab0d184cf0851670fee37bbe.tar.gz |
Bug#16180 Setting SQL_LOG_OFF without SUPER privilege is silently ignored
mysql-test/r/grant2.result:
Added results for bug#16180
mysql-test/t/grant2.test:
Added test for bug# 16180
sql/set_var.cc:
Verify user has appropiate rights before setting the sql_log_off system variable.
Diffstat (limited to 'mysql-test/t/grant2.test')
-rw-r--r-- | mysql-test/t/grant2.test | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/mysql-test/t/grant2.test b/mysql-test/t/grant2.test index 79ea7f70712..9da95cd42da 100644 --- a/mysql-test/t/grant2.test +++ b/mysql-test/t/grant2.test @@ -238,5 +238,22 @@ connect (con9,127.0.0.1,root,,test,$MASTER_MYPORT,); disconnect con9; connection default; +# +# Bug# 16180 - Setting SQL_LOG_OFF without SUPER privilege is silently ignored +# +create database mysqltest_1; +grant select, insert, update on `mysqltest\_1`.* to mysqltest_1@localhost; +connect (con10,localhost,mysqltest_1,,); +connection con10; +--error 1227 +set sql_log_off = 1; +--error 1227 +set sql_log_bin = 0; +disconnect con10; +connection default; +delete from mysql.user where user like 'mysqltest\_1'; +delete from mysql.db where user like 'mysqltest\_1'; +drop database mysqltest_1; +flush privileges; # End of 4.1 tests |