Exploit database

Vulnerability

CVE-2019-12799

Vulnerability details

Score
6.5
Severity
medium

CVSS 3.0 · mitre

Vector string

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

Description

In createInstanceFromNamedArguments in Shopware through 5.6.x, a crafted web request can trigger a PHP object instantiation vulnerability, which can result in an arbitrary deserialization if the right class is instantiated. An attacker can leverage this deserialization to achieve remote code execution. NOTE: this issue is a bypass for a CVE-2017-18357 whitelist patch.

CVE Program

Exploit source choices

1 source
Shopware createInstanceFromNamedArguments PHP Object Instantiation RCE
MSF-multi--http--shopware_createinstancefromnamedarguments_rceMetasploitPHP / remotePreferred

This module exploits a php object instantiation vulnerability that can lead to RCE in Shopware. An authenticated backend user could exploit the vulnerability. The vulnerability exists in the createInstanceFromNamedArguments function, where the code insufficiently performs whitelist check which can be bypassed to trigger an object injection. An attacker can leverage this to deserialize an arbitrary payload and write a webshell to the target system, resulting in remote code execution. Tested on Shopware git branches 5.6, 5.5, 5.4, 5.3.

2019-05-09shopware_createinstancefromnamedarguments_rce.rb