id: npm-debug-log

info:
  name: NPM Debug Log Disclosure
  author: Hardik-Solanki
  severity: low
  description: NPM Debug log file exposed.
  reference:
    - https://github.com/maurosoria/dirsearch/blob/master/db/dicc.txt
    - https://docs.npmjs.com/generating-and-locating-npm-debug.log-files
  metadata:
    verified: true
    max-request: 2
    github-query: filename:npm-debug.log
  tags: exposure,npm,logs,debug

http:
  - method: GET
    path:
      - "{{BaseURL}}/npm-debug.log"
      - "{{BaseURL}}/assets/npm-debug.log"

    stop-at-first-match: true

    matchers-condition: and
    matchers:
      - type: word
        part: body
        words:
          - 'verbose cli'
          - 'verbose stack'
        condition: and

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