CVE-2026-4020: A vulnerability in the Gravity SMTP WordPress plugin exposes site secrets

A serious vulnerability in the Gravity SMTP plugin for WordPress exposes the complete system report of sites using it without the need for authentication, including email credentials and API keys. Identified as CVE-2026-4020 and rated 7.5 on the CVSS scale, this flaw has been actively exploited since May 27. CrowdSec has reported 412 unique attacking IP addresses within five days of the vulnerability’s discovery. A patch is available in version 2.1.5.

An unauthenticated visitor can retrieve approximately 365 kilobytes of configuration data from a WordPress site equipped with the Gravity SMTP plugin, developed by RocketGenius. A simple request to one of the REST interface endpoints returns a detailed system report, including PHP and web server versions, a list of loaded extensions, the version of WordPress and the active theme, installed plugins, database metadata, and crucially, the plugin’s configuration values, which may encompass SMTP credentials, SendGrid or Mailgun API keys, and email authentication DKIM tokens.

This vulnerability affects all plugin versions up to and including 2.1.4. Published on March 31, 2026, CVE-2026-4020 highlights the risk of sensitive information disclosure. CrowdSec, which monitors its exploitation, deployed its detection capability on May 22, and observed the first real-world exploit on May 27. As of June 1, the observed activity transitioned into background noise, indicating its integration into automated attack routines sweeping across WordPress sites.

Unprotected REST Endpoint

The issue originates from a REST interface endpoint that is exposed without access controls. In the affected versions, the address /wp-json/gravitysmtp/v1/tests/mock-data?page=gravitysmtp-settings can be queried by any unauthenticated visitor, as the permission check consistently returns a positive value. This request triggers the assembly and return of a system report formatted in JSON, initially designed as a diagnostic tool for administrators.

The nature of the plugin exacerbates the scope of the data breach. As a messaging management tool, it occupies a pivotal position within a WordPress installation. It interfaces with external services and is configured with detailed access credentials, tokens, and environmental settings. When a vulnerability exposes such data, an attacker gains not only the knowledge of the plugin’s existence but also a comprehensive map of the infrastructure, configured secrets, and software components that may harbor additional exploitable vulnerabilities.

Widespread Exploitation, with France Leading

The exploitation has entered into large-scale automation. Between May 27 and June 1, CrowdSec cataloged 412 distinct attacking IP addresses, with an increase in exploitation pressure week-over-week. The countries seeing the highest levels of hostile activity were France, the Netherlands, and the U.S., a distribution consistent with the use of distributed cloud and hosting infrastructures rather than a targeted campaign.

The profile of the victims confirms an opportunistic logic. The majority of the observed activity targets e-commerce environments, accounting for 55%, followed by small businesses and home office deployments at 39%. These targets align with the attack traffic profile for WordPress, which favors scale, monetization potential, and delayed patching. The prevailing objective reported by CrowdSec is not data theft per se, but rather the takeover of infrastructure, accounting for 83% of observed intentions. The exposed system report serves as reconnaissance for more extensive compromise.

This vulnerability underscores a recurring exposure in the WordPress ecosystem, where the security of a site relies heavily on the chain of third-party extensions it utilizes. A messaging plugin, inherently connected to external services and holding access credentials, presents disproportionate value compared to its apparent function. For technical teams operating WordPress in production, maintaining an inventory of installed extensions and their patch levels is essential for reducing the attack surface, just as crucial as updating the core application. The rapid shift of this flaw to mass exploitation serves as a stark reminder that the timeline between the disclosure of a vulnerability and its industrial application can now be measured in days.

Update to Version 2.1.5 Immediately

Updating to version 2.1.5 or higher is imperative to address the vulnerability and should be the top priority for any exposed site on the internet. Security administrators who cannot implement the patch immediately should assume that the secrets the plugin handles are potentially compromised: rotating SMTP credentials, API keys for email vendors, and DKIM tokens is essential alongside the update, as a delayed patch leaves breached credentials intact.

In absence of an immediate fix, introducing a protective layer in front of exposed WordPress sites can help detect and block hostile probing before it escalates into a compromise. The exposure window is critical: the first real-world exploit occurred just five days after the detection release, and the activity integrated into current automation within less than a week. For e-commerce sites, where leaking email keys may lead to impersonation and fraud, the speed of response directly affects the extent of potential damage.

Scroll to Top