1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Bug#43748: crash when non-super user tries to kill the replication threads

Test was flakey on some machines and showed spurious
reds for races.

New-and-improved test makes do with fewer statements,
no mysqltest-variables, and no backticks. Should hope-
fully be more robust. Heck, it's debatable whether we
should have a test for this, anyway.

mysql-test/suite/rpl/r/rpl_temporary.result:
  streamlined
mysql-test/suite/rpl/t/rpl_temporary.test:
  streamlined
This commit is contained in:
Tatiana A. Nurnberg
2009-03-27 12:20:37 +01:00
parent fb8ac41a3b
commit ffd9792ca5
2 changed files with 22 additions and 21 deletions

View File

@ -108,13 +108,16 @@ select * from t1;
a
1
drop table t1;
Bug#43748
make a non-privileged user on slave.
-- Bug#43748
-- make a user on the slave that can list but not kill system threads.
FLUSH PRIVILEGES;
GRANT USAGE ON *.* TO user43748@127.0.0.1 IDENTIFIED BY 'meow';
try to KILL system-thread as non-privileged user.
KILL `select id from information_schema.processlist where command='Binlog Dump'`;
ERROR HY000: You are not owner of thread `select id from information_schema.processlist where command='Binlog Dump'`
throw out test-user on slave.
GRANT USAGE ON *.* TO user43748@127.0.0.1 IDENTIFIED BY 'meow';
GRANT PROCESS ON *.* TO user43748@127.0.0.1;
-- try to KILL system-thread as that non-privileged user (on slave).
SELECT id INTO @id FROM information_schema.processlist WHERE user='system user' LIMIT 1;
KILL @id;
Got one of the listed errors
-- throw out test-user on slave.
DROP USER user43748@127.0.0.1;
done. back to master.
-- done. back to master.
End of 5.1 tests