id: weebly-detect

info:
  name: Weebly Detection
  author: Chirag Mistry
  severity: info
  description: |
    An instance running Weebly is detected by looking for specific HTTP headers, HTML tags, and known endpoints.
  metadata:
    max-request: 7
    shodan-query: product:"Weebly"
  tags: weebly, detect, tech

http:
  - method: GET
    path:
      - "{{BaseURL}}"
      - "{{BaseURL}}/robots.txt"
      - "{{BaseURL}}/sitemap.xml"
      - "{{BaseURL}}/favicon.ico"
      - "{{BaseURL}}/index.php"
      - "{{BaseURL}}/weebly/"
      - "{{BaseURL}}/site/"

    stop-at-first-match: true
    matchers-condition: and
    matchers:
      - type: word
        part: response
        words:
          - "Powered by Weebly"
          - "weebly.com"
          - "X-Powered-By-Weebly"
        condition: or
        case-insensitive: true

      - type: status
        status:
          - 200
          - 403

    extractors:
      - type: regex
        part: body
        name: version
        regex:
          - 'Weebly ([0-9.]+)'
          - 'Powered by Weebly ([0-9.]+)'

      - type: regex
        part: body
        name: weebly_id
        regex:
          - 'weebly-site-id=([a-z0-9]+)'
          - 'weebly\.com/([^/]+)'
# digest: 4a0a00473045022100857169b36f6164ad75248e40a67ebd376cb898c78d0ff650743bdc4b5184842e02200eb86a26af96c4dc0b69c063702e618f52db27424539c9d23311979a30dc23ef:922c64590222798bb761d5b6d8e72950