Skip to content

proto: honor RecursionLimit when skipping unknown groups - #72

Open
AshSgDe29071999 wants to merge 1 commit into
protocolbuffers:masterfrom
AshSgDe29071999:fix/unknown-group-recursion-limit
Open

proto: honor RecursionLimit when skipping unknown groups#72
AshSgDe29071999 wants to merge 1 commit into
protocolbuffers:masterfrom
AshSgDe29071999:fix/unknown-group-recursion-limit

Conversation

@AshSgDe29071999

Copy link
Copy Markdown

Unknown group fields were skipped with protowire.DefaultRecursionLimit (10000), ignoring UnmarshalOptions.RecursionLimit. Nested unknown groups were only rejected at ~10002 levels.

ConsumeFieldValueDepth now receives the remaining unmarshal depth on the unknown-field path (slow unmarshal, generated impl, and lazy impl).

Related: golang/protobuf#1719

Unknown group fields were skipped with protowire.DefaultRecursionLimit,
so UnmarshalOptions.RecursionLimit did not apply. Pass the remaining
depth into ConsumeFieldValueDepth.

Fixes golang/protobuf#1719
@google-cla

google-cla Bot commented Aug 26, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

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