id: pi-hole-panel

info:
  name: Pi-hole Login Panel - Detect
  author: geeknik
  severity: info
  classification:
    cpe: cpe:2.3:a:pi-hole:pi-hole:*:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 5
    vendor: pi-hole
    product: pi-hole
    shodan-query: title:"Pi-hole"
  tags: tech,pihole,detect,discovery

http:
  - method: GET
    path:
      - "{{BaseURL}}"
      - "{{BaseURL}}/admin/index.php"
      - "{{BaseURL}}/admin/login.php"
      - "{{BaseURL}}/admin/index.php?login"
      - "{{BaseURL}}/index.php?login"

    host-redirects: true
    max-redirects: 2
    stop-at-first-match: true

    matchers-condition: or
    matchers:
      - type: word
        part: body
        words:
          - "Pi-hole"
          - "Web Interface"
          - "FTL"
        condition: and

      - type: word
        part: body
        words:
          - '<title>Pi-hole'
          - 'Pi-hole: Your black hole for Internet advertisements'
          - 'Pi-hole: A black hole for Internet advertisements'
          - '<pre>sudo pihole -a -p</pre>'
        condition: or
# digest: 490a0046304402200d437219493fa62acf9348ecf56a05b8846a10b6900be605179f92621dc1aa83022062e14d4d65e25b254b99f6aefcede8b79c7ed318ae3fb19a2a310dca4f1d5944:922c64590222798bb761d5b6d8e72950