/

CVE-2026-18548

Severity:

HIGH RISK

(7.2)

Stored XSS (CWE-79) in Groundhogg WordPress Plugin for

CVE-2026-18548

Deferred

Vulnerability type

Category:

Stored Cross-Site Scripting

CWE:

CWE-79

Impact:

Client-Side Code Execution and Account Compromise

Severity:

HIGH RISK

(7.2)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Groundhogg for WordPress contains a stored cross-site scripting vulnerability in its ref parameter because input is not sufficiently sanitized and output is not safely escaped. An unauthenticated attacker may store arbitrary web script content that executes when a visitor or administrator accesses the affected page.

Groundhogg for WordPress contains a stored cross-site scripting vulnerability in its ref parameter because input is not sufficiently sanitized and output is not safely escaped. An unauthenticated attacker may store arbitrary web script content that executes when a visitor or administrator accesses the affected page.

Affected context

The vulnerability occurs in Groundhogg plugin deployments where the ref parameter is accepted, stored, and later rendered into a WordPress page without adequate context-aware escaping. Exploitation does not generally require authentication, but the injected content must be processed and displayed by the affected application before it can execute in a visitor's browser.

The vulnerability occurs in Groundhogg plugin deployments where the ref parameter is accepted, stored, and later rendered into a WordPress page without adequate context-aware escaping. Exploitation does not generally require authentication, but the injected content must be processed and displayed by the affected application before it can execute in a visitor's browser.

Exploit preconditions

  • Attack surface: Publicly reachable Groundhogg functionality that processes the ref parameter
  • Required access: Typically no authenticated account is required to submit the malicious input
  • Trigger point: A user or administrator views a page containing the stored value
  • Why exploitation is possible: Input validation, sanitization, and output encoding do not adequately prevent script content from being interpreted in the browser
  • Attack surface: Publicly reachable Groundhogg functionality that processes the ref parameter
  • Required access: Typically no authenticated account is required to submit the malicious input
  • Trigger point: A user or administrator views a page containing the stored value
  • Why exploitation is possible: Input validation, sanitization, and output encoding do not adequately prevent script content from being interpreted in the browser

Why this happens

The underlying bug is an unsafe data flow from an attacker-controlled request parameter into persistent application content. The value is stored or reused without sufficient sanitization and is later rendered without context-appropriate output escaping, allowing the browser to interpret attacker-supplied markup or script. This behavior maps to CWE-79: Improper Neutralization of Input During Web Page Generation, commonly known as cross-site scripting.

The underlying bug is an unsafe data flow from an attacker-controlled request parameter into persistent application content. The value is stored or reused without sufficient sanitization and is later rendered without context-appropriate output escaping, allowing the browser to interpret attacker-supplied markup or script. This behavior maps to CWE-79: Improper Neutralization of Input During Web Page Generation, commonly known as cross-site scripting.

Potential impact

  • Malicious scripts may execute in the browser of a page visitor
  • Session information or other accessible browser data could be exposed
  • Administrative actions could be performed through a compromised administrator session
  • Visitors may be redirected to phishing pages or shown altered content
  • Site reputation, user trust, and marketing data could be affected
  • Malicious scripts may execute in the browser of a page visitor
  • Session information or other accessible browser data could be exposed
  • Administrative actions could be performed through a compromised administrator session
  • Visitors may be redirected to phishing pages or shown altered content
  • Site reputation, user trust, and marketing data could be affected

General mitigation guidance

Mitigation generally focuses on breaking the path between untrusted input and executable browser content.

Common defensive patterns include:

  • Applying allowlist-based input validation appropriate to the parameter's expected format
  • Using context-aware output encoding at every rendering location
  • Treating stored request parameters as untrusted even after database storage
  • Avoiding direct insertion of dynamic values into HTML, script, or event-handler contexts
  • Applying least privilege to WordPress users and administrative sessions
  • Using browser security controls such as an appropriately restrictive Content Security Policy where practical

Mitigation generally focuses on breaking the path between untrusted input and executable browser content.

Common defensive patterns include:

  • Applying allowlist-based input validation appropriate to the parameter's expected format
  • Using context-aware output encoding at every rendering location
  • Treating stored request parameters as untrusted even after database storage
  • Avoiding direct insertion of dynamic values into HTML, script, or event-handler contexts
  • Applying least privilege to WordPress users and administrative sessions
  • Using browser security controls such as an appropriately restrictive Content Security Policy where practical

How teams detect issues like this

Organizations can detect similar issues through:

  • Static analysis for unsanitized request data flowing into HTML or script output
  • Code review checks for missing context-aware escaping in WordPress rendering functions
  • Dynamic testing of public parameters with benign marker values and browser-side execution monitoring
  • Monitoring stored content and rendered pages for unexpected markup or script elements
  • Policy enforcement requiring security-focused review for plugin code that handles user-controlled values
  • Automated application security and code review tools that identify common XSS data-flow patterns

Organizations can detect similar issues through:

  • Static analysis for unsanitized request data flowing into HTML or script output
  • Code review checks for missing context-aware escaping in WordPress rendering functions
  • Dynamic testing of public parameters with benign marker values and browser-side execution monitoring
  • Monitoring stored content and rendered pages for unexpected markup or script elements
  • Policy enforcement requiring security-focused review for plugin code that handles user-controlled values
  • Automated application security and code review tools that identify common XSS data-flow patterns

Sources

SourceLink
github.comgithub.com/groundhoggwp/groundhogg/commit/8a6fe60e751e
plugins.trac.wordpress.orgplugins.trac.wordpress.org/browser/groundhogg/tags/4.5.15/assets/js/admin/contacts/contact-editor.js#L848
wordfence.comwordfence.com/threat-intel/vulnerabilities/id/791ee926-edd9-4615-9a46-1d8836938fd9?source=cve

Frequently asked

questions

Yes. The described issue allows unauthenticated attackers to submit the affected input, although successful exploitation also requires the value to be stored and later rendered by the application.

Any visitor, editor, or administrator who loads a page containing the stored value may trigger the script in their browser. The consequences can be more serious when a privileged user views the page.

Validate and constrain the parameter to its intended format, then apply context-aware output escaping at every location where the value is rendered.

Treat all request and database-derived values as untrusted, use framework-provided escaping APIs correctly, perform data-flow security reviews, and test both public and authenticated rendering paths.

Yes. The described issue allows unauthenticated attackers to submit the affected input, although successful exploitation also requires the value to be stored and later rendered by the application.

Any visitor, editor, or administrator who loads a page containing the stored value may trigger the script in their browser. The consequences can be more serious when a privileged user views the page.

Validate and constrain the parameter to its intended format, then apply context-aware output escaping at every location where the value is rendered.

Treat all request and database-derived values as untrusted, use framework-provided escaping APIs correctly, perform data-flow security reviews, and test both public and authenticated rendering paths.

Find out what's already
exploitable in your codebase.