Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
10.6(EOL), 10.11, 11.4, 11.8, 12.3
-
Can result in unexpected behaviour
-
Views now escape user names in the view frm file; old views where the definer name included a backslash will need to be recreated
Description
create user 'root |
definer_host=localhost
|
suid=1'@localhost; |
|
|
--connect u,localhost,'root
|
definer_host=localhost
|
suid=1';
|
|
|
--error ER_TABLEACCESS_DENIED_ERROR
|
select group_concat(user,'@',host) from mysql.global_priv; |
|
|
create function f() returns text sql security invoker |
return (select group_concat(user,'@',host) from mysql.global_priv); |
|
|
create view v as select f(); |
|
|
select * from v; |
Reported by Ben Bidner (Automattic.com Security Team).