Package: protobuf / 3.21.12-14

Metadata

Package Version Patches format
protobuf 3.21.12-14 3.0 (quilt)

Patch series

view the series file
Patch File delta Description
hurd.patch | (download)

src/google/protobuf/compiler/command_line_interface.cc | 3 3 + 0 - 0 !
1 file changed, 3 insertions(+)

 add support for gnu/hurd which doesn't define path_max.
default_python_version | (download)

python/mox.py | 2 1 + 1 - 0 !
python/stubout.py | 2 1 + 1 - 0 !
2 files changed, 2 insertions(+), 2 deletions(-)

---
s390x.patch | (download)

src/google/protobuf/stubs/platform_macros.h | 7 7 + 0 - 0 !
1 file changed, 7 insertions(+)

 add support for s390x architecture.
 Based on port of Google V8 JavaScript engine to z Systems


disable_local_gmock.patch | (download)

Makefile.am | 6 3 + 3 - 0 !
src/Makefile.am | 21 6 + 15 - 0 !
2 files changed, 9 insertions(+), 18 deletions(-)

 use packaged google test and google mock libraries
 Link tests with the already compiled libraries.
fix_google_test_link.patch | (download)

src/Makefile.am | 10 5 + 5 - 0 !
1 file changed, 5 insertions(+), 5 deletions(-)

 fix linking with recent google's c++ test framework
 Need to link with libgtest_main.a as well.
no_thirdparty.patch | (download)

Makefile.am | 2 1 + 1 - 0 !
configure.ac | 1 0 + 1 - 0 !
2 files changed, 1 insertion(+), 2 deletions(-)

 don't compile third_party source
 .
x32.patch | (download)

ruby/ext/google/protobuf_c/wrap_memcpy.c | 2 1 + 1 - 0 !
1 file changed, 1 insertion(+), 1 deletion(-)

 fix ftbfs on x32 due to versioned glibc symbols
 protobuf assumes that glibc 2.2.5 memcpy symbols will be available #if
 defined(__x86-64__); however, x32 also defines this, but was not
 supported prior to 2.16.
32bit.patch | (download)

python/google/protobuf/internal/text_format_test.py | 71 48 + 23 - 0 !
1 file changed, 48 insertions(+), 23 deletions(-)

 cut number 32 bit number parsing in python 2 self-tests
 Any number get back as zero. :-/
python3ify_examples.patch | (download)

examples/add_person.py | 2 1 + 1 - 0 !
examples/list_people.py | 2 1 + 1 - 0 !
2 files changed, 2 insertions(+), 2 deletions(-)

 execute examples with pyhton 3
 Update shebang to call Python 3 binary.
no_errorprone.patch | (download)

java/util/src/main/java/com/google/protobuf/util/Durations.java | 9 3 + 6 - 0 !
java/util/src/main/java/com/google/protobuf/util/FieldMaskTree.java | 7 1 + 6 - 0 !
java/util/src/main/java/com/google/protobuf/util/FieldMaskUtil.java | 5 1 + 4 - 0 !
java/util/src/main/java/com/google/protobuf/util/JsonFormat.java | 4 1 + 3 - 0 !
java/util/src/main/java/com/google/protobuf/util/Timestamps.java | 7 3 + 4 - 0 !
5 files changed, 9 insertions(+), 23 deletions(-)

 remove dependency on errror-prone library
 Library is not necessary and is not currently available in Debian. This patch
 can be safely removed if the error-prone library is ever added to Debian and
 that functionality is needed in protobuf.
no_j2objc.patch | (download)

java/util/pom.xml | 4 2 + 2 - 0 !
java/util/src/main/java/com/google/protobuf/util/Timestamps.java | 3 1 + 2 - 0 !
2 files changed, 3 insertions(+), 4 deletions(-)

 remove dependency on j2objc library
 It's not needed for Debian.
no_javax.patch | (download)

java/util/src/main/java/com/google/protobuf/util/FieldMaskUtil.java | 4 2 + 2 - 0 !
java/util/src/main/java/com/google/protobuf/util/JsonFormat.java | 8 2 + 6 - 0 !
2 files changed, 4 insertions(+), 8 deletions(-)

 remove dependency on javax.annotation library
 It's not yet packaged and not mandatory.
Fix_build_with_Python_3.11.patch | (download)

python/google/protobuf/pyext/descriptor.cc | 75 62 + 13 - 0 !
1 file changed, 62 insertions(+), 13 deletions(-)

 [patch] fix build with python 3.11

