id: redfish-api

info:
  name: Redfish API - Detect
  author: righettod
  severity: info
  description: |
    Redfish API was detected.
  reference:
    - https://en.wikipedia.org/wiki/Redfish_(specification)
    - https://www.dmtf.org/standards/redfish
  metadata:
    verified: true
    max-request: 1
    shodan-query: http.html:"/redfish/v1"
  tags: config,exposure,redfish,api,discovery

http:
  - method: GET
    path:
      - "{{BaseURL}}/redfish/v1/"

    matchers:
      - type: dsl
        dsl:
          - 'contains_any(body, "\"@odata.type\":", "/redfish/v1/$metadata#Message")'
          - 'contains(header, "application/json")'
          - 'status_code == 200 || status_code == 502'
        condition: and

    extractors:
      - type: regex
        part: body
        group: 1
        regex:
          - '[a-z]+\.v?([0-9_\.]+)\.'
# digest: 4b0a00483046022100e41b0a1db6a727b93a3b9b16229ec41c8b2a701642cf061188360d99684bf1e00221009b073931313d8bd52585572c547ef0173031f93170a374d005ad4d39f2e6c076:922c64590222798bb761d5b6d8e72950