Class TaintAnalyzer.Builder

java.lang.Object
proguard.analysis.cpa.util.TaintAnalyzer.Builder
Enclosing class:
TaintAnalyzer

public static class TaintAnalyzer.Builder extends Object
Class to configure and build a TaintAnalyzer.

Each separate built TaintAnalyzer uses its own BamCache, so different analyzers won't share results.

  • Constructor Details

  • Method Details

    • build

      public TaintAnalyzer build()
    • setMaxCallStackDepth

      public TaintAnalyzer.Builder setMaxCallStackDepth(int maxCallStackDepth)
      Set the max depth call depth of the inter-procedural analysis. After the max depth has been reached, the analysis will provide a default result for the method (i.e., in the same way LibraryMethods are usually not analyzed).

      The default value is 10.

      Parameters:
      maxCallStackDepth - maximum depth of the call stack analyzed inter-procedurally. 0 means intra-procedural analysis. < 0 means no maximum depth.
      Returns:
      this ValueAnalyzer builder.
    • setAbortOperator

      public TaintAnalyzer.Builder setAbortOperator(AbortOperator abortOperator)
      Sets the abort operator for premature CPA algorithm termination.
    • setMemoryLocationAbortOperator

      public TaintAnalyzer.Builder setMemoryLocationAbortOperator(AbortOperator memoryLocationAbortOperator)
      Sets the abort operator for premature trace reconstruction termination.
    • setTaintTransformers

      public TaintAnalyzer.Builder setTaintTransformers(Map<MethodSignature,JvmTaintTransformer> taintTransformers)
      Set a mapping from method signature to a transformer object applied to the taint state when that method is invoked.
    • setExtraTaintPropagationLocations

      public TaintAnalyzer.Builder setExtraTaintPropagationLocations(Map<Call,Set<JvmMemoryLocation>> extraTaintPropagationLocations)
      Set a mapping from a call to the set of locations which should get tainted after the call invocation.