The PyFrameObject structure members have been removed from the public C API.

fix_hppa_alignof_assert.patch | (download)

src/google/protobuf/descriptor.cc | 2 2 + 0 - 0 !
src/google/protobuf/map.h | 2 2 + 0 - 0 !
2 files changed, 4 insertions(+)

 hppa is over aligned and fails
 Filter out hppa machines on the static_assert lines.
Fix_rule_for_java_target.patch | (download)

examples/Makefile | 7 4 + 3 - 0 !
1 file changed, 4 insertions(+), 3 deletions(-)

 [patch] fix rule for java target in examples/makefile


build_32_bit_tests.patch | (download)

src/google/protobuf/compiler/cpp/message_size_unittest.cc | 2 1 + 1 - 0 !
src/google/protobuf/extension_set_unittest.cc | 6 4 + 2 - 0 !
src/google/protobuf/io/zero_copy_stream_unittest.cc | 3 3 + 0 - 0 !
src/google/protobuf/repeated_field_unittest.cc | 4 2 + 2 - 0 !
src/google/protobuf/util/time_util_test.cc | 28 17 + 11 - 0 !
5 files changed, 27 insertions(+), 16 deletions(-)

 [patch] adding full build to 32 bit tests (#10589)

* Adding full build to 32 bit tests

* Running C++ tests in 32 bit builds

* Patching static assert test failure

* Test fixes for 32-bit architectures

* Cleanup after CMake build

* Save protoc before cleanup

* Route protoc better

fix_C++_32bit_tests.patch | (download)

src/google/protobuf/any_test.cc | 9 7 + 2 - 0 !
src/google/protobuf/arena_unittest.cc | 8 4 + 4 - 0 !
2 files changed, 11 insertions(+), 6 deletions(-)

 fix c++ build tests
 Add bits to expect 32 bit systems.
fix_Python_32bit_tests.patch | (download)

python/google/protobuf/internal/descriptor_test.py | 11 7 + 4 - 0 !
python/google/protobuf/internal/json_format_test.py | 6 3 + 3 - 0 !
python/google/protobuf/internal/reflection_test.py | 4 3 + 1 - 0 !
python/google/protobuf/internal/text_format_test.py | 71 23 + 48 - 0 !
4 files changed, 36 insertions(+), 56 deletions(-)

 fix python build tests
 Add bits to expect 32 bit systems.
test_scope_for_junit.patch | (download)

java/util/pom.xml | 1 1 + 0 - 0 !
1 file changed, 1 insertion(+)

---
stop_using_backward_compatibility_timezones.patch | (download)

python/google/protobuf/internal/well_known_types_test.py | 8 4 + 4 - 0 !
1 file changed, 4 insertions(+), 4 deletions(-)

 [patch] python: stop using backward compatibility timezones

The 'Japan' and 'US/Pacific' timezones used in Python tests are
backward compatibility timezones (defined in the backward file of
tzdata) and might not be available on all systems. For instance Debian
recently split those timezones in a tzdata-legacy package.

Update the tests to the use the canonical name of the timezones instead,
that is respectively 'Asia/Tokyo' and 'America/Los_Angeles'.

python3.12.diff | (download)

python/google/protobuf/internal/json_format_test.py | 4 2 + 2 - 0 !
1 file changed, 2 insertions(+), 2 deletions(-)

---
CVE 2024 7254 1.patch | (download)

java/core/src/main/java/com/google/protobuf/CodedInputStream.java | 108 24 + 84 - 0 !
java/core/src/test/proto/com/google/protobuf/map_lite_test.proto | 3 2 + 1 - 0 !
java/core/src/test/proto/com/google/protobuf/map_test.proto | 3 2 + 1 - 0 !
java/lite/src/test/java/com/google/protobuf/LiteTest.java | 1 1 + 0 - 0 !
4 files changed, 29 insertions(+), 86 deletions(-)

 [patch 1/5] internal change

PiperOrigin-RevId: 663919912

CVE 2024 7254 2.patch | (download)

java/core/src/main/java/com/google/protobuf/ArrayDecoders.java | 3 1 + 2 - 0 !
java/core/src/main/java/com/google/protobuf/InvalidProtocolBufferException.java | 2 1 + 1 - 0 !
java/core/src/main/java/com/google/protobuf/MessageSchema.java | 3 3 + 0 - 0 !
java/core/src/main/java/com/google/protobuf/MessageSetSchema.java | 1 1 + 0 - 0 !
java/core/src/main/java/com/google/protobuf/UnknownFieldSchema.java | 3 1 + 2 - 0 !
java/lite/src/test/java/com/google/protobuf/LiteTest.java | 3 3 + 0 - 0 !
src/google/protobuf/unittest_lite.proto | 4 4 + 0 - 0 !
7 files changed, 14 insertions(+), 5 deletions(-)

 [patch 2/5] internal change

PiperOrigin-RevId: 653615736

CVE 2024 7254 3.patch | (download)

java/core/src/main/java/com/google/protobuf/ArrayDecoders.java | 28 28 + 0 - 0 !
java/core/src/main/java/com/google/protobuf/CodedInputStream.java | 6 6 + 0 - 0 !
java/core/src/main/java/com/google/protobuf/MessageSchema.java | 12 6 + 6 - 0 !
java/core/src/main/java/com/google/protobuf/MessageSetSchema.java | 3 1 + 2 - 0 !
java/core/src/main/java/com/google/protobuf/UnknownFieldSchema.java | 29 25 + 4 - 0 !
java/core/src/test/java/com/google/protobuf/CodedInputStreamTest.java | 158 158 + 0 - 0 !
java/lite/src/test/java/com/google/protobuf/LiteTest.java | 232 232 + 0 - 0 !
7 files changed, 456 insertions(+), 12 deletions(-)

 [patch 3/5] add recursion check when parsing unknown fields in java.

PiperOrigin-RevId: 675657198

CVE 2024 7254 4.patch | (download)

src/google/protobuf/unittest_lite.proto | 2 1 + 1 - 0 !
1 file changed, 1 insertion(+), 1 deletion(-)

 [patch 4/5] fix merge conflict by adding optional label to proto2
 unittest_lite.proto


CVE 2024 7254 5.patch | (download)

java/lite/src/test/java/com/google/protobuf/LiteTest.java | 20 0 + 20 - 0 !
src/google/protobuf/unittest_lite.proto | 4 0 + 4 - 0 !
2 files changed, 24 deletions(-)

 [patch 5/5] remove recursivegroup test case which doesn't exist in
 25.x pre-Editions


CVE 2025 4565 1.patch | (download)

python/google/protobuf/internal/decoder.py | 14 11 + 3 - 0 !
python/google/protobuf/internal/message_test.py | 11 11 + 0 - 0 !
python/google/protobuf/internal/python_message.py | 3 2 + 1 - 0 !
python/google/protobuf/unknown_fields.py | 3 2 + 1 - 0 !
4 files changed, 26 insertions(+), 5 deletions(-)

 [patch] make pure python reject unmatched end-group tag in unknown
 fields

This brings it into conformance with our spec and other languages.

PiperOrigin-RevId: 704518974

CVE 2025 4565 2.patch | (download)

python/google/protobuf/internal/decoder.py | 98 75 + 23 - 0 !
python/google/protobuf/internal/message_test.py | 1 1 + 0 - 0 !
python/google/protobuf/internal/python_message.py | 7 5 + 2 - 0 !
3 files changed, 81 insertions(+), 25 deletions(-)

 [patch] internal pure python fixes

PiperOrigin-RevId: 733441339

CVE 2025 4565 3.patch | (download)

python/google/protobuf/internal/decoder.py | 31 31 + 0 - 0 !
python/google/protobuf/internal/message_test.py | 60 56 + 4 - 0 !
2 files changed, 87 insertions(+), 4 deletions(-)

 [patch] add recursion depth limits to pure python

PiperOrigin-RevId: 758382549

protobuf add loongarch64 support.patch | (download)

src/google/protobuf/stubs/platform_macros.h | 3 3 + 0 - 0 !
1 file changed, 3 insertions(+)

 add loongarch64 support 
 .
 protobuf (3.21.12-10+loong64) unstable; urgency=medium
 .
   * src/google/protobuf/stubs/platform_macros.h
     - Add loongarch64 support
0001 Change PROTOBUF_MUSTTAIL to affirmatively use the mu.patch | (download)

src/google/protobuf/port_def.inc | 6 2 + 4 - 0 !
1 file changed, 2 insertions(+), 4 deletions(-)

 change protobuf_musttail to affirmatively use the musttail annotation
 only on our primary target platforms where we know it does what we want.

This should effectively be the same net result as the prior ifdef in practice, but leaves it disabled by default for the long tail of more exotic platforms where this may cause a build break.

Fixes #22367

PiperOrigin-RevId: 775757737