Magento 2.1.x < 2.1.17 / 2.2.x < 2.2.8 / 2.3.x < 2.3.1 SQL Injection

critical Web Application Scanning Plugin ID 98531



Magento 2.1.x < 2.1.17 / 2.2.x < 2.2.8 / 2.3.x < 2.3.1 SQL Injection


The Magento application running on the remote web server is affected by a SQL injection vulnerability due to failing to properly sanitize the user-supplied 'from' and 'to' inputs to the 'prepareSqlCondition' function of the '\Magento\Framework\DB\Adapter\Pdo\Mysql' class. An unauthenticated, remote attacker can exploit this to execute arbitrary SQL statements against the back-end database, leading to the execution of arbitrary code, manipulation of data, or disclosure of sensitive information.

Note: This has been detected using an active check and should be remediated immediately.


Apply the appropriate patch according to the vendor advisory.

See Also

Plugin Details

Severity: Critical

ID: 98531

Type: remote

Published: 4/10/2019

Updated: 9/7/2021

Scan Template: pci, api, scan

Risk Information


Risk Factor: High

Score: 7.4


Risk Factor: High

Base Score: 7.5

Vector: CVSS2#AV:N/AC:L/Au:N/C:P/I:P/A:P

CVSS Score Source: CVE-2019-7139


Risk Factor: Critical

Base Score: 9.8

Vector: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

CVSS Score Source: CVE-2019-7139

Vulnerability Information

CPE: cpe:2.3:a:magento:magento:*:*:*:*:*:*:*:*

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 3/26/2019

Vulnerability Publication Date: 3/26/2019

Reference Information

CVE: CVE-2019-7139