Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RestClient not working with SNI enabled endpoint #337

Open
todzheng opened this issue May 9, 2017 · 2 comments
Open

RestClient not working with SNI enabled endpoint #337

todzheng opened this issue May 9, 2017 · 2 comments

Comments

@todzheng
Copy link

todzheng commented May 9, 2017

with Ribbon RestClient 2.2.0 and Apache HttpClient4.5.2, invoking an SNI enabled endpoint results in "handshake_failure" because server_name extension is not in SSL handshake.

While directly using Apache HttpClient4.5.2 can successfully negotiate and server_name extension is successful.

RestClient 2.2.0 appears to be using SSLSocketFactory which is deprecated by apache; while directly using Apache HttpClient uses SSLConnectionSocketFactory.

Is there any workaround?

@clatko
Copy link

clatko commented Nov 13, 2018

SNI needs to be added as an SSLParameter to the SSLEngine. That engine is only created in rxNetty, but has been overriden in LoadBalancingHttpClient - https://github.com/Netflix/ribbon/blob/master/ribbon-transport/src/main/java/com/netflix/ribbon/transport/netty/http/LoadBalancingHttpClient.java#L510

You would have to add code there or modify rxNetty. I really don't think there is a clean way to do it without the rxNetty modification.

clatko added a commit to clatko/ribbon that referenced this issue Nov 14, 2018
@clatko
Copy link

clatko commented Nov 14, 2018

#391

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

No branches or pull requests

2 participants