hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@urbancode.com
Subject Re: HttpClient & SSL/TLS bad_record_mac error
Date Mon, 13 Feb 2006 23:05:14 GMT
Sorry, for not mentioning it, and perhaps it doesn't make a difference,
but I am using HttpClient 2.0 series.  If this is the wrong mailing list,
i appologize, the link on
http://jakarta.apache.org/commons/httpclient/2.0/mail-lists.html do not
work.

Doing coding is fine. System properties would have just been simpler.
Thank you, any more details on how I may fix it (w/ code or otherwise).

-Jeff


> On Mon, 2006-02-13 at 17:35 -0500, jwa@urbancode.com wrote:
>> I am trying to use the HttpClient over ssl with our server and am having
>> troubles with "bad_record_mac" errors.
>>
>> Using just sockets (not httpclient) I was able to get the connection to
>> work by
>> ((SSLSocket)ssl).setEnabledProtocols(new String[] {"SSLv3"});
>>
>> However, I need to get the HttpClient to work as well.  When I attempt
>> to
>> use HttpClient I get sill get the "bad_record_mac" error.  How can make
>> it
>> only use the SSLv3 connection and not TLS (which i believe is where the
>> error is coming from)? And this may seem silly, but this is actually a
>> part of another project that I am using, I would prefer it if this can
>> be
>> accomplished through setting some system properties/environment
>> variables
>> and minimizing the amount of custom code.
>>
>
> Jeff,
>
> HttpClient 3.0 does not make use of any system properties. There is no
> way around writing _some_ code. For details see the HttpClient SSL guide
>
> http://jakarta.apache.org/commons/httpclient/sslguide.html
>
> Oleg
>
>
>
>> Exception in thread "main" javax.net.ssl.SSLException: Received fatal
>> alert: bad_record_mac
>> 	at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.a(DashoA12275)
>> 	at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.b(DashoA12275)
>> 	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.b(DashoA12275)
>> 	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
>> 	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA12275)
>> 	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
>> 	at com.sun.net.ssl.internal.ssl.AppOutputStream.write(DashoA12275)
>> 	at
>> org.apache.commons.httpclient.HttpConnection$WrappedOutputStream.write(HttpConnection.java:1368)
>> 	at
>> java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:66)
>> 	at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:124)
>> 	at
>> org.apache.commons.httpclient.HttpConnection.flushRequestOutputStream(HttpConnection.java:799)
>> 	at
>> org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:2277)
>> 	at
>> org.apache.commons.httpclient.HttpMethodBase.processRequest(HttpMethodBase.java:2657)
>> 	at
>> org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1093)
>> 	at
>> org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:675)
>> 	at
>> org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:529)
>> 	at SSLTestClient.testIntranetB(SSLTestClient.java:126)
>> 	at SSLTestClient.main(SSLTestClient.java:47)
>>
>>
>> Any insight that you can offer into this problem would be greatly
>> appreciated.
>>
>> Thank you very much for your help,
>> Jeff
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: httpclient-user-help@jakarta.apache.org
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: httpclient-user-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-user-help@jakarta.apache.org


Mime
View raw message