Skip to content

Blind sql injection in smplredirectionsmanager PrestaShop module

Critical
jf-viguier published GHSA-84c9-xc73-8663 Jan 17, 2023

Package

smplredirectionsmanager (PrestaShop)

Affected versions

<1.1.19

Patched versions

1.1.19

Description

Impact

The module Redirections Manager (smplredirectionsmanager) from Smart Plugs contains a Blind SQL injection vulnerability up to version 1.1.19.
This module is for the PrestaShop e-commerce platform.

Patches

The release 1.1.19 fix the issue.

Workarounds

--- a/smplredirectionsmanager/classes/SmplTools.php
+++ b/smplredirectionsmanager/classes/SmplTools.php
@@ -104,10 +104,10 @@ class SmplTools
                     }
                 }
                 $contrainte_request_uri .= ($contrainte_request_uri ? ' OR' : '').' old_request_path="'.
-                    pSQL(preg_replace('#\?.*#', '', $smpl_relative_uri)).'?'.$str_querystring.'"';
+                    pSQL(preg_replace('#\?.*#', '', $smpl_relative_uri)).'?'.pSQL($str_querystring).'"';
                 foreach ($smpl_absolute_uris as $smpl_absolute_uri) {
                     $contrainte_request_uri .= ' OR old_request_path="'.
-                        pSQL(preg_replace('#\?.*#', '', $smpl_absolute_uri)).'?'.$str_querystring.'"';
+                        pSQL(preg_replace('#\?.*#', '', $smpl_absolute_uri)).'?'.pSQL($str_querystring).'"';
                 }
             }
         } else {

Links

Module on PrestaShop Addons
Security Advisory

Timeline

Date Action
2022-10-10 Issue discovered during a pentest
2022-10-11 Contact the author
2022-11-14 Fix published on addons PrestaShop marketplace
2023-01-12 Request CVE ID
2023-01-17 Publish this security advisory

Severity

Critical

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

CVE ID

No known CVE

Weaknesses

Credits