id: powerbi-report-server-detect

info:
  name: PowerBI Report Server - Detect
  author: righettod
  severity: info
  description: |
    PowerBI Report Server was detected.
  reference:
    - https://www.microsoft.com/en-us/power-platform/products/power-bi/report-server
  metadata:
    max-request: 1
    verified: true
    shodan-query: http.html:"report server web portal"
  tags: panel,powerbi,detect,discovery

http:
  - method: GET
    path:
      - "{{BaseURL}}/reports/api/v2.0/System"
      - "{{BaseURL}}/reports/browse"

    stop-at-first-match: true
    redirects: true
    max-redirects: 2
    matchers:
      - type: dsl
        dsl:
          - 'status_code == 200'
          - 'contains_any(to_lower(body), "power bi report server", "powerbireportserver", "<title>report server web portal</title>")'
        condition: and

    extractors:
      - type: json
        part: body
        name: version
        json:
          - '.ProductVersion'
# digest: 490a0046304402206c5c48064372c818524de6a1ca99d133b0ebd5b6deda5903a10ca42640db8adb0220158c856434e5ec8eaead0154eedad3312bfe202a10ed6794ff519bbdbe6b14c0:922c64590222798bb761d5b6d8e72950