Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2025-2540: CWE-79 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in nayon46 Awesome Wp Image Gallery

0
Medium
VulnerabilityCVE-2025-2540cvecve-2025-2540cwe-79
Published: Thu Jul 03 2025 (07/03/2025, 11:19:50 UTC)
Source: CVE Database V5
Vendor/Project: nayon46
Product: Awesome Wp Image Gallery

Description

Multiple plugins for WordPress are vulnerable to Stored Cross-Site Scripting via the plugin's bundled prettyPhoto library (version 3.1.6) in various versions due to insufficient input sanitization and output escaping on user supplied attributes. This makes it possible for authenticated attackers, with contributor-level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses an injected page.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 02/27/2026, 12:56:39 UTC

Technical Analysis

CVE-2025-2540 is a stored cross-site scripting (XSS) vulnerability identified in the nayon46 Awesome Wp Image Gallery WordPress plugin, which bundles the prettyPhoto library version 3.1.6. The vulnerability stems from improper neutralization of input during web page generation (CWE-79), specifically due to insufficient sanitization and output escaping of user-supplied attributes. Authenticated attackers with contributor-level or higher privileges can exploit this flaw by injecting arbitrary JavaScript payloads into pages managed by the plugin. These malicious scripts are stored persistently and executed in the context of any user who accesses the infected page, potentially compromising user sessions, stealing cookies, or performing unauthorized actions on behalf of users. The vulnerability has a CVSS 3.1 base score of 6.4, reflecting a medium severity with network attack vector, low attack complexity, and requiring privileges but no user interaction. The scope is changed (S:C), meaning the vulnerability affects resources beyond the attacker’s privileges. Although no known exploits have been reported in the wild, the widespread use of WordPress and the plugin increases the risk of future exploitation. The vulnerability affects all versions of the plugin, and no official patches have been linked yet. The issue was reserved in March 2025 and published in July 2025 by Wordfence. This vulnerability highlights the risks of third-party plugin dependencies and the importance of secure coding practices in input handling.

Potential Impact

The impact of CVE-2025-2540 can be significant for organizations running WordPress sites with the vulnerable Awesome Wp Image Gallery plugin. Successful exploitation allows attackers with contributor-level access to inject persistent malicious scripts, which execute in the browsers of any users visiting the compromised pages. This can lead to session hijacking, credential theft, unauthorized actions performed on behalf of users, defacement, or distribution of malware. Since the attack requires authenticated access, insider threats or compromised contributor accounts pose a direct risk. The vulnerability undermines the confidentiality and integrity of user data and site content but does not affect availability. Organizations relying on this plugin for image gallery functionality may face reputational damage, data breaches, and potential regulatory consequences if user data is compromised. The medium CVSS score reflects moderate risk, but the broad scope and ease of exploitation by authenticated users make it a notable threat, especially for high-traffic or sensitive websites.

Mitigation Recommendations

To mitigate CVE-2025-2540, organizations should take the following specific actions: 1) Immediately audit WordPress sites for the presence of the Awesome Wp Image Gallery plugin and identify all contributor-level or higher users. 2) Restrict contributor privileges to trusted users only and review user roles to minimize unnecessary elevated access. 3) Implement web application firewalls (WAFs) with custom rules to detect and block suspicious script injection patterns related to prettyPhoto or the plugin. 4) Apply strict input validation and output encoding on all user-supplied data within the plugin’s scope, if custom development is possible. 5) Monitor logs and user activity for unusual behavior indicative of exploitation attempts. 6) Stay alert for official patches or updates from the plugin vendor and apply them promptly once available. 7) Consider temporarily disabling or replacing the plugin with a secure alternative until a fix is released. 8) Educate content contributors on secure content practices and the risks of injecting untrusted code. These targeted steps go beyond generic advice by focusing on access control, monitoring, and proactive plugin management.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.1
Assigner Short Name
Wordfence
Date Reserved
2025-03-19T22:12:17.253Z
Cvss Version
3.1
State
PUBLISHED

Threat ID: 68666bf36f40f0eb72964d6a

Added to database: 7/3/2025, 11:39:31 AM

Last enriched: 2/27/2026, 12:56:39 PM

Last updated: 3/24/2026, 3:55:54 AM

Views: 115

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses