gnodet opened a new pull request, #2968:
URL: https://github.com/apache/cxf/pull/2968

   ## Summary
   `FormUtils.isFormPostRequest()` uses `equals()` to match the content type, 
but in practice the `Content-Type` header can include parameters like 
`application/x-www-form-urlencoded; charset=UTF-8`.
   
   This is extremely common — jQuery's `$.ajax()` sends exactly this content 
type by default. With the current code, form POST data is silently not 
recognized for these requests.
   
   The fix uses `startsWith` instead of `equals`, consistent with how 
`FormEncodingProvider` already handles content types with charset parameters 
(see `FormEncodingProviderTest` lines 
[264](https://github.com/apache/cxf/blob/main/rt/frontend/jaxrs/src/test/java/org/apache/cxf/jaxrs/provider/FormEncodingProviderTest.java#L264)
 and 
[283](https://github.com/apache/cxf/blob/main/rt/frontend/jaxrs/src/test/java/org/apache/cxf/jaxrs/provider/FormEncodingProviderTest.java#L283)).
   
   Split out from #2955 per review feedback.
   
   ## Test plan
   - [x] `rt/frontend/jaxrs` module compiles and tests pass
   
   🤖 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]

Reply via email to