Croway commented on PR #26872:
URL: https://github.com/apache/camel/pull/26872#issuecomment-5830176234

   Thanks for this, the consolidation of the servlet/jetty copies looks correct 
and the tests cover the edge cases well.
   
   One gap with respect to the ticket: CAMEL-24650 lists 
`VertxPlatformHttpConsumer` as the third copy to consolidate, and it is the one 
that still behaves differently. It keeps the substring match 
(`fileNameExtWhitelist.contains(ext)`), so on `main`, 
`platform-http:/upload?fileNameExtWhitelist=txt` still accepts uploads named 
`evil.x`, `evil.t` or `evil.xt`. I checked this with a quick test against 
`VertxPlatformHttpConsumer`. That is the exact behaviour CAMEL-24427 fixed for 
servlet and jetty.
   
   Since camel-platform-http-vertx doesn't depend on camel-http-common, but 
both depend on `camel-http-base`, a small static helper there would let all 
three call sites share one implementation, as suggested in 
[CAMEL-24652](https://issues.apache.org/jira/browse/CAMEL-24652). 
`DefaultHttpBinding.isFileNameAccepted` could then delegate to it.
   
   Also note that CAMEL-24652 (assigned to @oscerd) tracks the same 
consolidation plus the Vert.x alignment, so the two tickets overlap. It would 
be good to agree which one this PR resolves, and close the other as a duplicate 
or link it.
   
   _Claude Code on behalf of Croway_
   


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