Skip to content

Rules do not scan Lambda Handler classes that do not implement an interface #24

@mbfreder

Description

@mbfreder

Currently, for a class to be scanned by the main detector, it needs to meet at least one of the following conditions:

  • Implement a Lambda handler Interface (RequestHandler or RequestStreamHandler)

  • Has a method that receives either (Map, com.amazonaws.services.lambda.runtime.Context) or (InputStream, OutputStream, com.amazonaws.services.lambda.runtime.Context) as parameters. This method would be considered a Lambda Handler.

The issue here is that in general, we don't need to implement an interface to be able to have a Lambda function. For example, this is a valid Lambda handler class:

  public class NewHandler {
      public String handleRequest(){
          //code
      }
  }

Solving this problem will allow us to scan most Lambda Handler classes that are currently falling through the cracks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions