Skip to content

fix(deps): upgrade guava from 31.1-jre to 33.7.2-jre - #1116

Open
abhishekj720 wants to merge 3 commits into
masterfrom
security/fix-guava
Open

abhishekj720 wants to merge 3 commits into
masterfrom
security/fix-guava

Conversation

@abhishekj720

@abhishekj720 abhishekj720 commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Upgrades com.google.guava:guava from 31.1-jre to 33.7.2-jre.

Guava maintains backward compatibility across its jre variants. This also overrides the vulnerable 31.1-jre pulled in transitively by grpc-stub and grpc-protobuf, clearing those transitive alerts as well.

Vulnerabilities fixed

CVE Severity Description Fixed in
CVE-2023-2976 Low (CVSS 3.3) FileBackedOutputStream creates temporary files in the default Java temp directory with permissions readable by other local users guava 32.0.0-jre
CVE-2026-102554 High (CVSS 8.2) Deserialization of crafted streams via CompactHashMap, CompactHashSet, and MapMakerInternalMap allows an attacker to force oversized heap allocations, crashing the JVM with OutOfMemoryError guava 33.7.2-jre

Type of Change

  • Add new API(s)
  • Add new data type(s)
  • Add new field(s) to existing data type
  • Remove field(s) from data type
  • Remove data type(s)
  • Remove API(s)
  • Other (please provide detailed description)

Data Effect

  • Does it change the data stored in database?

Detailed Description

Upgrading directly to 33.7.2-jre (rather than the minimum 32.0.0-jre) fixes both CVEs in one change. Guava's jre variant is backward compatible.

The upgrade also transitively replaces the 31.1-jre pulled in by io.grpc:grpc-stub and io.grpc:grpc-protobuf, clearing the guava-related transitive alerts on those packages without requiring a grpc version bump.

Impact Analysis

  • Backward Compatibility: No impact. Guava maintains backward compatibility within its jre variant line.
  • Forward Compatibility: No impact.

Testing Plan

  • Unit Tests: Existing test suite covers all Guava usage in the project.
  • Persistence Tests: N/A
  • Integration Tests: N/A
  • Compatibility Tests: N/A

Rollout Plan

Standard release. No special rollout required.

Fixes two vulnerabilities:

- CVE-2023-2976 (CVSS 3.3): FileBackedOutputStream creates temporary files
  in the default Java temp directory with permissions accessible to other
  local users. Fixed in guava 32.0.0-jre.
- CVE-2026-102554 (CVSS 8.2): Deserialization of crafted streams via
  CompactHashMap, CompactHashSet, and MapMakerInternalMap allows an
  attacker to force oversized heap allocation leading to OutOfMemoryError.
  Fixed in guava 33.7.2-jre.

Upgrading directly to 33.7.2-jre fixes both and also overrides the
vulnerable 31.1-jre pulled in transitively by grpc-stub and grpc-protobuf.
Guava maintains backward compatibility across its jre variants.
@abhishekj720 abhishekj720 changed the title fix(security): upgrade guava from 31.1-jre to 33.7.2-jre fix(deps): upgrade guava from 31.1-jre to 33.7.2-jre Oct 16, 2026
Guava 32+ publishes both jreRuntimeElements and androidRuntimeElements
variants. Gradle 6 cannot choose between them for configurations that do
not declare the org.gradle.jvm.environment attribute (e.g. the protobuf
Gradle plugin's compileProtoPath used by extractIncludeProto).

Add a configurations.all block that sets org.gradle.jvm.environment to
standard-jvm on all configurations so Gradle always selects the JRE
variant.

Signed-off-by: abhishek.jha <abhishek.jha@uber.com>
@codecov

codecov Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 68.90%. Comparing base (5357c97) to head (0e0e9eb).
⚠️ Report is 3 commits behind head on master.

❌ Your project check has failed because the head coverage (68.90%) is below the target coverage (85.00%). You can increase the head coverage or adjust the target coverage.
see 9 files with indirect coverage changes


Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2a5de75...0e0e9eb. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Signed-off-by: abhishek.jha <abhishek.jha@uber.com>
@gitar-bot

gitar-bot Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Code Review ✅ Approved

🟡 Medium risk · Upgrading Guava and applying a JVM-environment attribute to all Gradle configurations could alter dependency resolution or expose compatibility issues at runtime.

Upgrades Guava from 31.1-jre to 33.7.2-jre to fix CVE-2023-2976 and CVE-2026-102554, and adds a configurations.all block setting org.gradle.jvm.environment to standard-jvm so Gradle 6 resolves the newer variants. No issues found.

Verification Repos 1 inspected · PRs 1 inspected

Functional validation No results

Rules No rules evaluated

Broader impact Repos 1 inspected PRs 1 inspected
Cross-repo 1 repository inspected 0 open impacts

cadence-workflow/cadence-java-samples Inspected

Cross-PR 1 PR inspected 0 open impacts

PR #1117: fix(deps): upgrade protobuf-java and protobuf-java-util to 3.25.5 Inspected

For more verification details, comment gitar display:verbose.

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing compact verification results.

Comment with these commands to change the behavior for this request:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

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.

1 participant