Skip to content

Commit

Permalink
For #460. Set groundwork for an NVD API key
Browse files Browse the repository at this point in the history
  • Loading branch information
binkley committed May 9, 2024
1 parent c983423 commit 2f98340
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
4 changes: 4 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,10 @@ dependencyCheck {
skip = Boolean.getBoolean("owasp.skip") // DEFAULT is false
suppressionFile = rootProject.file("config/owasp-suppressions.xml")

nvd {
apiKey = findProperty("owasp.nvdApiKey") ?: System.getenv("OWASP_NVD_API_KEY")
}

// Use this block when mirroring the NIST CVE data -- the data may suffer
// timeouts for downloading. GitHub, for example, maintains caches of the
// data, and you might see your local build fail for access, but pass in CI
Expand Down
2 changes: 2 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@
<maven.version>3.9.6</maven.version>
<mockito.version>5.11.0</mockito.version>
<modernizer.version>2.8.0</modernizer.version>
<owasp.nvdApiKey>${env.OWASP_NVD_API_KEY}</owasp.nvdApiKey>
<owasp.skip>false</owasp.skip>
<pitest-junit5-plugin.version>1.2.1</pitest-junit5-plugin.version>
<pitest-maven.version>1.16.0</pitest-maven.version>
Expand Down Expand Up @@ -460,6 +461,7 @@
<!-- This is not dotnet code -->
<assemblyAnalyzerEnabled>false</assemblyAnalyzerEnabled>
<failBuildOnCVSS>0</failBuildOnCVSS>
<nvdApiKey>${owasp.nvdApiKey}</nvdApiKey>
<skip>${owasp.skip}</skip>
</configuration>
<executions>
Expand Down

0 comments on commit 2f98340

Please sign in to comment.