id: hashicorp-consul-webgui

info:
  name: HashiCorp Consul Web UI Login Panel - Detect
  author: c-sh0
  severity: info
  description: HashiCorp Consul Web UI login panel was detected,
  classification:
    cvss-metrics: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:N
    cwe-id: CWE-200
    cpe: cpe:2.3:a:hashicorp:consul:*:*:*:*:*:*:*:*
  metadata:
    max-request: 1
    vendor: hashicorp
    product: consul
    shodan-query:
      - http.title:"Consul by HashiCorp"
      - http.title:"consul by hashicorp"
      - cpe:"cpe:2.3:a:hashicorp:consul"
    fofa-query: title="consul by hashicorp"
    google-query: intitle:"consul by hashicorp"
  tags: consul,webserver,panel,hashicorp

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

    host-redirects: true
    max-redirects: 2

    matchers-condition: and
    matchers:
      - type: status
        status:
          - 200

      - type: word
        part: body
        words:
          - '<title>Consul by HashiCorp</title>'
          - '%22%2C%22CONSUL_COPYRIGHT_URL%22%3A%22https%3A%2F%2Fwww.hashicorp.com%22'
        condition: or

    extractors:
      - type: regex
        part: body
        group: 1
        regex:
          - "CONSUL_VERSION:.*([0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3})"
# digest: 4a0a0047304502203582f4f001a06f844a9d32f6d19d60f18a62a9f034d55ba59de31f6757bab52f022100fac9c69866279f2e40ebcf5cdc904c477bd8d3447dd87c51b83a67eff1d6dcc5:922c64590222798bb761d5b6d8e72950