Update dependency com.google.protobuf:protobuf-java to v3.25.5 [SECURITY] #285
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
3.13.0
->3.25.5
GitHub Vulnerability Alerts
CVE-2021-22569
Summary
A potential Denial of Service issue in protobuf-java was discovered in the parsing procedure for binary data.
Reporter: OSS-Fuzz
Affected versions: All versions of Java Protobufs (including Kotlin and JRuby) prior to the versions listed below. Protobuf "javalite" users (typically Android) are not affected.
Severity
CVE-2021-22569 High - CVSS Score: 7.5, An implementation weakness in how unknown fields are parsed in Java. A small (~800 KB) malicious payload can occupy the parser for several minutes by creating large numbers of short-lived objects that cause frequent, repeated GC pauses.
Proof of Concept
For reproduction details, please refer to the oss-fuzz issue that identifies the specific inputs that exercise this parsing weakness.
Remediation and Mitigation
Please update to the latest available versions of the following packages:
CVE-2022-3171
Summary
A potential Denial of Service issue in
protobuf-java
core and lite was discovered in the parsing procedure for binary and text format data. Input streams containing multiple instances of non-repeated embedded messages with repeated or unknown fields causes objects to be converted back-n-forth between mutable and immutable forms, resulting in potentially long garbage collection pauses.Reporter: OSS Fuzz
Affected versions: This issue affects both the Java full and lite Protobuf runtimes, as well as Protobuf for Kotlin and JRuby, which themselves use the Java Protobuf runtime.
Severity
CVE-2022-3171 Medium - CVSS Score: 5.7 (NOTE: there may be a delay in publication)
Remediation and Mitigation
Please update to the latest available versions of the following packages:
protobuf-java (3.21.7, 3.20.3, 3.19.6, 3.16.3)
protobuf-javalite (3.21.7, 3.20.3, 3.19.6, 3.16.3)
protobuf-kotlin (3.21.7, 3.20.3, 3.19.6, 3.16.3)
protobuf-kotlin-lite (3.21.7, 3.20.3, 3.19.6, 3.16.3)
google-protobuf [JRuby gem only] (3.21.7, 3.20.3, 3.19.6)
CVE-2022-3509
A parsing issue similar to CVE-2022-3171, but with textformat in protobuf-java core and lite versions prior to 3.21.7, 3.20.3, 3.19.6 and 3.16.3 can lead to a denial of service attack. Inputs containing multiple instances of non-repeated embedded messages with repeated or unknown fields causes objects to be converted back-n-forth between mutable and immutable forms, resulting in potentially long garbage collection pauses. We recommend updating to the versions mentioned above.
CVE-2022-3510
A parsing issue similar to CVE-2022-3171, but with Message-Type Extensions in protobuf-java core and lite versions prior to 3.21.7, 3.20.3, 3.19.6 and 3.16.3 can lead to a denial of service attack. Inputs containing multiple instances of non-repeated embedded messages with repeated or unknown fields causes objects to be converted back-n-forth between mutable and immutable forms, resulting in potentially long garbage collection pauses. We recommend updating to the versions mentioned above.
CVE-2021-22570
Nullptr dereference when a null char is present in a proto symbol. The symbol is parsed incorrectly, leading to an unchecked call into the proto file's name during generation of the resulting error message. Since the symbol is incorrectly parsed, the file is nullptr. We recommend upgrading to version 3.15.0 or greater.
CVE-2024-7254
Summary
When parsing unknown fields in the Protobuf Java Lite and Full library, a maliciously crafted message can cause a StackOverflow error and lead to a program crash.
Reporter: Alexis Challande, Trail of Bits Ecosystem Security Team [email protected]
Affected versions: This issue affects all versions of both the Java full and lite Protobuf runtimes, as well as Protobuf for Kotlin and JRuby, which themselves use the Java Protobuf runtime.
Severity
CVE-2024-7254 High CVSS4.0 Score 8.7 (NOTE: there may be a delay in publication)
This is a potential Denial of Service. Parsing nested groups as unknown fields with DiscardUnknownFieldsParser or Java Protobuf Lite parser, or against Protobuf map fields, creates unbounded recursions that can be abused by an attacker.
Proof of Concept
For reproduction details, please refer to the unit tests (Protobuf Java LiteTest and CodedInputStreamTest) that identify the specific inputs that exercise this parsing weakness.
Remediation and Mitigation
We have been working diligently to address this issue and have released a mitigation that is available now. Please update to the latest available versions of the following packages:
Release Notes
protocolbuffers/protobuf (com.google.protobuf:protobuf-java)
v3.25.5
Compare Source
v3.25.4
Compare Source
v3.25.3
Compare Source
v3.25.2
Compare Source
v3.25.1
Compare Source
v3.25.0
Compare Source
v3.24.4
Compare Source
v3.24.3
Compare Source
v3.24.2
Compare Source
v3.24.1
Compare Source
v3.24.0
Compare Source
v3.23.4
Compare Source
v3.23.3
Compare Source
v3.23.2
Compare Source
v3.23.1
Compare Source
v3.23.0
Compare Source
v3.22.5
Compare Source
v3.22.4
Compare Source
v3.22.3
Compare Source
v3.22.2
Compare Source
v3.22.1
Compare Source
v3.22.0
Compare Source
v3.21.12
Compare Source
v3.21.11
Compare Source
v3.21.10
Compare Source
v3.21.9
Compare Source
v3.21.8
Compare Source
v3.21.7
Compare Source
v3.21.6
Compare Source
v3.21.5
Compare Source
v3.21.4
Compare Source
v3.21.3
Compare Source
v3.21.2
Compare Source
v3.21.1
Compare Source
v3.21.0
Compare Source
v3.20.3
: Protocol Buffers v3.20.3Compare Source
Java
migrate parsing logic from parse constructor to builder.
constructor" to the Builder class.
messages rather than building up a new immutable object before merging. This
way results in fewer allocations and copy operations.
instances and merging afterwards. This has much better performance.
sub-messages directly from text rather than building a new sub-message and
merging the fully formed message into the existing field.
v3.20.2
: Protocol Buffers v3.20.2Compare Source
C++
v3.20.1
: Protocol Buffers v3.20.1Compare Source
PHP
Ruby
Other
v3.20.0
: Protocol Buffers v3.20.0Compare Source
2022-03-25 version 3.20.0 (C++/Java/Python/PHP/Objective-C/C#/Ruby/JavaScript)
Ruby
Ruby GC. In certain tests this leads to much lower memory usage due to more
frequent GC runs (#9586).
without losing precision.
systems.
putting such values in unknown fields.
Java
FieldSet.Builder.mergeFrom
subfield. (previously it was replaced.)’
Kotlin
Python
in type annotations.
*[Breaking change] Protobuf python generated codes are simplified. Descriptors and message
classes' definitions are now dynamic created in internal/builder.py.
Insertion Points for messages classes are discarded.
rather than only PyLongObjects.
first.
specified, the function returns a timezone-aware datetime in the given time
zone. If omitted or None, the function returns a timezone-naive UTC datetime
(as previously).
JSON serializations with UTF-8 or other non-ASCII encodings.
multi-dimensional arrays. Numpy arrays should be indexed or flattened explicitly before assignment.
Compiler
guard against stack overflows
more than one invalid character.
Arenas
C++
protobuf_INSTALL
to not install files (#7123)shadowed cached_size field
PHP
C#
Objective-C
proto_package_to_prefix_mappings_path
topackage_to_prefix_mappings_path
. (#9552)v3.19.6
: Protocol Buffers v3.19.6Compare Source
Java
migrate parsing logic from parse constructor to builder.
constructor" to the Builder class.
messages rather than building up a new immutable object before merging. This
way results in fewer allocations and copy operations.
instances and merging afterwards. This has much better performance.
sub-messages directly from text rather than building a new sub-message and
merging the fully formed message into the existing field.
v3.19.5
: Protocol Buffers v3.19.5Compare Source
C++
v3.19.4
: Protocol Buffers v3.19.4Compare Source
Python
Ruby
optional
fields in a message is an exact multiple of 32. (#9440).PHP
optional
fields in a message is an exact multiple of 32. (#9440).v3.19.3
: Protocol Buffers v3.19.3Compare Source
Python
v3.19.2
: Protocol Buffers v3.19.2Compare Source
Java
v3.19.1
: Protocol Buffers v3.19.1Compare Source
Bazel
JavaScript
ReferenceError: window is not defined
when getting the global object (#9156)Ruby
v3.19.0
: Protocol Buffers v3.19.0Compare Source
C++
MSVC_RUNTIME_LIBRARY
property (#8851)Java
//java/com/google/protobuf/util/...
with nullness annotationsKotlin
Python
JavaScript
PHP
Ruby
C#
v3.18.3
: Protocol Buffers v3.18.3Compare Source
C++
v3.18.2
: Protocol Buffers v3.18.2Compare Source
Java
v3.18.1
: Protocol Buffers v3.18.1Compare Source
Python
Ruby
v3.18.0
: Protocol Buffers v3.18.0Compare Source
C++
record the map items which are different in MessageDifferencer's reporter.
start.
Java
JavaScript
PHP
Ruby
Python
Other
v3.17.3
: Protocol Buffers v3.17.3Compare Source
Python
C++
Kotlin
Java
finished parsing.
General
v3.17.2
: Protocol Buffers v3.17.2Compare Source
Kotlin
PHP
(#8670)
v3.17.1
: Protocol Buffers v3.17.1Compare Source
PHP
Ruby
v3.17.0
: Protocol Buffers v3.17.0Compare Source
Protocol Compiler
C++
Descriptor::DebugString()
printed proto3 synthetic oneofs.SortAndUnique()
.Kotlin
Java
ranges in a TreeMap for faster queries. This is particularly relevant for
protos which define a large number of extension ranges, for example when
each tag is defined as an extension.
Python
oneof are present and all but one is null.
Ruby
Conformance Tests
oneof.
Other
proto_descriptor_set
(#8469)v3.16.3
: Protobuf Release v3.16.3Compare Source
Java
migrate parsing logic from parse constructor to builder.
constructor" to the Builder class.
messages rather than building up a new immutable object before merging. This
way results in fewer allocations and copy operations.
instances and merging afterwards. This has much better performance.
sub-messages directly from text rather than building a new sub-message and
merging the fully formed message into the existing field.
v3.16.1
: Protocol Buffers v3.16.1Compare Source
Java
v3.16.0
: Protocol Buffers v3.16.0Compare Source
C++
calls instead of crashing.
string
orbytes
fields.RepeatedPtrField.
middle.
performance.
on an error path.
Subclasses should inherit from SimpleFieldComparator instead.
C#
Java
included as causes.
JavaScript
Python
one instead of merging.
Objective-C
PHP
Ruby
Other
v3.15.8
: Protocol Buffers v3.15.8Compare Source
Ruby
v3.15.7
: Protocol Buffers v3.15.7Compare Source
C++
Ruby
v3.15.6
: Protocol Buffers v3.15.6Compare Source
Ruby
v3.15.5
: Protocol Buffers v3.15.5Compare Source
Ruby
PHP
C++
v3.15.4
: Protocol Buffers v3.15.4Compare Source
Ruby
C++
PHP
v3.15.3
: Protocol Buffers v3.15.3Compare Source
Ruby
v3.15.2
: Protocol Buffers v3.15.2Compare Source
Ruby
C++
v3.15.1
: Protocol Buffers v3.15.1Compare Source
Ruby
C++
v3.15.0
: Protocol Buffers v3.15.0Compare Source
Protocol Compiler
the --experimental_allow_proto3_optional flag.
C++
unknown fields
implement
Configuration
📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.