Return-Path: Mailing-List: contact commons-httpclient-dev-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list commons-httpclient-dev@jakarta.apache.org Received: (qmail 12146 invoked from network); 27 Feb 2003 12:48:22 -0000 Received: from fep01-0.kolumbus.fi (HELO fep01-app.kolumbus.fi) (193.229.0.41) by daedalus.apache.org with SMTP; 27 Feb 2003 12:48:22 -0000 Received: from mailsrv.hotelmarketing.fi ([194.241.99.253]) by fep01-app.kolumbus.fi with SMTP id <20030227124822.ZYJB639.fep01-app.kolumbus.fi@mailsrv.hotelmarketing.fi> for ; Thu, 27 Feb 2003 14:48:22 +0200 Received: from SMTP agent by mail gateway Thu, 27 Feb 2003 14:59:08 --200 Received: by MAILSRV with Internet Mail Service (5.5.2653.19) id ; Thu, 27 Feb 2003 14:49:31 +0200 Message-ID: From: Jani Mattsson To: "'commons-httpclient-dev@jakarta.apache.org'" Subject: Having problems with HTTPS proxy tunneling Date: Thu, 27 Feb 2003 14:49:29 +0200 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2653.19) Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C2DE5E.AAB0F0D0" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N ------_=_NextPart_001_01C2DE5E.AAB0F0D0 Content-Type: text/plain Hi! I am using commons-httpclient in a setup where I'm making connections to a secure HTTPS server over a proxy server. I use POST-requests, and the first request always works fine (albeit a bit slow because of SSL handshaking or something). Subsequent request work fine if I do them soon enough after the first request, but if there's been a longer pause I seem to run into trouble. The cause of the trouble seems to be either the remote HTTPS server or my local proxy server (do not know which) dropping the tunneling connection that httpclient creates during the first request. The results of which seem to vary: sometimes HttpClient.executeMethod() throws a HttpRecoverableException to me, sometimes a java.net.SocketException is thrown somewhere down in the call (HttpMethodBase.writeRequestHeaders there somewhere along the line) and HttpClient tries a retry on its own. I get around the first case by just creating a new PostMethod instance and retrying the very same request with it, works fine, but I'm stuck right now with the second case. It seem HttpClient won't try tunneling another time but just sends a "POST https://remote.host.com/foo/bar HTTP/1.1" request to I do not know whom (my proxy or the remote server?), gets a "HTTP/1.0 200 OK" response and then nothing more. I do not know if the problem is with HttpClient or with either uncompliant proxy or remote server. Is there any way to turn any tunneling off altogether to see if the first request would succeed in non-tunneling proxy mode? (I do not know the details of the HTTPS proxying protocol, but I suppose the tunneling is optional?!) Any other ideas/hints about this? All help is highly appreciated. Best regards, Jani Mattsson ------_=_NextPart_001_01C2DE5E.AAB0F0D0--