Skip to content

feat: allow configuration of Sonatype Guide / OSS Index cache validity time#507

Merged
jeremylong merged 6 commits intodependency-check:mainfrom
chadlwilson:allow-ossindex-cache-validity-configuration
May 1, 2026
Merged

feat: allow configuration of Sonatype Guide / OSS Index cache validity time#507
jeremylong merged 6 commits intodependency-check:mainfrom
chadlwilson:allow-ossindex-cache-validity-configuration

Conversation

@chadlwilson
Copy link
Copy Markdown
Collaborator

@chadlwilson chadlwilson commented Apr 26, 2026

Allows overriding the configuration for how long to keep OSS Index cache entries for.

Minor

  • Adds (reinstates?) the capability to test the plugin on master against published ODC core snapshots
  • minor bump to JUnit while fixing the dependabot config for less noise
  • tidies some deprecation annotations
  • bump Gradle test version

@chadlwilson chadlwilson self-assigned this Apr 26, 2026
@chadlwilson chadlwilson force-pushed the allow-ossindex-cache-validity-configuration branch from dd743b1 to a76efd9 Compare April 29, 2026 14:19
@chadlwilson chadlwilson marked this pull request as ready for review April 29, 2026 14:19
@chadlwilson chadlwilson requested a review from Copilot April 29, 2026 14:39
@chadlwilson chadlwilson force-pushed the allow-ossindex-cache-validity-configuration branch from 813a7b1 to 82f405f Compare April 29, 2026 14:39
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds support in the Gradle plugin DSL to configure how long OSS Index (Sonatype Guide) cache entries remain valid, and updates build tooling to support testing against dependency-check-core snapshots.

Changes:

  • Add analyzers.ossIndex.validForHours to the extension and propagate it into dependency-check-core Settings.
  • Enable resolving OWASP snapshot artifacts via Sonatype snapshots repo; bump ODC to 12.2.2-SNAPSHOT.
  • Minor maintenance updates: JUnit version bump and dependabot ignore tweaks.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
src/main/groovy/org/owasp/dependencycheck/gradle/tasks/ConfiguredTask.groovy Maps the new OSS Index cache validity setting into core Settings.
src/main/groovy/org/owasp/dependencycheck/gradle/extension/OssIndexExtension.groovy Adds validForHours to the OSS Index analyzer DSL.
settings.gradle.kts Adds a snapshots-only Sonatype repo (restricted to org.owasp).
gradle/libs.versions.toml Bumps ODC to a snapshot and updates the JUnit BOM version.
.github/dependabot.yml Reduces dependabot noise by ignoring major updates for wrapper/JUnit BOM.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread gradle/libs.versions.toml
Always retrieve from local as a last resort; reduces changes of cache poisoning.
Gradle doesn't look here normally anyway, as it has its own cache, so it's mainly useful for local development.

Signed-off-by: Chad Wilson <[email protected]>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread settings.gradle.kts
Copy link
Copy Markdown
Contributor

@jeremylong jeremylong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jeremylong jeremylong merged commit 773f6ed into dependency-check:main May 1, 2026
4 checks passed
@chadlwilson chadlwilson deleted the allow-ossindex-cache-validity-configuration branch May 1, 2026 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants