CVE-2026-48997: e107: Command Injection via shell expansion in ImageMagick resize destination path
e107 is a content management system (CMS). Versions 2.3.5 and earlier contain a command injection vulnerability in the ImageMagick resize destination path. In resizeimage(), the source path is escaped with escapeshellarg(), but the destination path is inserted inside raw double quotes in the convert command; in the submit-news upload flow, that destination filename includes the first six characters of user-controlled news title input. Because the title filter removes literal spaces but not tab characters, and shell expansions such as $(...) and backticks can survive into the quoted destination argument, /bin/sh -c may evaluate attacker-controlled input. Exploitation is possible only when all of the following non-default settings are enabled: resizemethod=ImageMagick, subnewsattach=1, uploadenabled=1, subnewsresize is numeric between 30 and 5000, and the attacker is a non-admin in classes permitted by both subnewsclass and uploadclass. This issue has been fixed in version 2.3.6.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
e107to a version that resolves this vulnerability.Fixed in 2.3.6 - Compensating control
Prevent exploitation by ensuring the upload/resize combination cannot be reached by untrusted users: ensure at least one of the following conditions is true -- resize_method is not set to 'ImageMagick'; subnews_attach is not set to '1'; upload_enabled is not set to '1'; subnews_resize is not a numeric value between 30 and 5000; or restrict classes permitted by subnews_class and upload_class so non-admin attackers cannot perform uploads. Alternatively, apply the 2.3.6 upgrade.
Event History
Frequently Asked Questions
What is the severity of CVE-2026-48997?
CVE-2026-48997 is classified as high severity with a score of 7.1.
How do I fix CVE-2026-48997?
To fix CVE-2026-48997, update e107 to version 2.3.6 or later.
What systems are affected by CVE-2026-48997?
CVE-2026-48997 affects e107 versions 2.3.5 and earlier.
What type of vulnerability is CVE-2026-48997?
CVE-2026-48997 is a command injection vulnerability.
What is the potential impact of CVE-2026-48997?
Exploitation of CVE-2026-48997 could allow an attacker to execute arbitrary commands on the server.