id: private-key-exposure

info:
  name: Private key exposure via helper detector
  author: aashiq
  severity: high
  description: Searches for private key exposure by attempting to query the helper endpoint on node_modules
  metadata:
    max-request: 1
  tags: exposure,node,misconfig,vuln

http:
  - method: GET
    path:
      - "{{BaseURL}}/node_modules/mqtt/test/helpers/"

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

      - type: word
        words:
          - "Index of /node_modules/mqtt/test/helpers"
          - "Parent Directory"
        condition: and
# digest: 4b0a004830460221009507772f12bfed388757f3491783822e5b28fc08b4470d13cf57c130cd92ec62022100f12ccd0ae0e56674c05f2d8b8a17727ab2046e53475357ed214cf2be2cab10f6:922c64590222798bb761d5b6d8e72950