CVE-2017-18264: Phpmyadmin/phpmyadmin PhpMyAdmin Improper Privilege Management Vulnerability

CRITICAL
Advisory Identifier: GHSA-5868-g58j-vrj5
CVSS 9.8
CWE-269
Published
Advisory Summary

CVE-2017-18264 is a CRITICAL (CVSS 9.8) phpmyadmin improper privilege management vulnerability (CWE-269: Improper Privilege Management) affecting Phpmyadmin/phpmyadmin libraries in the Packagist ecosystem. The issue involves phpmyadmin improper privilege management. Remediation is available by upgrading affected packages to version 4.0.10.20, 4.7.0.

CVE-2017-18264 at a Glance

CVE Identifier CVE-2017-18264
GHSA Identifier GHSA-5868-g58j-vrj5
Severity CRITICAL
CVSS v3.1 Base Score 9.8
CWE Classification CWE-269: Improper Privilege Management
Affected Product Phpmyadmin/phpmyadmin
Package Ecosystem Packagist
Published Date
Last Updated

Security Impact

CVSS: 9.8

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2017-18264

To remediate this vulnerability, upgrade all affected Phpmyadmin/phpmyadmin dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

phpmyadmin/phpmyadmin fixed: 4.0.10.20
Upgrade phpmyadmin/phpmyadmin to 4.0.10.20
phpmyadmin/phpmyadmin fixed: 4.7.0
Upgrade phpmyadmin/phpmyadmin to 4.7.0
phpmyadmin/phpmyadmin fixed: Latest secure release
Upgrade phpmyadmin/phpmyadmin to Latest secure release
phpmyadmin/phpmyadmin fixed: Latest secure release
Upgrade phpmyadmin/phpmyadmin to Latest secure release
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for phpmyadmin/phpmyadmin

How to Check if You Are Affected

To determine whether your application is affected by CVE-2017-18264, inspect your project dependencies for Phpmyadmin/phpmyadmin:

inspect dependencies for phpmyadmin/phpmyadmin

Analyze the terminal output to locate any version of Phpmyadmin/phpmyadmin in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 4.0.10.20), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-269: Improper Privilege Management, where the product does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor. In Phpmyadmin/phpmyadmin, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

An issue was discovered in libraries/common.inc.php in phpMyAdmin 4.0 before 4.0.10.20, 4.4.x, 4.6.x, and 4.7.0 prereleases. The restrictions caused by $cfg['Servers'][$i]['AllowNoPassword'] = false are bypassed under certain PHP versions (e.g., version 5). This can allow the login of users who have no password set even if the administrator has set $cfg['Servers'][$i]['AllowNoPassword'] to false (which is also the default). This occurs because some implementations of the PHP substr function return false when given '' as the first argument.

CVE-2017-18264 Affected Phpmyadmin/phpmyadmin Versions

4 component(s)
Fixed Versions:
4.0.10.204.7.0
Product / Package Ecosystem Affected Versions Fixed Version
phpmyadmin/phpmyadmin
Packagist
≥ 4.0
< 4.0.10.20
4.0.10.20
phpmyadmin/phpmyadmin
Packagist
≥ 4.7.0-beta1
< 4.7.0
4.7.0
phpmyadmin/phpmyadmin
Packagist
≥ 4.4.0
≤ 4.4.15.10
phpmyadmin/phpmyadmin
Packagist
≥ 4.6.0
≤ 4.6.6

References

Frequently Asked Questions

What is CVE-2017-18264?
CVE-2017-18264 is a security vulnerability in Phpmyadmin/phpmyadmin involving phpMyAdmin Improper Privilege Management under CWE-269: Improper Privilege Management.
Which Phpmyadmin/phpmyadmin versions are affected?
Affected versions include releases prior to 4.0.10.20, 4.7.0 across affected packages: phpmyadmin/phpmyadmin.
What version fixes CVE-2017-18264?
Upgrading to 4.0.10.20, 4.7.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is phpmyadmin/phpmyadmin affected?
Yes, phpmyadmin/phpmyadmin is affected in releases prior to 4.0.10.20, 4.7.0, Latest secure release. Upgrade your dependency to 4.0.10.20, 4.7.0, Latest secure release or later.
What is the CVSS score of CVE-2017-18264?
CVE-2017-18264 has a CVSS v3.1 base score of 9.8 (CRITICAL) with vector string CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2017-18264?
CVE-2017-18264 is classified under CWE-269: Improper Privilege Management (The product does not properly assign, modify, track, or check privileges for an actor, creating an unintended sphere of control for that actor.).
How can I check Packagist dependencies for CVE-2017-18264?
Run the dependency tree command: 'inspect dependencies for phpmyadmin/phpmyadmin'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-5868-g58j-vrj5",
  "modified" : "2024-04-24T18:14:02Z",
  "published" : "2022-05-13T01:44:38Z",
  "aliases" : [ "CVE-2017-18264" ],
  "summary" : "phpMyAdmin Improper Privilege Management",
  "details" : "An issue was discovered in libraries/common.inc.php in phpMyAdmin 4.0 before 4.0.10.20, 4.4.x, 4.6.x, and 4.7.0 prereleases. The restrictions caused by $cfg['Servers'][$i]['AllowNoPassword'] = false are bypassed under certain PHP versions (e.g., version 5). This can allow the login of users who have no password set even if the administrator has set $cfg['Servers'][$i]['AllowNoPassword'] to false (which is also the default). This occurs because some implementations of the PHP substr function return false when given '' as the first argument.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "phpmyadmin/phpmyadmin"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.0"
      }, {
        "fixed" : "4.0.10.20"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "phpmyadmin/phpmyadmin"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.7.0-beta1"
      }, {
        "fixed" : "4.7.0"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "phpmyadmin/phpmyadmin"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.4.0"
      }, {
        "last_affected" : "4.4.15.10"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Packagist",
      "name" : "phpmyadmin/phpmyadmin"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "4.6.0"
      }, {
        "last_affected" : "4.6.6"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2017-18264"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/phpmyadmin/composer"
  }, {
    "type" : "WEB",
    "url" : "https://lists.debian.org/debian-lts-announce/2018/07/msg00006.html"
  }, {
    "type" : "WEB",
    "url" : "https://www.phpmyadmin.net/security/PMASA-2017-8"
  }, {
    "type" : "WEB",
    "url" : "http://www.securityfocus.com/bid/97211"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-269" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-04-24T18:14:02Z",
    "nvd_published_at" : "2018-05-01T17:29:00Z"
  }
}