oscerd opened a new pull request, #22768: URL: https://github.com/apache/camel/pull/22768
## Backport of #22637 (which itself backported #22613) Cherry-pick of #22637 onto `camel-4.14.x`. The upstream change (CAMEL-23324) adds defense-in-depth deserialization filtering for the HTTP transports, extending the pattern already applied in CAMEL-23297 (camel-netty), CAMEL-23319 (camel-mina) and CAMEL-23321 (camel-jms/sjms/amqp). **Original PR:** #22613 — CAMEL-23324 **4.18.x backport:** #22637 — merged commit `a3835afef10` **Original author:** @oscerd **Target branch:** `camel-4.14.x` ### Conflict resolution Conflicts appeared in 6 generated files (catalog + uri-factory + component JSON) because 4.14.x still has the deprecated `keyStoreFile`/`trustStoreFile` options that were removed on 4.18.x/main. Resolved all generated-file conflicts by taking the 4.14.x (`--ours`) baseline, then ran a full regen on `camel-netty-http`, `camel-vertx-http`, `camel-endpointdsl`, and `camel-catalog` against 4.14.x to produce the correct merged output (final commit: `CAMEL-23324: Regen for 4.14.x`). The Java source (`NettyHttpConfiguration`, `NettyHttpHelper`, `NettyHttpProducer`, `VertxHttpConfiguration`, `VertxHttpHelper`, `DefaultVertxHttpBinding`) merged cleanly on both branches. ### Bundled commits The 4.18.x backport also bundled `CAMEL-23214: Harden NettyHttpSSLHandshakeErrorTest against Netty exception wrapping` to unblock CI on a pre-existing 4.18.x flake. Keeping that commit here as well — 4.14.x does not yet have the CAMEL-23214 fix and the same CI environment is likely to surface the same SSLHandshakeException wrapping behavior. ### Original description Extends the defense-in-depth deserialization filtering pattern applied in CAMEL-23297 (camel-netty), CAMEL-23319 (camel-mina) and CAMEL-23321 (camel-jms/sjms/amqp) to the HTTP transports. - `NettyHttpHelper.deserializeJavaObjectFromStream` and `VertxHttpHelper.deserializeJavaObjectFromStream` now apply an `ObjectInputFilter` on the `ObjectInputStream` used when reading `application/x-java-serialized-object` payloads. - Filter resolution priority: configured pattern → JVM `-Djdk.serialFilter` → default `java.**;javax.**;org.apache.camel.**;!*` - Configured pattern exposed as a new endpoint option `deserializationFilter` (label `advanced,security`, matching the JMS counterpart) on `NettyHttpConfiguration` and `VertxHttpConfiguration`, wired through `NettyHttpProducer` and `DefaultVertxHttpBinding`. Link: https://issues.apache.org/jira/browse/CAMEL-23324 ### Test plan - [x] `mvn clean install -DskipTests -pl :camel-netty-http,:camel-vertx-http,:camel-endpointdsl,:camel-catalog -am` → BUILD SUCCESS - [x] `mvn test-compile -pl :camel-netty-http,:camel-vertx-http -am` → BUILD SUCCESS - [x] Generated files only contain `deserializationFilter` additions; no unrelated version-bump noise --- _Backport performed by Claude Code on behalf of Andrea Cosentino._ -- 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]
