CVE-2026-25383

KiviCare – Clinic & Patient Management System (EHR) <= 3.6.16 - Reflected Cross-Site Scripting

mediumImproper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
6.1
CVSS Score
6.1
CVSS Score
medium
Severity
4.0.0
Patched in
4d
Time to patch

Description

The KiviCare – Clinic & Patient Management System (EHR) plugin for WordPress is vulnerable to Reflected Cross-Site Scripting in versions up to, and including, 3.6.16 due to insufficient input sanitization and output escaping. This makes it possible for unauthenticated attackers to inject arbitrary web scripts in pages that execute if they can successfully trick a user into performing an action such as clicking on a link.

CVSS Vector Breakdown

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Low
Confidentiality
Low
Integrity
None
Availability

Technical Details

Affected versions<=3.6.16
PublishedMarch 23, 2026
Last updatedMarch 26, 2026

What Changed in the Fix

Changes introduced in v4.0.0

Loading patch diff...

Source Code

WordPress.org SVN
Research Plan
Unverified

# Exploitation Research Plan: CVE-2026-25383 (KiviCare Reflected XSS) ## 1. Vulnerability Summary The **KiviCare – Clinic & Patient Management System (EHR)** plugin (versions <= 3.6.16) is vulnerable to **Reflected Cross-Site Scripting (XSS)**. The vulnerability exists because the plugin reflects u…

Show full research plan

Exploitation Research Plan: CVE-2026-25383 (KiviCare Reflected XSS)

1. Vulnerability Summary

The KiviCare – Clinic & Patient Management System (EHR) plugin (versions <= 3.6.16) is vulnerable to Reflected Cross-Site Scripting (XSS). The vulnerability exists because the plugin reflects user-supplied input from URL parameters into the page HTML without sufficient sanitization or output escaping. Specifically, parameters used for displaying status messages or error notifications on pages containing KiviCare shortcodes are likely candidates for this reflection.

2. Attack Vector Analysis

  • Endpoint: Any frontend page containing the KiviCare shortcodes, most notably the "Login/Register" page created during plugin activation.
  • Vulnerable Parameter: kc_msg (inferred based on plugin naming conventions) or error.
  • Authentication: Unauthenticated.
  • Attack Type: Reflected (GET-based).
  • Preconditions: The plugin must be active and a page containing a KiviCare shortcode (e.g., [kivicareRegisterLogin]) must be accessible.

3. Code Flow

  1. Entry Point: A user accesses a URL such as http://site.com/kivicare-login/?kc_msg=<payload>.
  2. Shortcode Execution: WordPress parses the page and triggers the callback for the [kivicareRegisterLogin] shortcode.
  3. Parameter Retrieval: The plugin's controller (likely an internal handler for shortcode views) retrieves the kc_msg parameter from the $_GET superglobal.
  4. Vulnerable Sink: The parameter value is echoed directly into the HTML response (often inside a notice or alert div) without being passed through escaping functions like esc_html() or wp_kses().
  5. Alternative Sink: The value is passed to a JavaScript variable via wp_localize_script() and subsequently rendered by the plugin's Vue.js frontend using a vulnerable directive (e.g., v-html).

4. Nonce Acquisition Strategy

Reflected XSS via a GET parameter typically occurs during the initial page load and does not usually require a nonce for the reflection itself. However, if the reflection is contained within an AJAX-based view system:

  1. Shortcode: [kivicareRegisterLogin]
  2. Page Creation: Use wp post list --post_type=page to find the slug of the page created by KCActivate::createShortcodePage().
  3. JS Variable: Check for wp_localize_script data. Common variables in KiviCare include kivicare_options or kc_nonces.
  4. Extraction:
    • browser_navigate("http://site.local/kivicare-login")
    • browser_eval("window.kivicare_options")

Note: For this specific Reflected XSS, the primary exploit target is the direct reflection in the GET request, which likely bypasses nonce requirements.

5. Exploitation Strategy

  1. Identify Target Page: Find the page containing the [kivicareRegisterLogin] shortcode.
  2. Payload Construction:
    • Basic: <script>alert(document.domain)</script>
    • Attribute Breakout: "><script>alert(document.cookie)</script>
    • Image-based: <img src=x onerror=alert(1)>
  3. HTTP Request:
    • Method: GET
    • URL: http://[target-site]/kivicare-login/?kc_msg=<URL_ENCODED_PAYLOAD>
    • Headers: Accept: text/html
  4. Tool: Use http_request to send the GET request and analyze the body for the reflected payload.

6. Test Data Setup

  1. Activate Plugin: wp plugin activate kivicare-clinic-management-system
  2. Verify Pages:
    • Run wp post list --post_type=page to ensure the "Kivicare Login" page exists.
    • If missing, create one: wp post create --post_type=page --post_title="Kivicare Login" --post_status=publish --post_content='[kivicareRegisterLogin]'
  3. Identify Slug: Note the slug (usually kivicare-login).

7. Expected Results

  • The HTTP response body will contain the literal payload string (e.g., <script>alert(document.domain)</script>) instead of an escaped version (e.g., &lt;script&gt;).
  • When viewed in a browser, the JavaScript payload will execute in the context of the user's session.

8. Verification Steps

  1. Manual Inspection: Search the response body of the http_request for the exact payload string.
  2. DOM Verification: Use browser_navigate to the malicious URL and check for an alert dialog or evidence of script execution.
    • browser_navigate("http://site.local/kivicare-login/?kc_msg=<payload>")
    • Check for execution side-effects (e.g., a global variable set by the payload).

9. Alternative Approaches

  • Parameter Variation: If kc_msg is not reflected, try error, message, status, or view.
  • Localization Reflection: Inspect the source of the page for wp_localize_script blocks. Look for parameters echoed into JSON objects:
    <script id="kc-main-js-extra">
    var kc_data = {"message": "[PAYLOAD]"};
    </script>
    
  • SVG Upload (if permissions allow): If the reflected XSS fails, check if the plugin allows unauthenticated users to upload files (e.g., via appointment attachments) and use an SVG with embedded XSS. (This is a different vulnerability type but a common fallback in EHR plugins).

Check if your site is affected.

Run a free security audit to detect vulnerable plugins, outdated versions, and misconfigurations.