id: arcgis-api-service

info:
  name: ArcGIS REST Services Directory - Detect
  author: HeeresS
  severity: info
  description: Check for the existence of the "/arcgis/rest/services" path on an ArcGIS server.
  reference:
    - https://enterprise.arcgis.com/en/
  classification:
    cpe: cpe:2.3:a:esri:arcgis_server:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    product: arcgis_server
    shodan-query: title:"ArcGIS"
    vendor: esri
    verified: true
  tags: panel,arcgis,rest,api,detect,esri

http:
  - method: GET
    path:
      - '{{BaseURL}}/arcgis/rest/services'

    matchers-condition: and
    matchers:
      - type: word
        words:
          - 'REST Services Directory'
          - 'ArcGIS'
        condition: and

      - type: status
        status:
          - 200

    extractors:
      - type: regex
        part: body
        group: 1
        regex:
          - 'Current Version:\s*<\/b>\s*([0-9.]+)'
# digest: 4b0a00483046022100dff450061a964e5a154028977c3f879fa27f91712b0b4f7e8295b07199618444022100a508425811e5aee07eab739f769239323b52761d47bdcb35bbe0a980dc972661:922c64590222798bb761d5b6d8e72950