question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

SSLHandshakeException using a Proxy Config

See original GitHub issue

See:

https://groups.google.com/forum/#!topic/membrane-monitor/Q53ewuB6ZFg

Hi,

More news today. I’ve try to make a test with a java core batch in the same context (same server, same proxy…) :

    public static void main(String[] args) throws Exception {

    CloseableHttpClient httpclient = HttpClients.createDefault();

    try {

    HttpHost target = new HttpHost("www.google.de", 443, "https");

    HttpHost proxy = new HttpHost("gateway.xxxx.zzzzz.net", 80, "http");


    RequestConfig config = RequestConfig.custom().setProxy(proxy).build();

    HttpGet request = new HttpGet("/");

    request.setConfig(config);


    CloseableHttpResponse response = httpclient.execute(target, request);

    try {

    System.out.println(response.getStatusLine());

    EntityUtils.consume(response.getEntity());

    } 

    } 

    }

–> It’s work : HTTP/1.1 200 OK

If I switch “http” by “https” in this line

HttpHost proxy = new HttpHost("gateway.xxxx.zzzzz.net", 80, "https");

I get the same error than with membrane :

Exception in thread "main" javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake [...]

–> It’s sounds like membrane try to access to my proxy server with HTTPS protocol instead HTTP.

Do you know how can I force membrane to access to my proxy with HTTP protocol ?

Best Regards.

Issue Analytics

  • State:closed
  • Created 10 years ago
  • Comments:17 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
rraystcommented, Nov 4, 2016

Hi @saraivamarco . Sorry, the homepage hasn’t been updated yet. You can find the release on https://github.com/membrane/service-proxy/releases/tag/v4.2.3 .

1reaction
malsmith-cscommented, Aug 16, 2016

Change set looks good to me. You may need to consider the copy right block in this https://docs.oracle.com/javase/7/docs/technotes/guides/security/jsse/samples/sockets/client/SSLSocketClientWithTunneling.java

It’s open source but it should have a proper reference for the doTunnelHankshake function.

Read more comments on GitHub >

github_iconTop Results From Across the Web

HTTPS Connections with Proxy cause SSLHandshakeException
In this case the proxy is tampering with the SSL, e.g. it does a man-in-the-middle attack (also called SSL interception in some firewalls...
Read more >
Forms 12c + HTTPS + Behind a Proxy - javax.net.ssl ...
Hello, I've just finished to install Forms 12c and my application. Everything works fine with HTTP.
Read more >
Received fatal alert: certificate_unknown" error in BrowserMob ...
When you use BrowserMob-Proxy to capture HTTPs traffic you might encounter "SSLHandshakeException: Received fatal alert: certificate_unknown" error in ...
Read more >
SSL handshake exception connecting to Salesforce via proxy ...
The connection to Saleforce is through a proxy server. The issue is observed in spite of using the latest JVM verison.
Read more >
Get Started -> SSLHandshakeException via Proxy server
Hi Team,. Getting error only when I use my proxy setting bellow three lines on the java code, code works fine without the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found