dashorst opened a new pull request, #1928: URL: https://github.com/apache/wicket/pull/1928
Fixes the intermittent `CryptoMapperTest` failures analysed in #1923. The change is test-only. `bookmarkablePageDecryptMultipleCryptoMapper`, `pageInstanceDecryptMultipleCryptoMapper` and the second half of `mountedPageRequestListenerParameter` wrapped the test mapper in a second `CryptoMapper` built from the application. That outer mapper uses the default `KeyInSessionSunJceCryptFactory`, which generates a random key per session. PBEWithMD5AndDES has no integrity check. In about 1 in 256 runs, decrypting the inner mapper's URL with that wrong key yields valid padding, so the outer mapper passes on a garbage URL instead of `null`. The outer mapper now gets its own fixed `SunJceCrypt` key, so the result is the same in every run. Testing: - Before the change, the page-instance test failed 7 times in 2000 repeats, on Java 17 and on Java 25. - After the change, each of the three tests passes 2000 repeats with no failures. - A full `mvn clean verify` on Java 25 passes. master and 11.x use authenticated AES-GCM, where a wrong key always fails, so they need no change. If a 9.x license cleanup release is cut, this commit should be cherry-picked onto wicket-9.x. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
