A WordPress anti-spam plugin with over 60,000 installations patched a PHP Item injection vulnerability that arose from incorrect sanitization of inputs, subsequently enabling base64 encoded user input.
Unauthenticated PHP Item Injection
A vulnerability was found in the popular Stop Spammers Security|Block Spam Users, Remarks, Forms WordPress plugin.
The function of the plugin is to stop spam in remarks, types, and sign-up registrations. It can stop spam bots and has the capability for users to input IP addresses to obstruct.
It is a required practice for any WordPress plugin or form that accepts a user input to only enable specific inputs, like text, images, email addresses, whatever input is expected.
Unexpected inputs need to be strained. That filtering process that stays out unwanted inputs is called sanitization.
For example, a contact type must have a function that inspects what is submitted and block (sanitize) anything that is not text.
The vulnerability discovered in the anti-spam plugin permitted encoded input (base64 encoded) which can then trigger a kind of vulnerability called a PHP Object injection vulnerability.
The description of the vulnerability released on the WPScan website explains the problem as:
“The plugin passes base64 encoded user input to the unserialize() PHP function when CAPTCHA are used as second obstacle, which could result in PHP Item injection if a plugin installed on the blog site has a suitable device chain …”
The category of the vulnerability is Insecure Deserialization.
The non-profit Open Web Application Security Task (OWASP) describes the possible effect of these kinds of vulnerabilities as serious, which may or might not hold true particular to this vulnerability.
The description at OWASP:
“The effect of deserialization defects can not be overstated. These defects can cause remote code execution attacks, one of the most severe attacks possible.The service impact depends upon the security requirements of the application and information. “But OWASP also keeps in mind that exploiting this sort of vulnerability tends to be tough:”Exploitation of deserialization is somewhat tough,
as off the rack exploits hardly ever work without modifications or tweaks to the underlying exploit code.”The vulnerability in the Stop Spammers Security WordPress
plugin was fixed in variation 2022.6 The official Stop Spammers Security changelog (a description with dates of various updates)notes the fix as an improvement for security. Users of the Stop Spam Security plugin need to think about updating to the most recent
variation in order to avoid a hacker from making use of the plugin. Read the main notice at the United States Government National Vulnerability Database
: CVE-2022-4120 Information Check out the WPScan publication of details connected to this vulnerability:
Stop Spammers Security