Skip to content

Question about monotonic recursion in customizations #2

@chmodxxx

Description

@chmodxxx

Hey @rvermeulen

I'm hitting an issue when setting up a customizations for JndiInjectionQuery (https://github.com/github/codeql/blob/bbd7e623418e41775c90cfbbe44ad25b3bf9c5e3/java/ql/lib/semmle/code/java/security/JndiInjectionQuery.qll#L12)

so the code I have right now in my Customizations.qll is :

import java 

private import semmle.code.java.dataflow.FlowSources
private import semmle.code.java.security.JndiInjectionQuery

class JndiInjectionSanitizer extends JndiInjectionFlowConfig {
    override predicate isSanitizer(DataFlow::Node node) { 
        exists(MethodAccess containsCall |
            containsCall.getMethod().toString() = "contains" and
            containsCall.getMethod() instanceof CollectionMethod and
            containsCall.getAnArgument() = node.asExpr()
          )
      }
}

However this is returning an error about monotonic-recursion in a bunch of files, is this not the correct way to customize the sanitizer of a flowconfig class ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions