id: basic-auth-detect

info:
  name: Basic Auth Detection
  author: w4cky_,bhutch
  severity: info
  metadata:
    max-request: 1
    shodan-query: "www-authenticate:"
  tags: tech,basic,auth

http:
  - method: GET
    path:
      - "{{BaseURL}}"

    matchers-condition: and
    matchers:
      - type: regex
        part: header
        regex:
          - "(?i)www-authenticate: basic"

      - type: status
        status:
          - 401

    extractors:
      - type: regex
        part: header
        group: 1
        regex:
          - '(?i)www-authenticate: (basic.*)\r\n'
# digest: 490a0046304402206b2e1cdd81183db6d9f03bd17a3a3440849836c38b0cceef79b15b6e503ccf2102205a98a6903d589d5338287b13754fb5a55c2dd69b08a4a68e02e38e8005c59488:922c64590222798bb761d5b6d8e72950