Apply number-length validator on streaming integer path of async parser [GHSA-r7wm-3cxj-wff9] - #1611
Conversation
The non-blocking parser's NOT_AVAILABLE exits in the integer parsing branch did not invoke the same length validator that the sync parser and the async fraction path already use. This patch applies the existing _setIntLength helper at those exits so maxNumberLength is enforced consistently across sync and async parsers. Signed-off-by: tonghuaroot <tonghuaroot@gmail.com>
|
@tonghuaroot Looks good so far. One thing before I can merge: CLA from https://github.com/FasterXML/jackson/blob/main/CLA-jackson-2026.pdf (unless you have sent one already; only need to be sent once, good for all future prs). The usual way is to print it, fill & sign, scan/photo, email to |
|
@cowtowncoder Signed CLA emailed to cla@fasterxml.com just now. Thanks! |
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| java_version: ['8', '11', '17', '21', '25'] |
There was a problem hiding this comment.
Java 11 was an LTS, just as much as Java 8 was an LTS but both are no longer supported
There was a problem hiding this comment.
There was a problem hiding this comment.
Oh. I stand corrected. Will put it back.
|
Fixed in:
|
### What changes were proposed in this pull request? This PR upgrades `FasterXML` `Jackson` to 2.21.4. ### Why are the changes needed? - https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.21.4 (2026-05-28) - FasterXML/jackson-core#1611 - FasterXML/jackson-databind#5931 - FasterXML/jackson-databind#5950 - FasterXML/jackson-databind#5951 - FasterXML/jackson-databind#5967 - FasterXML/jackson-databind#5969 - FasterXML/jackson-databind#5971 - FasterXML/jackson-databind#5974 - FasterXML/jackson-databind#5981 - FasterXML/jackson-databind#5988 - FasterXML/jackson-databind#5993 ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Pass the CIs. ### Was this patch authored or co-authored using generative AI tooling? Generated-by: Claude Code (Claude Opus 4.8) Closes #56338 from dongjoon-hyun/SPARK-57273. Authored-by: Dongjoon Hyun <dongjoon@apache.org> Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
|
this seems to have been in 4cdd529 and that was ready in time for 2.22.0 and 3.2.0 |
|
Ok, as per https://github.com/FasterXML/jackson/wiki/Jackson-Release-2.22 (May 31, 2026) I think you are correct @pjfanning. I updated my earlier comment to reflect this. |
Aligns the async non-blocking parser's integer-path
NOT_AVAILABLEexits with the length-validation idiom already used by the sync paths and the async fraction path, somaxNumberLengthis enforced consistently across sync and async parsers.The change reuses the existing
_setIntLengthhelper at each of the integer-path streaming-suspension points inNonBlockingUtf8JsonParserBase(_startPositiveNumber(int),_startNegativeNumber(),_startPositiveNumber()no-arg,_finishNumberIntegralPart()).Tests
AsyncNumberLengthConsistencyTestpins both the integer- and fraction-path streaming behavior under digit-only chunks.mvn test: 1437 tests run, 0 failures, 0 errors, 2 skipped (pre-existing).Happy to reword / split / amend per maintainer preference.