id: prometheus-promtail

info:
  name: Prometheus Promtail - Exposure
  author: irshad ahamed
  severity: medium
  description: |
    Prometheus Promtail is an agent that gathers log data from various sources, such as files or systemd journal.
  reference:
    - https://grafana.com/docs/loki/latest/clients/promtail/
    - https://github.com/grafana/loki/issues/8680
  metadata:
    verified: true
    max-request: 1
    shodan-query: http.favicon.hash:932345713
  tags: misconfig,prometheus,promtail,exposure

http:
  - method: GET
    path:
      - "{{BaseURL}}/service-discovery"

    matchers-condition: and
    matchers:
      - type: word
        words:
          - '>Promtail</a>'
          - 'https://github.com/grafana/loki'
        condition: and

      - type: status
        status:
          - 200
# digest: 4b0a00483046022100c07d245dc194bf9229108589edcfdd60f4138cb209e173f0c3e62e696e0c3021022100e9fca8fc39515639a4f21bcf09b62e00fbc53f2160666a1f1802903d9f05ef8d:922c64590222798bb761d5b6d8e72950