Miggo Logo

CVE-2016-5731: phpMyAdmin Cross-site scripting (XSS) vulnerability

6.1

CVSS Score
3.0

Basic Information

EPSS Score
0.61409%
Published
5/14/2022
Updated
4/24/2024
KEV Status
No
Technology
TechnologyPHP

Technical Details

CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
phpmyadmin/phpmyadmincomposer>= 4.0, < 4.0.10.164.0.10.16
phpmyadmin/phpmyadmincomposer>= 4.4, < 4.4.15.74.4.15.7
phpmyadmin/phpmyadmincomposer>= 4.6, < 4.6.34.6.3

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability arises from unhandled exceptions when constructing the OpenID_Message object in examples/openid.php. Before the patch, the code did not catch exceptions thrown during the creation of OpenID_Message, leading to PHP's default error handling. If the server had html_errors disabled, unescaped error messages containing user-controlled input (from $queryString) could be displayed, enabling XSS. However, the vulnerability is not tied to a specific function in phpMyAdmin's code but rather to the procedural flow lacking proper exception handling. The existing error handlers in catch blocks used htmlspecialchars correctly, but the uncaught exception path in the main script was the root issue. Thus, no specific functions in phpMyAdmin's code are identified as vulnerable with high confidence.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

*ross-sit* s*riptin* (XSS) vuln*r**ility in *x*mpl*s/op*ni*.p*p in p*pMy**min *.*.x ***or* *.*.**.**, *.*.x ***or* *.*.**.*, *n* *.*.x ***or* *.*.* *llows r*mot* *tt**k*rs to inj**t *r*itr*ry w** s*ript or *TML vi* v**tors involvin* *n Op*nI* *rror m

Reasoning

T** vuln*r**ility *ris*s *rom un**n*l** *x**ptions w**n *onstru*tin* t** Op*nI*_M*ss*** o*j**t in *x*mpl*s/op*ni*.p*p. ***or* t** p*t**, t** *o** *i* not **t** *x**ptions t*rown *urin* t** *r**tion o* Op*nI*_M*ss***, l***in* to P*P's ****ult *rror **