id: apache-answer-detect

info:
  name: Apache Answer - Detection
  author: omranisecurity
  severity: info
  description: |
    Detects Apache Answer version through API endpoit
  reference:
    - https://answer.apache.org/
  classification:
    cpe: cpe:2.3:a:apache:answer:*:*:*:*:*:*:*:*
  metadata:
    verified: true
    max-request: 1
    vendor: apache
    product: answer
    shodan-query: http.favicon.hash:523757057
    fofa-query: icon_hash="523757057"
  tags: detect,tech,apache

http:
  - method: GET
    path:
      - "{{BaseURL}}/answer/api/v1/siteinfo"

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - '"code":'

      - type: word
        part: header
        words:
          - application/json

      - type: status
        status:
          - 200

    extractors:
      - type: regex
        part: body
        name: version
        regex:
          - '"version":"([^"]+)"'
# digest: 4a0a00473045022100ffdce75cdb59a9dbec1a933e26281a91039a5cd0b3c3d85255496fc27b771ee7022017080929a1a540ba1b156a5782e27580fdc1fbf4eba4a1f3cf33fe5b98d20e6d:922c64590222798bb761d5b6d8e72950