CVE-2026-4300
Received Received - Intake
Stored XSS in Robo Gallery WordPress Plugin Allows Script Injection

Publication date: 2026-04-08

Last updated on: 2026-04-08

Assigner: Wordfence

Description
The Robo Gallery plugin for WordPress is vulnerable to Stored Cross-Site Scripting via the 'Loading Label' setting in all versions up to, and including, 5.1.3. The plugin uses a custom `|***...***|` marker pattern in its `fixJsFunction()` method to embed raw JavaScript function references within JSON-encoded configuration objects. When a gallery's options are rendered on the frontend, `json_encode()` wraps all string values in double quotes. The `fixJsFunction()` method then strips the `"|***` and `***|"` sequences, effectively converting a JSON string value into raw JavaScript code. The Loading Label field (stored as `rbs_gallery_LoadingWord` post_meta) is an `rbstext` type field that is sanitized with `sanitize_text_field()` on save. While this strips HTML tags, it does not strip the `|***...***|` markers since they contain no HTML. When a user inputs `|***alert(document.domain)***|`, the value passes through sanitization intact, is stored in post_meta, and is later retrieved and output within an inline `<script>` tag via `renderMainBlock()` with the quote markers stripped β€” resulting in arbitrary JavaScript execution. The gallery post type uses `capability_type => 'post'`, allowing Author-level users to create galleries. This makes it possible for authenticated attackers, with Author-level access and above, to inject arbitrary web scripts in pages that will execute whenever a user accesses a page containing the gallery shortcode.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-04-08
Last Modified
2026-04-08
Generated
2026-05-07
AI Q&A
2026-04-08
EPSS Evaluated
2026-05-05
NVD
EUVD
Affected Vendors & Products
Showing 1 associated CPE
Vendor Product Version / Range
robo_gallery robo_gallery to 5.1.3 (inc)
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-79 The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?

The Robo Gallery plugin for WordPress has a Stored Cross-Site Scripting (XSS) vulnerability in its 'Loading Label' setting in all versions up to and including 5.1.3.

The plugin uses a custom marker pattern `|***...***|` in its `fixJsFunction()` method to embed raw JavaScript function references inside JSON-encoded configuration objects. When the gallery options are rendered on the frontend, the JSON strings are wrapped in quotes, but the `fixJsFunction()` method strips these quote markers, turning the string into executable JavaScript code.

The 'Loading Label' field is sanitized with `sanitize_text_field()` which removes HTML tags but does not remove the `|***...***|` markers. This allows an attacker with Author-level access or higher to input malicious JavaScript code inside these markers, which is stored and later executed in the browser when a user views the gallery.


How can this vulnerability impact me? :

This vulnerability allows authenticated users with Author-level permissions or higher to inject arbitrary JavaScript code into pages containing the gallery shortcode.

As a result, any visitor to those pages could have malicious scripts executed in their browsers, potentially leading to theft of cookies, session hijacking, defacement, or other malicious actions.

Because the vulnerability is stored (persistent), the malicious code remains active until removed, affecting all users who visit the affected pages.


How can this vulnerability be detected on my network or system? Can you suggest some commands?

This vulnerability involves the Robo Gallery WordPress plugin storing and rendering malicious JavaScript via the 'Loading Label' setting. Detection involves checking for the presence of the plugin and inspecting the 'rbs_gallery_LoadingWord' post_meta field for suspicious patterns.

  • Check if the Robo Gallery plugin is installed and its version is 5.1.3 or below.
  • Search the WordPress database for the 'rbs_gallery_LoadingWord' meta key containing the marker pattern '|***...***|', which indicates potential exploitation.
  • Example MySQL command to find suspicious entries: SELECT post_id, meta_value FROM wp_postmeta WHERE meta_key = 'rbs_gallery_LoadingWord' AND meta_value LIKE '%|***%***|%';
  • Review pages or posts containing the gallery shortcode for unexpected inline scripts or JavaScript execution.

What immediate steps should I take to mitigate this vulnerability?

To mitigate this vulnerability, immediate actions should focus on preventing exploitation and removing any malicious code.

  • Update the Robo Gallery plugin to a version later than 5.1.3 where this vulnerability is fixed.
  • Temporarily disable or remove the Robo Gallery plugin if an update is not immediately available.
  • Audit and clean the 'rbs_gallery_LoadingWord' post_meta entries to remove any values containing the '|***...***|' markers.
  • Restrict Author-level user permissions to prevent unauthorized creation or modification of galleries until the issue is resolved.
  • Monitor your site for suspicious JavaScript execution and unauthorized content injections.

How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:

The vulnerability allows authenticated users with Author-level access to inject arbitrary JavaScript code into pages containing the gallery shortcode. This can lead to stored cross-site scripting (XSS) attacks, potentially exposing user data or session information to attackers.

Such unauthorized script execution can compromise the confidentiality and integrity of user data, which may impact compliance with data protection regulations like GDPR and HIPAA that require safeguarding personal and sensitive information against unauthorized access or disclosure.

However, the provided information does not explicitly detail the direct compliance implications or specific regulatory impacts of this vulnerability.


Ask Our AI Assistant
Need more information? Ask your question to get an AI reply (Powered by our expertise)
0/70
EPSS Chart