id: nodejs-framework-exceptions

info:
  name: Node.js Framework Exceptions
  author: Aayush Dhakal
  severity: info
  description: Detects suspicious Node.js framework exceptions that could indicate exploitation attempts
  reference:
    - https://expressjs.com/en/guide/error-handling.html
    - https://nodejs.org/en/docs/guides
  tags: file,logs,nodejs

file:
  - extensions:
      - all

    extractors:
      - type: regex
        name: exception
        part: body
        regex:
          - 'TypeError'
          - 'ReferenceError'
          - 'SyntaxError'
          - 'ValidationError'
          - 'UnauthorizedError'
          - 'ForbiddenError'
          - 'NotFoundError'
          - 'InternalServerError'
          - 'BadRequestError'
          - 'MongoError'
          - 'SequelizeDatabaseError'
# digest: 490a0046304402203d687dad5299c3dc8d8e9858acd5c8e523452096376ba31f4b0cb5f0032fd5e002204e372fcd49787a78853fc88447ce742a15945082ec05b690e9699c174399d4e8:922c64590222798bb761d5b6d8e72950