Maven Plugin: Export Report

The ossindex:audit can optionally record a report file which contains the details about the component reports that are used to determine if a dependency is vulnerable or not.

To enable this feature configure the reportFile parameter to the location where the report will be written.

<plugin>
  <groupId>org.sonatype.ossindex.maven</groupId>
  <artifactId>ossindex-maven-plugin</artifactId>
  <configuration>
    <reportFile>${project.build.directory}/audit-report.json</reportFile>
  </configuration>
</plugin>

or via CLI:

mvn ossindex:audit -Dossindex.reportFile=target/audit-report.json

Formats

The file extension is used to inform which format the report will be written as.

Format File Extension
JSON .json
XML .xml
Text .txt