Skip to content
KitploitKITPLOIT
ToolsExploitsBlog
Log in
Submit
ToolsExploitsBlog
Submit

Hacking, PenTest, and Cybersecurity Tools for Your Security Arsenal!

Kitploit is a directory of hacking, cybersecurity, and pentesting tools. Discover the latest project updates to find vulnerabilities, analyze systems, automate testing, and strengthen your security.

FeedsContactPrivacy© 2026 Kitploit

Tool Directory

Categories

View all categories
Loading categories
phpmyadmin-auth-plugin-unquoted — phpMyAdmin 5.2.3 - High - Remote - SQLi - auth plugin identifier unquoted | Kitploit
Tools/GitHubGitHub/abraxas/phpmyadmin-auth-plugin-unquoted
Vulnerability ScannersVulnerability AnalysisExploitationWeb Application ExploitationWeb SecurityPenetration TestingDatabase Security
GitHub
abraxas/phpmyadmin-auth-plugin-unquoted

phpmyadmin-auth-plugin-unquoted

phpMyAdmin 5.2.3 - High - Remote - SQLi - auth plugin identifier unquoted

View Repository
3 days agoNot yet reviewed

Most Popular

View all →

Discover the most used tools by our community.

Explore all tools

Browse our collection of tools

View all tools →
Share

Abraxas Labs - phpmyadmin-auth-plugin-unquoted

abraxaslabs.tech  ·  github.com/abraxas  ·  @abraxas_null  ·  [email protected]  ·  phpmyadmin-auth-plugin-unquoted

phpmyadmin-auth-plugin-unquoted

Class: SQLi Reach: Remote

phpMyAdmin 5.2.3 (RELEASE_5_2_3 / 962857e) - phpMyAdmin

Change password is on by default. UserPassword.php copies POST authentication_plugin into ALTER USER ... IDENTIFIED WITH with no allowlist and no quoting. Username, host, and password in the same statement go through escapeString. On MySQL 8 the WITH clause is emitted when the posted plugin differs from the current one.

A signed-in phpMyAdmin user injects SQL into their own ALTER USER through the change-password form. Extra SQL in the plugin field is SQL, not a plugin name.

IDno CVE yet
ClassSQLi
ReachRemote (authenticated cookie login; change password on)
CWECWE-89
CVSSHigh: 8.1 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N
ProductphpMyAdmin
Affected5.2.3 tag RELEASE_5_2_3 (962857e4f63d42e38f11ff4d63f5e722018add76)
Authauthenticated cookie login. $cfg['ShowChgPassword'] default true. Auth type is not config
LicenseGNU Affero GPL v3.0
Lab127.0.0.1 only

What an attacker can do

A signed-in phpMyAdmin user can inject SQL into their own ALTER USER through the change-password form.

PrivilegeMethod / sinkRecon / integrity / availabilityLab-proven or inferred
Send extra SQL in IDENTIFIED WITHPOST index.php?route=/user-password with authentication_pluginIntegrity of the statement phpMyAdmin buildsLab-proven. Raw POST sha256_password /*PMA-AUTH-PLUGIN-UNQUOTED-WITNESS*/ appears unquoted in the SQL box
Have MySQL parse that extra SQL as SQLSame statement reaches mysqldIntegrity of the user connectionLab-proven. General log kept plugin sha256_password and dropped the comment. 1227 because this user has no CREATE USER
Extra clauses or extra accounts if the breakout parsesSame sink; stacked queries depend on the driverIntegrity of other accountsInferred. This lab does not run a second statement or create another account
Same concat on add/edit userPrivileges.php IDENTIFIED WITH / MariaDB VIAIntegrity of grantor-built statementsInferred sibling. Lab POST is change-password only

Closed on this path: unauthenticated use (cookie login required), config-auth (change password is hidden), RCE, GRANT-less plugin change succeeding on MySQL 8 (1227 without CREATE USER). Username, host, and password stay escaped. Own-password does not need GRANT; the leftover is the unquoted plugin field, not a free plugin swap.

Same pin: WebAuthn CustomServer leftover.

How I found it

I pinned phpmyadmin/phpmyadmin RELEASE_5_2_3. PMASA-2025-1/2/3 are already in 5.2.2. Change password still builds:

return 'ALTER USER \'' . $dbi->escapeString($username)
    . '\'@\'' . $dbi->escapeString($hostname)
    . '\' IDENTIFIED WITH ' . $authPlugin . ' BY '

$authPlugin is $_POST['authentication_plugin']. MySQL 5.7.37+ and 8.0 omit WITH unless the plugin changed. POST a different name and the clause comes back.

Wrong turns already recorded: treating MySQL 1227 as failure of the leftover (it is the proof extra SQL parsed); claiming a GRANT-less plugin change on MySQL 8; treating config-auth as in-scope; a reverse shell. Theatre.

Lab

python3 phpmyadmin-auth-plugin-unquoted-Abraxas-Labs.py
# or: cd lab && ./run.sh

Target only http://127.0.0.1:19260. Images phpmyadmin:5.2.3 and mysql:8.0. Compose project phpmyadmin-auth-plugin-unquoted. Stack tears down after the run.

Cookie login as appuser. POST /user-password with authentication_plugin=sha256_password /*PMA-AUTH-PLUGIN-UNQUOTED-WITNESS*/. PMA SQL query box: ALTER USER 'appuser'@'%' IDENTIFIED WITH sha256_password /*PMA-AUTH-PLUGIN-UNQUOTED-WITNESS*/ BY '***'. MySQL general log parses the comment and stores IDENTIFIED WITH 'sha256_password'. Username is quoted.

SUCCESS phpmyadmin-auth-plugin-unquoted how=live unquoted=yes escaped-user=yes plugin=sha256_password PMA-AUTH-PLUGIN-UNQUOTED-WITNESS

The fix

Allowlist plugin names from SHOW PLUGINS. Never interpolate POST into IDENTIFIED WITH, VIA, or plugin=.

References

  • github.com/phpmyadmin/phpmyadmin tag RELEASE_5_2_3 (962857e4f63d42e38f11ff4d63f5e722018add76)
  • libraries/classes/UserPassword.php
  • libraries/classes/Server/Privileges.php
  • Same pin: PMA-5.2.3-WebAuthn-2FA
  • CWE-89

License

GNU Affero GPL v3.0. See LICENSE. Loopback lab only. No warranty.

Download Tool