mirror of
https://github.com/MariaDB/server.git
synced 2026-10-23 18:49:29 +03:00
The "is it my own thread" check compared the login user name (Security_context::user) and ignored the host, so u1@localhost could see and kill threads of u1@'127.0.0.1'. Compare the authenticated account instead: * all comparisons are done in sctx->is_priv_user() now * change user_matches() to priv_user_matches(), which uses is_priv_user() * use it in KILL, KILL USER, SHOW PROCESSLIST, I_S.PROCESSLIST, COM_PROCESS_INFO and SHOW EXPLAIN/ANALYZE FOR. * all the remaining places use is_priv_user() directly instead of doing strcmp: SHOW GRANTS, SHOW CREATE PROCEDURE, I_S.VIEWS, the DEFINER clause, optimizer trace and change_security_context(). Assisted-by: Claude:claude-5-opus
9.6 KiB
9.6 KiB