Concrete5 <= 5.7.3.1 (sendmail) Remote Code Execution Vulnerability
The registration settings page stored the notification email value without checking it was a valid email address, only passing it through a generic string sanitiser. An attacker could save a crafted value that later reached the sendmail command, allowing remote code execution.
karmainsecurity.com
Published on karmainsecurity.com
The vulnerable code is located in /concrete/controllers/singlepage/dashboard/system/registration/open.php:
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the notification email setting was validated only with a generic string sanitiser rather than an email-format check, so shell metacharacters survived into the value passed to sendmail.
What the attacker needed
Access to registration settings page
The fix
The notification email value should be validated as a proper email address before being saved, rather than relying on a generic string sanitiser.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
A settings page lets an administrator set an email address for registration notifications. The code cleaned the text a little but never checked it was actually an email address, so special characters could be saved. Later, when the site used that saved value to send mail, those characters could be interpreted as extra commands by the mail program, letting an attacker run their own commands on the server.
What is RCE?
Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.