You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by "rpamu-jdev (via GitHub)" <gi...@apache.org> on 2026/06/12 10:12:22 UTC
[PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
rpamu-jdev opened a new pull request, #23987:
URL: https://github.com/apache/camel/pull/23987
## Description
After upgrading to httpclient 5.6, `NoopHostnameVerifier` stopped working for users
with self-signed certificates. The root cause is that 5.6 changed the default
`HostnameVerificationPolicy` to `BOTH`, which adds a JDK built-in hostname check
that runs before the configured verifier and cannot be bypassed by it.
To fix this I added a `hostnameVerificationPolicy` option to `HttpComponent` and
`HttpEndpoint` with three values:
- `CLIENT` (default) — only the configured `x509HostnameVerifier` runs, same as pre-5.6
- `BUILTIN` — only the JDK check runs
- `BOTH` — both run; `NoopHostnameVerifier` cannot bypass the JDK check
Default is `CLIENT` so existing setups are not affected.
## Target
- [x] I checked that the commit is targeting the correct branch (Camel 4 uses the `main` branch)
## Tracking
- [x] I checked there is a [JIRA issue](https://issues.apache.org/jira/browse/CAMEL-23743) filed for the change.
## Apache Camel coding standards and style
- [x] I checked that each commit in the pull request has a meaningful subject line and body.
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "rpamu-jdev (via GitHub)" <gi...@apache.org>.
rpamu-jdev commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4691083298
>
Done, added the upgrade guide entry under the existing === camel-http section in camel-4x-upgrade-guide-4_21.adoc.
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4693030527
<!-- ci-tested-modules -->
:test_tube: **CI tested the following changed modules:**
- `catalog/camel-catalog`
- `components/camel-http`
- `docs`
- `dsl/camel-componentdsl`
- `dsl/camel-endpointdsl`
> :information_source: Dependent modules were not tested because the total number of affected modules exceeded the threshold (50). Use the `test-dependents` label to force testing all dependents.
<details><summary>Build reactor — dependencies compiled but only changed modules were tested (5 modules)</summary>
- Camel :: Catalog :: Camel Catalog
- Camel :: Component DSL
- Camel :: Docs
- Camel :: Endpoint DSL
- Camel :: HTTP
</details>
---
:gear: [View full build and test results](https://github.com/apache/camel/actions/runs/27426531542)
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "Croway (via GitHub)" <gi...@apache.org>.
Croway commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4693085071
> > there are uncommitted changes,
> > ```
> > There are uncommitted changes
> > HEAD detached at pull/23987/merge
> > Changes not staged for commit:
> > (use "git add <file>..." to update what will be committed)
> > (use "git restore <file>..." to discard changes in working directory)
> > modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpComponentBuilderFactory.java
> > modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpsComponentBuilderFactory.java
> > modified: dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/HttpEndpointBuilderFactory.java
> > ```
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > please `cd dsl && mvn clean install -DskipTests` and push the generated files
>
> Hi @Croway, thank you for the guidance. I have regenerated the DSL files as suggested and pushed the changes. This is my first contribution to Apache Camel and I am still getting familiar with the build process. Please let me know if anything else needs to be addressed.
no worries, when updating uri endpoint parameters the process is not so straightforward.
Thanks for the contribution!
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "Croway (via GitHub)" <gi...@apache.org>.
Croway merged PR #23987:
URL: https://github.com/apache/camel/pull/23987
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4691007932
:star2: Thank you for your contribution to the Apache Camel project! :star2:
:robot: CI automation will test this PR automatically.
:camel: Apache Camel Committers, please review the following items:
* First-time contributors **require MANUAL approval** for the GitHub Actions to run
* You can use the command `/component-test (camel-)component-name1 (camel-)component-name2..` to request a test from the test bot although they are normally detected and executed by CI.
* You can label PRs using `skip-tests` and `test-dependents` to fine-tune the checks executed by this PR.
* Build and test logs are available in the summary page. **Only** [Apache Camel committers](https://camel.apache.org/community/team/#committers) have access to the summary.
:warning: Be careful when sharing logs. Review their contents before sharing them publicly.
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "rpamu-jdev (via GitHub)" <gi...@apache.org>.
rpamu-jdev commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4692844906
> there are uncommitted changes,
>
> ```
> There are uncommitted changes
> HEAD detached at pull/23987/merge
> Changes not staged for commit:
> (use "git add <file>..." to update what will be committed)
> (use "git restore <file>..." to discard changes in working directory)
> modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpComponentBuilderFactory.java
> modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpsComponentBuilderFactory.java
> modified: dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/HttpEndpointBuilderFactory.java
> ```
>
> please `cd dsl && mvn clean install -DskipTests` and push the generated files
Hi @Croway, thank you for the guidance. I have regenerated the DSL files as suggested and pushed the changes. This is my first contribution to Apache Camel and I am still getting familiar with the build process. Please let me know if anything else needs to be addressed.
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "davsclaus (via GitHub)" <gi...@apache.org>.
davsclaus commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4691263544
There are uncommitted changes
HEAD detached at pull/23987/merge
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/http.json
modified: catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/https.json
modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpComponentBuilderFactory.java
modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpsComponentBuilderFactory.java
modified: dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/HttpEndpointBuilderFactory.java
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] CAMEL-23743: Add hostnameVerificationPolicy option to HttpComponent/HttpEndpoint [camel]
Posted by "Croway (via GitHub)" <gi...@apache.org>.
Croway commented on PR #23987:
URL: https://github.com/apache/camel/pull/23987#issuecomment-4692361042
there are uncommitted changes,
```
There are uncommitted changes
HEAD detached at pull/23987/merge
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpComponentBuilderFactory.java
modified: dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HttpsComponentBuilderFactory.java
modified: dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/HttpEndpointBuilderFactory.java
```
please `cd dsl && mvn clean install -DskipTests` and push the generated files
--
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: commits-unsubscribe@camel.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org