Hi Robin & list,
-----Original Message-----
From: Robin H. Johnson
On Mon, Mar 24, 2003 at 09:37:00AM -0500, Marc Delisle wrote:
Well, after reading their answer, I guess we will
have to rely on
something else to set $is_superuser, like selecting records from
mysql.user.
Agreed. We will have to just follow how GRANT/REVOKE work and
build up the permissions ourselves. Or use SHOW GRANTS and some work.
Please avoid SHOW GRANTS. It's a little buggy in early 4.0 / 3.23
versions.
And the big problem is that we have to know the correct Hostname as it
appears in the user table.
e.g. if user foo(a)192.168.0.% logs on from 192.168.0.26 we would
intentionally build this query:
SHOW GRANTS FOR foo(a)192.168.0.26;
Unfortunally, this query would fail.
The only way to determine a user's privileges properly is to use the
`mysql` database. We should use the controluser for this purpose.
Alexander M. Turek
<alex(a)bugfixes.info>
+-----------------------------+
| The phpMyAdmin Project |
|
http://www.phpmyadmin.net |
| rabus(a)users.sourceforge.net |
+-----------------------------+
| [bugfixes.info] |
|
http://www.bugfixes.info |
| rabus(a)bugfixes.info |
+-----------------------------+