Users and privileges
Users and privileges opens from the Databases window (the node under a connection, or
Users and privileges… in its context menu) as a tab Users: <session> of that connection.
The header shows the server, where the list came from (source: mysql.user, …) and a badge:
read only (with the reason as tooltip), write allowed, or production: changes need
confirmation. MySQL 5.7, 8.x and 9.x, MariaDB 10.x and 11.x.

What is read
Section titled “What is read”All reading goes over the tab’s read-only connection; each statement is in the connection console.
| Statement | For |
|---|---|
SHOW PRIVILEGES |
Privilege names of this server (also MySQL dynamic privileges such as BACKUP_ADMIN). Only these names can be granted. When it fails, a documented static list is used (Privilege names: documented static list (SHOW PRIVILEGES failed)). |
SELECT * FROM mysql.user |
Accounts and their attributes, read by column name (the columns differ between 5.7, 8 and MariaDB). Password hashes never leave KryoDesk’s backend. |
mysql.global_priv (MariaDB 10.4+) |
Lock state, password lifetime and last change. |
mysql.role_edges, mysql.default_roles (MySQL 8+); mysql.roles_mapping (MariaDB) |
Granted roles, admin option, default roles. |
SHOW GRANTS FOR '<user>'@'<host>' |
Privileges of the picked account; the part after IDENTIFIED (a hash in MySQL 5.7 / MariaDB) is hidden. |
Without SELECT on mysql.* the list comes from information_schema.USER_PRIVILEGES, or only
CURRENT_USER(); each refused statement is shown with its server error code, SQLSTATE and message
(copy button).
The account view
Section titled “The account view”The list (filter field, New account = CREATE USER, + = New role = CREATE ROLE)
marks roles, locked accounts, expired passwords and the current account (you). For the picked
account: Plugin, Locked, Password (state, lifetime, last change), Limits / hour,
TLS, the raw SHOW GRANTS lines (click to expand, copy), and lines KryoDesk does not put in the
matrix (Not in the matrix (left as they are): PROXY, partial revokes, unknown lines).
| Part | What it edits |
|---|---|
| Roles | Granted roles with admin (WITH ADMIN OPTION) and default (SET DEFAULT ROLE); × revokes; Grant role… adds one. |
| Privileges | One row per level with a checkbox per privilege allowed on that level, grant option (WITH GRANT OPTION), all / none, × (revoke all on the level). No privileges (USAGE only). when empty. |
| Add a level | Global *.*, Database (name or pattern such as app\_%), Table, Column, Routine, then Add level. |
| Discard, Review SQL… | Drop the edits, or build the statements. |
| Edit account…, Rename…, Drop… | The account form, RENAME USER, DROP USER (MariaDB roles: DROP ROLE). |
Database names in privileges may be a pattern or a database that does not exist yet (normal in
GRANT), so they are not checked against the catalog; they are always in backticks. A _ or % in
a database name is a wildcard; the review warns about it.
Account form
Section titled “Account form”| Field | Values |
|---|---|
| User / Role, Host | Host pattern: % = any, 10.0.%, localhost |
| Authentication | server default (new) / unchanged (edit), or a plugin of this server version (list) |
| Password | none / unchanged, generate (copied after the change), type it |
| TLS | REQUIRE NONE, REQUIRE SSL, REQUIRE X509 (client certificate) |
| Limits | queries/h (MAX_QUERIES_PER_HOUR), updates/h, connections/h, concurrent (MAX_USER_CONNECTIONS); 0 = unlimited, empty = not set / unchanged |
| Password expiry | PASSWORD EXPIRE DEFAULT, expired now (set at next login), PASSWORD EXPIRE NEVER, every N days |
| Account | ACCOUNT LOCK, ACCOUNT UNLOCK |
ALTER USER contains only the changed options. Options the server version lacks are not offered.
How changes are built and sent
Section titled “How changes are built and sent”| Action | Statement |
|---|---|
| New account | CREATE USER with host pattern, plugin, password, REQUIRE SSL / X509, WITH MAX_… limits, ACCOUNT LOCK, PASSWORD EXPIRE … |
| Edit account | ALTER USER with the changed options |
| Rename / Drop | RENAME USER, DROP USER / DROP ROLE |
| New role | CREATE ROLE |
| Privileges | REVOKE first, then GRANT, only for the differences; WITH GRANT OPTION / REVOKE GRANT OPTION |
| Roles | GRANT <role> TO … (WITH ADMIN OPTION), REVOKE, SET DEFAULT ROLE |
Before building, the account’s SHOW GRANTS is read again; if the lines differ from the ones the
tab showed, the change stops (changed since they were loaded). ALL PRIVILEGES from SHOW GRANTS
is expanded to this server’s list for the level. Privilege names come only from SHOW PRIVILEGES
and the levels each one is allowed on; unknown names (dynamic MySQL 8 privileges, new MariaDB ones)
are global only.
Names: accounts as 'user'@'host', or `user`@`host` when the name contains ', \ or a
backtick; objects in backticks; control characters refused.
The review dialog shows the exact statements (Sent exactly as shown, one by one on a separate connection, stopping at the first error.), warnings and Copy SQL; Send runs them and shows per statement the result or the server error code, SQLSTATE and message. A prepared change expires after 5 minutes and is bound to the connection it was prepared on.
The statements go over a separate connection opened with the tab’s address, login and TLS
settings (SET NAMES utf8mb4 checked, autocommit = 1) and closed afterwards (COM_QUIT); the
tab’s connection stays read-only. FLUSH PRIVILEGES is not sent: account statements update the
server’s privilege cache themselves. Global privileges take effect for open sessions of that
account after they reconnect, database privileges after the next USE (the review notes it).
Behind ProxySQL the statements go where its query rules route them; its mysql_users table is not
changed.
Changes need Allow write on the session (read again at prepare and send, bound to the tab’s
host, port and login); quick-connect tabs are read-only. A tab opened with Connect as… another
login changes accounts as exactly that login (the separate connection reuses the tab’s login and
password; the console shows Opening a separate connection for the change as app (server account app@%) on db.example:3306 (Connect as)). Production adds the checkbox
Production server: I checked these statements. While KryoDesk is locked, prepare and send are
refused.
Passwords
Section titled “Passwords”- generate (macOS): 24 random characters from a CSPRNG (letters, digits, symbols; no quotes, backtick or backslash; every class present). After the statement succeeds it goes to the clipboard, marked as concealed and transient for clipboard managers, and is cleared after 60 s unless something else was copied meanwhile.
- type it: kept in the field only until the change is prepared, then cleared. An empty password
and a backslash are refused (the server reads a backslash differently under
NO_BACKSLASH_ESCAPES);'is doubled.
In the review, the console and server messages (for example 1064 near ‘…’) the password is
'***'; only the statement sent contains it. It is never written to a file. Without TLS, or with
a certificate you accepted without verification, the review warns that the statement with the
password crosses the network as sent; it also warns that a server with the general query log on
records it.