Skip to content

Add OWASP Dependency-Check to msal library build, Fixes AB#3667951#2531

Open
p3dr0rv wants to merge 6 commits into
devfrom
pedroro/owasp-dependency-check
Open

Add OWASP Dependency-Check to msal library build, Fixes AB#3667951#2531
p3dr0rv wants to merge 6 commits into
devfrom
pedroro/owasp-dependency-check

Conversation

@p3dr0rv

@p3dr0rv p3dr0rv commented Jun 15, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds OWASP Dependency-Check scanning to the :msal Android library build so runtime dependencies can be analyzed for known CVEs during the standard Gradle check lifecycle, using a suppression file for narrowly-scoped false positives.

What changed

  • Applies the org.owasp.dependencycheck Gradle plugin to :msal and wires dependencyCheckAnalyze into check.
  • Configures Dependency-Check (CVSS threshold, report formats/output dir, runtime-only scan configurations, NVD throttling, analyzer disables) and adds an NVD API key guard for runs that include the analyze task.
  • Adds an OWASP Dependency-Check suppressions XML with targeted false-positive suppressions.

Validation

  • Local build script docs and paths updated to match repository structure.
  • Error message for missing NVD key now contains only actionable input methods.

Work Item

Mirrors the OWASP Dependency-Check setup already in common:

- Apply org.owasp.dependencycheck plugin (v12.2.2)
- Wire dependencyCheckAnalyze into the check task
- Scan only shipped runtime classpaths (dist/local x release/debug)
- Disable analyzers irrelevant to an Android/Java library (assembly,
  nuspec, node, ossIndex, archive)
- NVD key resolved from -PnvdApiKey / gradle.properties / NVD_API_KEY
  with fail-fast when the task is in the graph and the key is missing
- Add config/owasp/dependency-check-suppressions.xml with the same two
  false-positive suppressions used by common (androidx.browser CVE-2008-7298
  and common4j CVE-2024-35255)
@p3dr0rv p3dr0rv requested a review from a team as a code owner June 15, 2026 22:04
Copilot AI review requested due to automatic review settings June 15, 2026 22:04
@github-actions

This comment has been minimized.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Adds OWASP Dependency-Check scanning to the :msal Android library build so runtime dependencies can be analyzed for known CVEs during the standard Gradle check lifecycle, using a suppression file for narrowly-scoped false positives.

Changes:

  • Applies the org.owasp.dependencycheck Gradle plugin to :msal and wires dependencyCheckAnalyze into check.
  • Configures Dependency-Check (CVSS threshold, report formats/output dir, runtime-only scan configurations, NVD throttling, analyzer disables) and adds an NVD API key guard for runs that include the analyze task.
  • Adds an OWASP Dependency-Check suppressions XML with two targeted false-positive suppressions.

Reviewed changes

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

File Description
msal/build.gradle Adds and configures OWASP Dependency-Check and hooks it into check, including NVD API key resolution + fail-fast behavior.
config/owasp/dependency-check-suppressions.xml Introduces a suppression file with scoped suppressions + guidance comments for maintaining suppressions.

Comment thread msal/build.gradle Outdated
Comment thread config/owasp/dependency-check-suppressions.xml Outdated
Comment thread config/owasp/dependency-check-suppressions.xml Outdated
Comment thread config/owasp/dependency-check-suppressions.xml Outdated
p3dr0rv added 3 commits June 16, 2026 13:39
- Add suppressions for Kotlin stdlib CVEs (< 1.4.21)
- Add suppressions for OpenTelemetry Go/C++ CVEs
- Add suppressions for protobuf-javalite false positives
- Add suppressions for common library CPE false positive
- Note: CVE-2023-0833 (okhttp) NOT suppressed; tracked in PBI #3667962
@github-actions

This comment has been minimized.

@github-actions

Copy link
Copy Markdown

❌ Invalid work item number: AB#3667951
-. Work item number must be a valid integer.

Click here to learn more.

@github-actions

Copy link
Copy Markdown

❌ Invalid work item number: AB#3667951

##. Work item number must be a valid integer.

Click here to learn more.

@github-actions

Copy link
Copy Markdown

✅ Work item link check complete. Description contains link AB#3667951 to an Azure Boards work item.

@github-actions github-actions Bot changed the title Add OWASP Dependency-Check to msal library build Add OWASP Dependency-Check to msal library build, Fixes AB#3667951 Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants