Security Flaw in WP-Members Plugin Leads to Script Injection

Share This Post

Attackers could exploit a high-severity cross-site Scripting (XSS) vulnerability in the WP-Members Membership WordPress plugin to inject arbitrary scripts into web pages, according to an advisory from security firm Defiant.

The bug, tracked as CVE-2024-1852, is the result of insufficient input sanitization and output escaping, allowing an attacker to create accounts that have a malicious script stored as the value of the user’s IP address.

An attacker could use WP-Members Membership’s user registration functionality to fill and submit a registration form, then intercept the registration request using a proxy, and modify it to contain an X-Forwarded-For header with a malicious payload enclosed in script tags, Defiant’s Wordfence research team said.

The issue is that, if an X-Forwarded-For header is present in the request, the plugin uses its value to store the IP address of any user relying on the registration form.

“Due to the fact that HTTP headers can be manipulated, and the input was not sanitized, a user could supply any value including a malicious web script that will be stored as the user’s IP,” according to the alert.

The malicious script is stored in the user’s profile and, if an administrator edits or views the user account, the payload will be included in the generated source code when the page loads.

“It is important to understand that this malicious code will be executed in the context of an administrator’s browser session and can be used to create malicious user accounts, redirect site visitors to other malicious sites and perform other malicious actions,” Wordfence added.

WP-Members Membership version patches the vulnerability, after a partial fix was included in version Users are advised to update their installations as soon as possible.

Advertisement. Scroll to continue reading.

With more than 60,000 active installations, WP-Members is a user membership plugin that allows site owners to easily set up and manage user registration, logins, and profiles, set restrictions, and more.

Related: 39,000 Websites Infected in ‘Sign1’ Malware Campaign

Related: Discontinued Plugins Expose WordPress Sites to Takeover

Related: Ultimate Member Plugin Flaw Exposes 100,000 WordPress Sites

This post was originally published on this site

More Articles


Navigating SEC Regulations In Cybersecurity And Incident Response

Free video resource for cybersecurity professionals. As 2024 approaches, we all know how vital it is to keep up to date with regulatory changes that affect our work. We get it – it’s a lot to juggle, especially when you’re in the trenches working on an investigation, handling, and responding to incidents.


BFU – Seeing is Believing

Oh no, the device is in BFU. This is the common reaction; a device needs extracting, and you find it in a BFU state. Often, there’s an assumption that a BFU extraction will only acquire basic information, but that isn’t always the case.