lymerin opened a new pull request, #7757:
URL: https://github.com/apache/shenyu/pull/7757

   Fixes #7734
   
   ### Problem
   
   RPC parameter transformation decodes form bodies before splitting parameter 
pairs. The query path similarly uses the already-decoded `URI.getQuery()` and 
then decodes individual parameters again.
   
   As a result, `value=a%26b%3Dc` becomes `{"value":"a","b":"c"}` instead of 
`{"value":"a&b=c"}`. Query values such as `plus=a%2Bb` become `a b` instead of 
`a+b`.
   
   ### Impact
   
   Valid RPC arguments containing encoded delimiters are split into extra 
fields or truncated. Query arguments also lose literal plus signs through 
double decoding. The corruption occurs while constructing RPC argument JSON.
   
   ### Changes
   
   - Split raw form parameters before decoding individual names and values once.
   - Use the raw query string so the existing converter performs a single 
decoding pass.
   - Preserve empty values and the existing repeated-key behavior: first value 
for forms, last value for queries.
   
   Strengthen the form regression test and add a separate query test through 
the plugin’s public `execute()` path.
   
   ### Validation
   
   - `RpcParamTransformPluginTest`: 7 tests passed.
   - `HttpParamConverterTest`: 4 tests passed.
   - Related modules compiled successfully.
   - Checkstyle and Apache RAT checks passed.
   
   ### Checklist
   
   Make sure that:
   
   - [x] You have read the [[contribution 
guidelines](https://shenyu.apache.org/community/contributor-guide)](https://shenyu.apache.org/community/contributor-guide).
   - [x] You submit test cases (unit or integration tests) that back your 
changes.
   - [x] Your local test passed `./mvnw clean install 
-Dmaven.javadoc.skip=true`.


-- 
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