Skip to content

Conversation

@arturobernalg
Copy link
Member

Add setTlsOnly(boolean) to classic and async builders to reject cleartext routes.
Install an internal exec interceptor that fails fast when the computed route is not secure.
Includes small sync + async examples in Javadoc.

@arturobernalg arturobernalg requested a review from ok2c January 8, 2026 09:46
@arturobernalg arturobernalg changed the title HTTPCLIENT-2397 - Enforce TLS-only routes (opt-in) HTTPCLIENT-2397 - Enforce TLS-Required routes (opt-in) Jan 8, 2026
@arturobernalg arturobernalg force-pushed the HTTPCLIENT-2397 branch 2 times, most recently from 38c0392 to 7196331 Compare January 8, 2026 13:28
authCachingDisabled),
ChainElement.PROTOCOL.name());

if (this.tlsRequired) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@arturobernalg Would not it be better to put this interceptor at the very beginning of the pipeline?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ok2c fine by me. changed.

…ic and async builders to reject cleartext routes.

Fail fast with UnsupportedSchemeException when the computed route is not secure.
@arturobernalg arturobernalg merged commit 68435f2 into apache:master Jan 10, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants