Class FileNameAnalyzer

java.lang.Object
org.owasp.dependencycheck.analyzer.AbstractAnalyzer
org.owasp.dependencycheck.analyzer.FileNameAnalyzer
All Implemented Interfaces:
Analyzer

@ThreadSafe public class FileNameAnalyzer extends AbstractAnalyzer
Takes a dependency and analyzes the filename and determines the hashes.
Author:
Jeremy Long
  • Constructor Details

    • FileNameAnalyzer

      public FileNameAnalyzer()
  • Method Details

    • getName

      public String getName()
      Returns the name of the analyzer.
      Returns:
      the name of the analyzer.
    • getAnalysisPhase

      public AnalysisPhase getAnalysisPhase()
      Returns the phase that the analyzer is intended to run in.
      Returns:
      the phase that the analyzer is intended to run in.
    • getAnalyzerEnabledSettingKey

      protected String getAnalyzerEnabledSettingKey()

      Returns the setting key to determine if the analyzer is enabled.

      Specified by:
      getAnalyzerEnabledSettingKey in class AbstractAnalyzer
      Returns:
      the key for the analyzer's enabled property
    • analyzeDependency

      protected void analyzeDependency(Dependency dependency, Engine engine) throws AnalysisException
      Collects information about the file name.
      Specified by:
      analyzeDependency in class AbstractAnalyzer
      Parameters:
      dependency - the dependency to analyze.
      engine - the engine that is scanning the dependencies
      Throws:
      AnalysisException - is thrown if there is an error reading the JAR file.