id: linkerd-service-detect

info:
  name: Linkerd Service detection
  author: dudez
  severity: info
  reference:
    - https://twitter.com/nirvana_msu/status/1084144955034165248
  metadata:
    max-request: 1
  tags: tech,linkerd,service

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

    headers:
      l5d-dtab: /svc/* => /$/inet/interact.sh/443

    matchers-condition: or
    matchers:
      - type: regex
        regex:
          - '(?mi)^l5d-err:.*$'
          - '(?mi)^l5d-success-class: 0.*$'
          - '(?mi)^Via\s*?:.*?linkerd.*$'
        part: header
        condition: or

      - type: regex
        regex:
          - '(?mi)Exceeded .*? binding timeout while resolving name'
          - '(?mi)exceeded .*? to unspecified while dyn binding'
        part: body
        condition: or
# digest: 4b0a00483046022100904fa99d88cea88d52c1ed336fcaea6417cdc2d3470731ccbf7c12eb2e9180a4022100968ee6c8e3637e16234fd34b85ed315cbbb37f72bf6bf60fdc7f48a5fd191c85:922c64590222798bb761d5b6d8e72950