[HTTPClient] Problems to connect to a proxy

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

[HTTPClient] Problems to connect to a proxy

Pauline CANTALOUP
Hello

I have to connect to a proxy in order to reach a website. So I wrote :
        try {
            HttpClient client = new HttpClient();
            HostConfiguration hostConfig=new HostConfiguration();
            hostConfig.setProxy("192.168.10.225",8888);
            client.setHostConfiguration(hostConfig);

            NTCredentials ntc=new
NTCredentials("user","pass","pc-cantaloup","tls");
            client.getState().setProxyCredentials(AuthScope.ANY,ntc);
            GetMethod method = new GetMethod(url);
            method.setFollowRedirects(true);

            // Execute the GET method
            int statusCode = client.executeMethod(method);
            if (statusCode != -1) {
                String contents = method.getResponseBodyAsString();
                method.releaseConnection();
                System.out.println(contents);
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
In traces, I readed : "INFO: ntlm authentication scheme selected" so I
supposed the library choose the authentication type by itself. But then I
have this error :

30 mai 2005 14:02:04 org.apache.commons.httpclient.HttpMethodDirector
processProxyAuthChallenge
INFO: Failure authenticating with NTLM <any realm>@192.168.10.225:8888

I thought it was perhaps a problem of encryption so I added :

        try {
        String secProviderName = "com.sun.crypto.provider.SunJCE";
        java.security.Provider secProvider =
 
(java.security.Provider)Class.forName(secProviderName).newInstance();
        Security.addProvider(secProvider);
        }catch(Exception e) {
            e.printStackTrace();
        }

But nothing changed. The man who manages proxy said he didn't see my request
for authentication.
So what could I try ?
Thanks in advance for your help !

Pauline Cantaloup
--
123 Multimédia
Service mobilité
05.61.43.16.68


D?charge / Disclaimer

Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration, 123Multim?dia et ses filiales d?clinent toute responsabilit? au titre de ce message s'il a ?t? alt?r?, d?form? ou falsifi?.

This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or falsified.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [HTTPClient] Problems to connect to a proxy

olegk
Pauline,

Please post the complete wire/context log of the HTTP session.

http://jakarta.apache.org/commons/httpclient/3.0/logging.html

Oleg

On Mon, May 30, 2005 at 02:24:48PM +0200, Pauline CANTALOUP wrote:

> Hello
>
> I have to connect to a proxy in order to reach a website. So I wrote :
>         try {
>             HttpClient client = new HttpClient();
>             HostConfiguration hostConfig=new HostConfiguration();
>             hostConfig.setProxy("192.168.10.225",8888);
>             client.setHostConfiguration(hostConfig);
>
>             NTCredentials ntc=new
> NTCredentials("user","pass","pc-cantaloup","tls");
>             client.getState().setProxyCredentials(AuthScope.ANY,ntc);
>             GetMethod method = new GetMethod(url);
>             method.setFollowRedirects(true);
>
>             // Execute the GET method
>             int statusCode = client.executeMethod(method);
>             if (statusCode != -1) {
>                 String contents = method.getResponseBodyAsString();
>                 method.releaseConnection();
>                 System.out.println(contents);
>             }
>         } catch (Exception e) {
>             e.printStackTrace();
>         }
> In traces, I readed : "INFO: ntlm authentication scheme selected" so I
> supposed the library choose the authentication type by itself. But then I
> have this error :
>
> 30 mai 2005 14:02:04 org.apache.commons.httpclient.HttpMethodDirector
> processProxyAuthChallenge
> INFO: Failure authenticating with NTLM <any realm>@192.168.10.225:8888
>
> I thought it was perhaps a problem of encryption so I added :
>
>         try {
>         String secProviderName = "com.sun.crypto.provider.SunJCE";
>         java.security.Provider secProvider =
>  
> (java.security.Provider)Class.forName(secProviderName).newInstance();
>         Security.addProvider(secProvider);
>         }catch(Exception e) {
>             e.printStackTrace();
>         }
>
> But nothing changed. The man who manages proxy said he didn't see my request
> for authentication.
> So what could I try ?
> Thanks in advance for your help !
>
> Pauline Cantaloup
> --
> 123 Multim?dia
> Service mobilit?
> 05.61.43.16.68
>
>
> D?charge / Disclaimer
>
> Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration,
>
> This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiari
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: [HTTPClient] Problems to connect to a proxy

Pauline CANTALOUP
In reply to this post by Pauline CANTALOUP
Sorry, here are logs. I don't understand lines
"2005/05/30 14:40:47:676 CEST [DEBUG] HttpMethodDirector - Proxy credentials
required
2005/05/30 14:40:47:692 CEST [DEBUG] HttpMethodDirector - Proxy credentials
provider not available"
Does it mean I didn't set credentials in the right object ?

2005/05/30 14:40:46:973 CEST [DEBUG] HttpClient - Java version: 1.5.0_01
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - Java vendor: Sun
Microsystems Inc.
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - Java class path:
C:\eclipse\workspace\CheckHeaders\webapp\WEB-INF\classes;C:\eclipse\workspace
\CheckHeaders\webapp\WEB-INF\lib\commons-logging.jar;C:\eclipse\workspace\Che
ckHeaders\webapp\WEB-INF\lib\commons-httpclient-3.0-rc2.jar;C:\eclipse\worksp
ace\CheckHeaders\webapp\WEB-INF\lib\commons-codec-1.3.jar
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - Operating system name:
Windows XP
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - Operating system
architecture: x86
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - Operating system version:
5.1
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - SUN 1.5: SUN (DSA
key/parameter generation; DSA signing; SHA-1, MD5 digests; SecureRandom;
X.509 certificates; JKS keystore; PKIX CertPathValidator; PKIX
CertPathBuilder; LDAP, Collection CertStores)
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - SunRsaSign 1.5: Sun RSA
signature provider
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - SunJSSE 1.5: Sun JSSE
provider(PKCS12, SunX509 key/trust factories, SSLv3, TLSv1)
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - SunJCE 1.5: SunJCE Provider
(implements RSA, DES, Triple DES, AES, Blowfish, ARCFOUR, RC2, PBE,
Diffie-Hellman, HMAC)
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - SunJGSS 1.0: Sun (Kerberos
v5)
2005/05/30 14:40:47:004 CEST [DEBUG] HttpClient - SunSASL 1.5: Sun SASL
provider(implements client mechanisms for: DIGEST-MD5, GSSAPI, EXTERNAL,
PLAIN, CRAM-MD5; server mechanisms for: DIGEST-MD5, GSSAPI, CRAM-MD5)
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.useragent = Jakarta Commons-HttpClient/3.0-rc2
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.version = HTTP/1.1
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.connection-manager.class = class
org.apache.commons.httpclient.SimpleHttpConnectionManager
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.cookie-policy = rfc2109
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.element-charset = US-ASCII
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.content-charset = ISO-8859-1
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.method.retry-handler =
org.apache.commons.httpclient.DefaultHttpMethodRetryHandler@d251a3
2005/05/30 14:40:47:020 CEST [DEBUG] DefaultHttpParams - Set parameter
http.dateparser.patterns = [EEE, dd MMM yyyy HH:mm:ss zzz, EEEE, dd-MMM-yy
HH:mm:ss zzz, EEE MMM d HH:mm:ss yyyy, EEE, dd-MMM-yyyy HH:mm:ss z, EEE,
dd-MMM-yyyy HH-mm-ss z, EEE, dd MMM yy HH:mm:ss z, EEE dd-MMM-yyyy HH:mm:ss
z, EEE dd MMM yyyy HH:mm:ss z, EEE dd-MMM-yyyy HH-mm-ss z, EEE dd-MMM-yy
HH:mm:ss z, EEE dd MMM yy HH:mm:ss z, EEE,dd-MMM-yy HH:mm:ss z,
EEE,dd-MMM-yyyy HH:mm:ss z, EEE, dd-MM-yyyy HH:mm:ss z]
2005/05/30 14:40:47:145 CEST [DEBUG] HttpConnection - Open connection to
192.168.10.225:8888
2005/05/30 14:40:47:192 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
HTTP/1.1[\r][\n]"
2005/05/30 14:40:47:192 CEST [DEBUG] HttpMethodBase - Adding Host request
header
2005/05/30 14:40:47:207 CEST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.0-rc2[\r][\n]"
2005/05/30 14:40:47:207 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
2005/05/30 14:40:47:207 CEST [DEBUG] header - >> "Proxy-Connection:
Keep-Alive[\r][\n]"
2005/05/30 14:40:47:207 CEST [DEBUG] header - >> "[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
Authentication Required[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Server:
squid/2.5.STABLE9[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Date: Mon, 30 May 2005
12:40:47 GMT[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Content-Type:
text/html[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Content-Length:
1462[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Expires: Mon, 30 May 2005
12:40:47 GMT[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "X-Squid-Error:
ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Proxy-Authenticate:
NTLM[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Proxy-Authenticate: Basic
realm="Squid proxy-caching web server"[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "X-Cache: MISS from
ProxyA[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] header - << "Proxy-Connection:
close[\r][\n]"
2005/05/30 14:40:47:223 CEST [DEBUG] HttpMethodDirector - Authorization
required
2005/05/30 14:40:47:238 CEST [DEBUG] AuthChallengeProcessor - Supported
authentication schemes in the order of preference: [ntlm, digest, basic]
2005/05/30 14:40:47:238 CEST [INFO] AuthChallengeProcessor - ntlm
authentication scheme selected
2005/05/30 14:40:47:238 CEST [DEBUG] AuthChallengeProcessor - Using
authentication scheme: ntlm
2005/05/30 14:40:47:238 CEST [DEBUG] AuthChallengeProcessor - Authorization
challenge processed
2005/05/30 14:40:47:238 CEST [DEBUG] HttpMethodDirector - Proxy
authentication scope: NTLM <any realm>@192.168.10.225:8888
2005/05/30 14:40:47:238 CEST [DEBUG] HttpMethodDirector - Retry
authentication
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<HTML><HEAD><META
HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
Acc&egrave;s au cache interdit</TITLE>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<STYLE
type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</HEAD>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<BODY>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
interdit</H2>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "En essayant de charger
l'URL&nbsp;:[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<A
HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "L'erreur suivante a
&eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<UL>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<LI>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<STRONG>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "Acc&egrave;s au cache
interdit.[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</STRONG>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</UL>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "&agrave; demander[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<PRE>
http://www.yahoo.fr/</PRE>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "&agrave; ce cache tant que
vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "Vous avez besoin de
Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
un "
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "navigateur conforme
&agrave; HTTP/1.1 pour que[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "si vous avez des
difficult&eacute;s &agrave; vous authentifier, ou[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<A
HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
passe.[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<BR clear="all">[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "<ADDRESS>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "Generated Mon, 30 May 2005
12:40:47 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</ADDRESS>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
2005/05/30 14:40:47:254 CEST [DEBUG] HttpMethodBase - Should close connection
in response to directive: close
2005/05/30 14:40:47:254 CEST [DEBUG] HttpConnection - Connection is locked.
Call to releaseConnection() ignored.
2005/05/30 14:40:47:270 CEST [DEBUG] HttpMethodDirector - Authenticating with
NTLM <any realm>@192.168.10.225:8888
2005/05/30 14:40:47:285 CEST [DEBUG] HttpMethodParams - Credential charset
not configured, using HTTP element charset
2005/05/30 14:40:47:285 CEST [DEBUG] HttpConnection - Open connection to
192.168.10.225:8888
2005/05/30 14:40:47:301 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
HTTP/1.0[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] HttpMethodBase - Adding Host request
header
2005/05/30 14:40:47:301 CEST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.0-rc2[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - >> "Proxy-Authorization: NTLM
TlRMTVNTUAABAAAABlIAAAMAAwAsAAAADAAMACAAAABQQy1DQU5UQUxPVVBUTFM=[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - >> "Proxy-Connection:
Keep-Alive[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - >> "[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
Authentication Required[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Server:
squid/2.5.STABLE9[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Date: Mon, 30 May 2005
12:40:47 GMT[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Content-Type:
text/html[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Content-Length:
1462[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Expires: Mon, 30 May 2005
12:40:47 GMT[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "X-Squid-Error:
ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Proxy-Authenticate: NTLM
TlRMTVNTUAACAAAAAAAAADAAAAASAgAAE+F7GZvD+bAAAAAAAAAAAAAAAAAwAAAA[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "X-Cache: MISS from
ProxyA[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] header - << "Proxy-Connection:
keep-alive[\r][\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] HttpMethodDirector - Authorization
required
2005/05/30 14:40:47:301 CEST [DEBUG] AuthChallengeProcessor - Using
authentication scheme: ntlm
2005/05/30 14:40:47:301 CEST [DEBUG] AuthChallengeProcessor - Authorization
challenge processed
2005/05/30 14:40:47:301 CEST [DEBUG] HttpMethodDirector - Proxy
authentication scope: NTLM <any realm>@192.168.10.225:8888
2005/05/30 14:40:47:301 CEST [DEBUG] HttpMethodDirector - Retry
authentication
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<HTML><HEAD><META
HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
Acc&egrave;s au cache interdit</TITLE>[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<STYLE
type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "</HEAD>[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<BODY>[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
2005/05/30 14:40:47:301 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
interdit</H2>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "En essayant de charger
l'URL&nbsp;:[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<A
HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "L'erreur suivante a
&eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<UL>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<LI>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<STRONG>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "Acc&egrave;s au cache
interdit.[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</STRONG>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</UL>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "&agrave; demander[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<PRE>
http://www.yahoo.fr/</PRE>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "&agrave; ce cache tant que
vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "Vous avez besoin de
Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
un "
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "navigateur conforme
&agrave; HTTP/1.1 pour que[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "si vous avez des
difficult&eacute;s &agrave; vous authentifier, ou[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<A
HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
passe.[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<BR clear="all">[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "<ADDRESS>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "Generated Mon, 30 May 2005
12:40:47 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</ADDRESS>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
2005/05/30 14:40:47:317 CEST [DEBUG] HttpMethodBase - Should NOT close
connection in response to directive: keep-alive
2005/05/30 14:40:47:317 CEST [DEBUG] HttpConnection - Connection is locked.
Call to releaseConnection() ignored.
2005/05/30 14:40:47:317 CEST [DEBUG] HttpMethodDirector - Authenticating with
NTLM <any realm>@192.168.10.225:8888
2005/05/30 14:40:47:317 CEST [DEBUG] HttpMethodParams - Credential charset
not configured, using HTTP element charset
2005/05/30 14:40:47:613 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
HTTP/1.0[\r][\n]"
2005/05/30 14:40:47:613 CEST [DEBUG] HttpMethodBase - Adding Host request
header
2005/05/30 14:40:47:613 CEST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.0-rc2[\r][\n]"
2005/05/30 14:40:47:613 CEST [DEBUG] header - >> "Proxy-Authorization: NTLM
TlRMTVNTUAADAAAAGAAYAGAAAAAAAAAAeAAAAAMAAwBAAAAAEQARAEMAAAAMAAwAVAAAAAAAAAB4A
AAABlIAAFRMU1BBVUxJTkUuQ0FOVEFMT1VQUEMtQ0FOVEFMT1VQA/uQagaqmRXdJR+BBqxQ4gMONR
a81Qhc[\r][\n]"
2005/05/30 14:40:47:613 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
2005/05/30 14:40:47:613 CEST [DEBUG] header - >> "Proxy-Connection:
Keep-Alive[\r][\n]"
2005/05/30 14:40:47:613 CEST [DEBUG] header - >> "[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
Authentication Required[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Server:
squid/2.5.STABLE9[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Date: Mon, 30 May 2005
12:40:47 GMT[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Content-Type:
text/html[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Content-Length:
1462[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Expires: Mon, 30 May 2005
12:40:47 GMT[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "X-Squid-Error:
ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Proxy-Authenticate:
NTLM[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Proxy-Authenticate: Basic
realm="Squid proxy-caching web server"[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "X-Cache: MISS from
ProxyA[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] header - << "Proxy-Connection:
close[\r][\n]"
2005/05/30 14:40:47:676 CEST [DEBUG] HttpMethodDirector - Authorization
required
2005/05/30 14:40:47:676 CEST [DEBUG] AuthChallengeProcessor - Using
authentication scheme: ntlm
2005/05/30 14:40:47:676 CEST [DEBUG] AuthChallengeProcessor - Authorization
challenge processed
2005/05/30 14:40:47:676 CEST [DEBUG] HttpMethodDirector - Proxy
authentication scope: NTLM <any realm>@192.168.10.225:8888
2005/05/30 14:40:47:676 CEST [DEBUG] HttpMethodDirector - Proxy credentials
required
2005/05/30 14:40:47:692 CEST [DEBUG] HttpMethodDirector - Proxy credentials
provider not available
2005/05/30 14:40:47:692 CEST [INFO] HttpMethodDirector - Failure
authenticating with NTLM <any realm>@192.168.10.225:8888
2005/05/30 14:40:47:692 CEST [DEBUG] HttpMethodBase - Buffering response body
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<HTML><HEAD><META
HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
Acc&egrave;s au cache interdit</TITLE>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<STYLE
type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "</HEAD>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<BODY>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
interdit</H2>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "En essayant de charger
l'URL&nbsp;:[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<A
HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "L'erreur suivante a
&eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<UL>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<LI>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<STRONG>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "Acc&egrave;s au cache
interdit.[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "</STRONG>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "</UL>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
2005/05/30 14:40:47:692 CEST [DEBUG] content - << "&agrave; demander[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "<PRE>
http://www.yahoo.fr/</PRE>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "&agrave; ce cache tant que
vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "<P>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "Vous avez besoin de
Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
un navigateur conforme &agrave; HTTP/1.1 pour que[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "si vous avez des
difficult&eacute;s &agrave; vous authentifier, ou[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "<A
HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
passe.[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "</P>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "<BR clear="all">[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "<ADDRESS>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "Generated Mon, 30 May 2005
12:40:47 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "</ADDRESS>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
2005/05/30 14:40:47:707 CEST [DEBUG] HttpMethodBase - Should close connection
in response to directive: close
2005/05/30 14:40:47:707 CEST [DEBUG] HttpConnection - Releasing connection
back to connection manager.
2005/05/30 14:40:47:707 CEST [DEBUG] HttpMethodBase - Default charset used:
ISO-8859-1

-----Message d'origine-----
De : Oleg Kalnichevski [mailto:[hidden email]]
Envoyé : lundi 30 mai 2005 14:35
À : [hidden email]
Objet : Re: [HTTPClient] Problems to connect to a proxy

Pauline,

Please post the complete wire/context log of the HTTP session.

http://jakarta.apache.org/commons/httpclient/3.0/logging.html

Oleg

On Mon, May 30, 2005 at 02:24:48PM +0200, Pauline CANTALOUP wrote:

> Hello
>
> I have to connect to a proxy in order to reach a website. So I wrote :
>         try {
>             HttpClient client = new HttpClient();
>             HostConfiguration hostConfig=new HostConfiguration();
>             hostConfig.setProxy("192.168.10.225",8888);
>             client.setHostConfiguration(hostConfig);
>
>             NTCredentials ntc=new
> NTCredentials("user","pass","pc-cantaloup","tls");
>             client.getState().setProxyCredentials(AuthScope.ANY,ntc);
>             GetMethod method = new GetMethod(url);
>             method.setFollowRedirects(true);
>
>             // Execute the GET method
>             int statusCode = client.executeMethod(method);
>             if (statusCode != -1) {
>                 String contents = method.getResponseBodyAsString();
>                 method.releaseConnection();
>                 System.out.println(contents);
>             }
>         } catch (Exception e) {
>             e.printStackTrace();
>         }
> In traces, I readed : "INFO: ntlm authentication scheme selected" so I
> supposed the library choose the authentication type by itself. But
> then I have this error :
>
> 30 mai 2005 14:02:04 org.apache.commons.httpclient.HttpMethodDirector
> processProxyAuthChallenge
> INFO: Failure authenticating with NTLM <any realm>@192.168.10.225:8888
>
> I thought it was perhaps a problem of encryption so I added :
>
>         try {
>         String secProviderName = "com.sun.crypto.provider.SunJCE";
>         java.security.Provider secProvider =
>  
> (java.security.Provider)Class.forName(secProviderName).newInstance();
>         Security.addProvider(secProvider);
>         }catch(Exception e) {
>             e.printStackTrace();
>         }
>
> But nothing changed. The man who manages proxy said he didn't see my
> request for authentication.
> So what could I try ?
> Thanks in advance for your help !
>
> Pauline Cantaloup
> --
> 123 Multim?dia
> Service mobilit?
> 05.61.43.16.68
>
>
> D?charge / Disclaimer
>
> Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont
> confidentiels et ?tablis ? l'intention exclusive des destinataires.
> Toute utilisation ou diffusion non autoris?e est interdite. Tout
> message ?lectronique ?tant susceptible d'alt?ration,
>
> This message and any attachments (the "message") are confidential and
> intended solely for the addressees. Any unauthorised use or
> dissemination is prohibited. E-mails are susceptible to alteration.
> Therefore neither 123Multim?dia nor any of its subsidiari
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


D?charge / Disclaimer

Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration, 123Multim?dia et ses filiales d?clinent toute responsabilit? au titre de ce message s'il a ?t? alt?r?, d?form? ou falsifi?.

This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or falsified.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [HTTPClient] Problems to connect to a proxy

olegk
Pauline,

As far as I can tell all the requests generated by HttpClient look
perfectly sane. The server simply does not seem to like the credentials
supplied by the client. Are you sure you are using the correct user name
/ password / domain / host params? Any of these four params being
invalid will cause the NTLM scheme to fail.

Actually this is the very time I see Squid proxy configured to use NTLM
authentication. Frankly, I do not know if HttpClient is compatible with
squid's implementation of NTLM auth. Consider using BASIC auth, at least
initially, to test the credentials

Oleg

>> "GET http://www.yahoo.fr/ HTTP/1.1[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
>> "Host: www.yahoo.fr[\r][\n]"
>> "Proxy-Connection: Keep-Alive[\r][\n]"
>> "[\r][\n]"

<< "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
<< "Server: squid/2.5.STABLE9[\r][\n]"
<< "Mime-Version: 1.0[\r][\n]"
<< "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "Content-Type: text/html[\r][\n]"
<< "Content-Length: 1462[\r][\n]"
<< "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
<< "Proxy-Authenticate: NTLM[\r][\n]"
<< "Proxy-Authenticate: Basic realm="Squid proxy-caching web
server"[\r][\n]"
<< "X-Cache: MISS from ProxyA[\r][\n]"
<< "Proxy-Connection: close[\r][\n]"

>> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
>> "Proxy-Authorization: NTLM
>> TlRMTVNTUAABAAAABlIAAAMAAwAsAAAADAAMACAAAABQQy1DQU5UQUxPVVBUTFM=[\r][\n]"
>> "Host: www.yahoo.fr[\r][\n]"
>> "Proxy-Connection: Keep-Alive[\r][\n]"
>> "[\r][\n]"

<< "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
<< "Server: squid/2.5.STABLE9[\r][\n]"
<< "Mime-Version: 1.0[\r][\n]"
<< "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "Content-Type: text/html[\r][\n]"
<< "Content-Length: 1462[\r][\n]"
<< "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
<< "Proxy-Authenticate: NTLM
TlRMTVNTUAACAAAAAAAAADAAAAASAgAAE+F7GZvD+bAAAAAAAAAAAAAAAAAwAAAA[\r][\n]"
<< "X-Cache: MISS from ProxyA[\r][\n]"
<< "Proxy-Connection: keep-alive[\r][\n]"

>> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
>> "Proxy-Authorization: NTLM
>> TlRMTVNTUAADAAAAGAAYAGAAAAAAAAAAeAAAAAMAAwBAAAAAEQARAEMAAAAMAAwAVAAAAAAAAAB4A
>> AAABlIAAFRMU1BBVUxJTkUuQ0FOVEFMT1VQUEMtQ0FOVEFMT1VQA/uQagaqmRXdJR+BBqxQ4gMONR
>> a81Qhc[\r][\n]"
>> "Host: www.yahoo.fr[\r][\n]"
>> "Proxy-Connection: Keep-Alive[\r][\n]"
>> "[\r][\n]"

<< "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
<< "Server: squid/2.5.STABLE9[\r][\n]"
<< "Mime-Version: 1.0[\r][\n]"
<< "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "Content-Type: text/html[\r][\n]"
<< "Content-Length: 1462[\r][\n]"
<< "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
<< "Proxy-Authenticate: NTLM[\r][\n]"
<< "Proxy-Authenticate: Basic realm="Squid proxy-caching web
server"[\r][\n]"
<< "X-Cache: MISS from ProxyA[\r][\n]"
<< "Proxy-Connection: close[\r][\n]"




---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: [HTTPClient] Problems to connect to a proxy

Pauline CANTALOUP
In reply to this post by Pauline CANTALOUP
Thanks, but how can I force basic auth ?

-----Message d'origine-----
De : Oleg Kalnichevski [mailto:[hidden email]]
Envoyé : lundi 30 mai 2005 15:26
À : Jakarta Commons Users List
Objet : Re: [HTTPClient] Problems to connect to a proxy

Pauline,

As far as I can tell all the requests generated by HttpClient look perfectly
sane. The server simply does not seem to like the credentials supplied by the
client. Are you sure you are using the correct user name / password / domain
/ host params? Any of these four params being invalid will cause the NTLM
scheme to fail.

Actually this is the very time I see Squid proxy configured to use NTLM
authentication. Frankly, I do not know if HttpClient is compatible with
squid's implementation of NTLM auth. Consider using BASIC auth, at least
initially, to test the credentials

Oleg

>> "GET http://www.yahoo.fr/ HTTP/1.1[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
>> "Host: www.yahoo.fr[\r][\n]"
>> "Proxy-Connection: Keep-Alive[\r][\n]"
>> "[\r][\n]"

<< "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
<< "Server: squid/2.5.STABLE9[\r][\n]"
<< "Mime-Version: 1.0[\r][\n]"
<< "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "Content-Type: text/html[\r][\n]"
<< "Content-Length: 1462[\r][\n]"
<< "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
<< "Proxy-Authenticate: NTLM[\r][\n]"
<< "Proxy-Authenticate: Basic realm="Squid proxy-caching web server"[\r][\n]"
<< "X-Cache: MISS from ProxyA[\r][\n]"
<< "Proxy-Connection: close[\r][\n]"

>> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
>> "Proxy-Authorization: NTLM
>> TlRMTVNTUAABAAAABlIAAAMAAwAsAAAADAAMACAAAABQQy1DQU5UQUxPVVBUTFM=[\r][\n]"
>> "Host: www.yahoo.fr[\r][\n]"
>> "Proxy-Connection: Keep-Alive[\r][\n]"
>> "[\r][\n]"

<< "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
<< "Server: squid/2.5.STABLE9[\r][\n]"
<< "Mime-Version: 1.0[\r][\n]"
<< "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "Content-Type: text/html[\r][\n]"
<< "Content-Length: 1462[\r][\n]"
<< "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
<< "Proxy-Authenticate: NTLM
TlRMTVNTUAACAAAAAAAAADAAAAASAgAAE+F7GZvD+bAAAAAAAAAAAAAAAAAwAAAA[\r][\n]"
<< "X-Cache: MISS from ProxyA[\r][\n]"
<< "Proxy-Connection: keep-alive[\r][\n]"

>> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
>> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
>> "Proxy-Authorization: NTLM
>> TlRMTVNTUAADAAAAGAAYAGAAAAAAAAAAeAAAAAMAAwBAAAAAEQARAEMAAAAMAAwAVAAAA
>> AAAAAB4A
>> AAABlIAAFRMU1BBVUxJTkUuQ0FOVEFMT1VQUEMtQ0FOVEFMT1VQA/uQagaqmRXdJR+BBq
>> xQ4gMONR
>> a81Qhc[\r][\n]"
>> "Host: www.yahoo.fr[\r][\n]"
>> "Proxy-Connection: Keep-Alive[\r][\n]"
>> "[\r][\n]"

<< "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
<< "Server: squid/2.5.STABLE9[\r][\n]"
<< "Mime-Version: 1.0[\r][\n]"
<< "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "Content-Type: text/html[\r][\n]"
<< "Content-Length: 1462[\r][\n]"
<< "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
<< "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
<< "Proxy-Authenticate: NTLM[\r][\n]"
<< "Proxy-Authenticate: Basic realm="Squid proxy-caching web server"[\r][\n]"
<< "X-Cache: MISS from ProxyA[\r][\n]"
<< "Proxy-Connection: close[\r][\n]"




---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


D?charge / Disclaimer

Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration, 123Multim?dia et ses filiales d?clinent toute responsabilit? au titre de ce message s'il a ?t? alt?r?, d?form? ou falsifi?.

This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or falsified.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [HTTPClient] Problems to connect to a proxy

olegk
Pauline,

This should do the trick

HttpClient client = new HttpClient();
List authPrefs = new ArrayList(2);
authPrefs.add(AuthPolicy.DIGEST);
authPrefs.add(AuthPolicy.BASIC);
// This will exclude the NTLM authentication scheme
client.getParams().setParameter(AuthPolicy.AUTH_SCHEME_PRIORITY,
authPrefs);

For details see:

http://jakarta.apache.org/commons/httpclient/3.0/authentication.html#Alternate%20authentication

Oleg

On Mon, May 30, 2005 at 05:18:21PM +0200, Pauline CANTALOUP wrote:

> Thanks, but how can I force basic auth ?
>
> -----Message d'origine-----
> De : Oleg Kalnichevski [mailto:[hidden email]]
> Envoy? : lundi 30 mai 2005 15:26
> ? : Jakarta Commons Users List
> Objet : Re: [HTTPClient] Problems to connect to a proxy
>
> Pauline,
>
> As far as I can tell all the requests generated by HttpClient look perfectly
> sane. The server simply does not seem to like the credentials supplied by the
> client. Are you sure you are using the correct user name / password / domain
> / host params? Any of these four params being invalid will cause the NTLM
> scheme to fail.
>
> Actually this is the very time I see Squid proxy configured to use NTLM
> authentication. Frankly, I do not know if HttpClient is compatible with
> squid's implementation of NTLM auth. Consider using BASIC auth, at least
> initially, to test the credentials
>
> Oleg
>
> >> "GET http://www.yahoo.fr/ HTTP/1.1[\r][\n]"
> >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> >> "Host: www.yahoo.fr[\r][\n]"
> >> "Proxy-Connection: Keep-Alive[\r][\n]"
> >> "[\r][\n]"
>
> << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> << "Server: squid/2.5.STABLE9[\r][\n]"
> << "Mime-Version: 1.0[\r][\n]"
> << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "Content-Type: text/html[\r][\n]"
> << "Content-Length: 1462[\r][\n]"
> << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> << "Proxy-Authenticate: NTLM[\r][\n]"
> << "Proxy-Authenticate: Basic realm="Squid proxy-caching web server"[\r][\n]"
> << "X-Cache: MISS from ProxyA[\r][\n]"
> << "Proxy-Connection: close[\r][\n]"
>
> >> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
> >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> >> "Proxy-Authorization: NTLM
> >> TlRMTVNTUAABAAAABlIAAAMAAwAsAAAADAAMACAAAABQQy1DQU5UQUxPVVBUTFM=[\r][\n]"
> >> "Host: www.yahoo.fr[\r][\n]"
> >> "Proxy-Connection: Keep-Alive[\r][\n]"
> >> "[\r][\n]"
>
> << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> << "Server: squid/2.5.STABLE9[\r][\n]"
> << "Mime-Version: 1.0[\r][\n]"
> << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "Content-Type: text/html[\r][\n]"
> << "Content-Length: 1462[\r][\n]"
> << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> << "Proxy-Authenticate: NTLM
> TlRMTVNTUAACAAAAAAAAADAAAAASAgAAE+F7GZvD+bAAAAAAAAAAAAAAAAAwAAAA[\r][\n]"
> << "X-Cache: MISS from ProxyA[\r][\n]"
> << "Proxy-Connection: keep-alive[\r][\n]"
>
> >> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
> >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> >> "Proxy-Authorization: NTLM
> >> TlRMTVNTUAADAAAAGAAYAGAAAAAAAAAAeAAAAAMAAwBAAAAAEQARAEMAAAAMAAwAVAAAA
> >> AAAAAB4A
> >> AAABlIAAFRMU1BBVUxJTkUuQ0FOVEFMT1VQUEMtQ0FOVEFMT1VQA/uQagaqmRXdJR+BBq
> >> xQ4gMONR
> >> a81Qhc[\r][\n]"
> >> "Host: www.yahoo.fr[\r][\n]"
> >> "Proxy-Connection: Keep-Alive[\r][\n]"
> >> "[\r][\n]"
>
> << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> << "Server: squid/2.5.STABLE9[\r][\n]"
> << "Mime-Version: 1.0[\r][\n]"
> << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "Content-Type: text/html[\r][\n]"
> << "Content-Length: 1462[\r][\n]"
> << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> << "Proxy-Authenticate: NTLM[\r][\n]"
> << "Proxy-Authenticate: Basic realm="Squid proxy-caching web server"[\r][\n]"
> << "X-Cache: MISS from ProxyA[\r][\n]"
> << "Proxy-Connection: close[\r][\n]"
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
> D?charge / Disclaimer
>
> Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration,
>
> This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiari
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: [HTTPClient] Problems to connect to a proxy

Pauline CANTALOUP
In reply to this post by Pauline CANTALOUP

Unfortunately, it seems it doesn't work :(
Anyway, thanks a lot and sorry again !

-----Message d'origine-----
De : Oleg Kalnichevski [mailto:[hidden email]]
Envoyé : lundi 30 mai 2005 17:33
À : Jakarta Commons Users List
Objet : Re: [HTTPClient] Problems to connect to a proxy

Pauline,

This should do the trick

HttpClient client = new HttpClient();
List authPrefs = new ArrayList(2);
authPrefs.add(AuthPolicy.DIGEST);
authPrefs.add(AuthPolicy.BASIC);
// This will exclude the NTLM authentication scheme
client.getParams().setParameter(AuthPolicy.AUTH_SCHEME_PRIORITY,
authPrefs);

For details see:

http://jakarta.apache.org/commons/httpclient/3.0/authentication.html#Alternat
e%20authentication

Oleg

On Mon, May 30, 2005 at 05:18:21PM +0200, Pauline CANTALOUP wrote:

> Thanks, but how can I force basic auth ?
>
> -----Message d'origine-----
> De : Oleg Kalnichevski [mailto:[hidden email]] Envoy? : lundi 30 mai
> 2005 15:26 ? : Jakarta Commons Users List Objet : Re: [HTTPClient]
> Problems to connect to a proxy
>
> Pauline,
>
> As far as I can tell all the requests generated by HttpClient look
> perfectly sane. The server simply does not seem to like the
> credentials supplied by the client. Are you sure you are using the
> correct user name / password / domain / host params? Any of these four
> params being invalid will cause the NTLM scheme to fail.
>
> Actually this is the very time I see Squid proxy configured to use
> NTLM authentication. Frankly, I do not know if HttpClient is
> compatible with squid's implementation of NTLM auth. Consider using
> BASIC auth, at least initially, to test the credentials
>
> Oleg
>
> >> "GET http://www.yahoo.fr/ HTTP/1.1[\r][\n]"
> >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> >> "Host: www.yahoo.fr[\r][\n]"
> >> "Proxy-Connection: Keep-Alive[\r][\n]"
> >> "[\r][\n]"
>
> << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> << "Server: squid/2.5.STABLE9[\r][\n]"
> << "Mime-Version: 1.0[\r][\n]"
> << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "Content-Type: text/html[\r][\n]"
> << "Content-Length: 1462[\r][\n]"
> << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> << "Proxy-Authenticate: NTLM[\r][\n]"
> << "Proxy-Authenticate: Basic realm="Squid proxy-caching web
server"[\r][\n]"
> << "X-Cache: MISS from ProxyA[\r][\n]"
> << "Proxy-Connection: close[\r][\n]"
>
> >> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
> >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> >> "Proxy-Authorization: NTLM
> >>
TlRMTVNTUAABAAAABlIAAAMAAwAsAAAADAAMACAAAABQQy1DQU5UQUxPVVBUTFM=[\r][\n]"

> >> "Host: www.yahoo.fr[\r][\n]"
> >> "Proxy-Connection: Keep-Alive[\r][\n]"
> >> "[\r][\n]"
>
> << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> << "Server: squid/2.5.STABLE9[\r][\n]"
> << "Mime-Version: 1.0[\r][\n]"
> << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "Content-Type: text/html[\r][\n]"
> << "Content-Length: 1462[\r][\n]"
> << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> << "Proxy-Authenticate: NTLM
> TlRMTVNTUAACAAAAAAAAADAAAAASAgAAE+F7GZvD+bAAAAAAAAAAAAAAAAAwAAAA[\r][\n]"
> << "X-Cache: MISS from ProxyA[\r][\n]"
> << "Proxy-Connection: keep-alive[\r][\n]"
>
> >> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
> >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> >> "Proxy-Authorization: NTLM
> >> TlRMTVNTUAADAAAAGAAYAGAAAAAAAAAAeAAAAAMAAwBAAAAAEQARAEMAAAAMAAwAVAA
> >> AA
> >> AAAAAB4A
> >> AAABlIAAFRMU1BBVUxJTkUuQ0FOVEFMT1VQUEMtQ0FOVEFMT1VQA/uQagaqmRXdJR+B
> >> Bq
> >> xQ4gMONR
> >> a81Qhc[\r][\n]"
> >> "Host: www.yahoo.fr[\r][\n]"
> >> "Proxy-Connection: Keep-Alive[\r][\n]"
> >> "[\r][\n]"
>
> << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> << "Server: squid/2.5.STABLE9[\r][\n]"
> << "Mime-Version: 1.0[\r][\n]"
> << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "Content-Type: text/html[\r][\n]"
> << "Content-Length: 1462[\r][\n]"
> << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> << "Proxy-Authenticate: NTLM[\r][\n]"
> << "Proxy-Authenticate: Basic realm="Squid proxy-caching web
server"[\r][\n]"

> << "X-Cache: MISS from ProxyA[\r][\n]"
> << "Proxy-Connection: close[\r][\n]"
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
> D?charge / Disclaimer
>
> Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont
> confidentiels et ?tablis ? l'intention exclusive des destinataires.
> Toute utilisation ou diffusion non autoris?e est interdite. Tout
> message ?lectronique ?tant susceptible d'alt?ration,
>
> This message and any attachments (the "message") are confidential and
> intended solely for the addressees. Any unauthorised use or
> dissemination is prohibited. E-mails are susceptible to alteration.
> Therefore neither 123Multim?dia nor any of its subsidiari
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]


D?charge / Disclaimer

Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration, 123Multim?dia et ses filiales d?clinent toute responsabilit? au titre de ce message s'il a ?t? alt?r?, d?form? ou falsifi?.

This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or falsified.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [HTTPClient] Problems to connect to a proxy

olegk
Pauline,

Exactly what does not work? I know for a fact that Squid BASIC
authentication works, because I regularly test HttpClient against Squid.
I am also pretty sure that the code snippet I posted below should work

Oleg


On Mon, May 30, 2005 at 06:54:47PM +0200, Pauline CANTALOUP wrote:

>
> Unfortunately, it seems it doesn't work :(
> Anyway, thanks a lot and sorry again !
>
> -----Message d'origine-----
> De : Oleg Kalnichevski [mailto:[hidden email]]
> Envoy? : lundi 30 mai 2005 17:33
> ? : Jakarta Commons Users List
> Objet : Re: [HTTPClient] Problems to connect to a proxy
>
> Pauline,
>
> This should do the trick
>
> HttpClient client = new HttpClient();
> List authPrefs = new ArrayList(2);
> authPrefs.add(AuthPolicy.DIGEST);
> authPrefs.add(AuthPolicy.BASIC);
> // This will exclude the NTLM authentication scheme
> client.getParams().setParameter(AuthPolicy.AUTH_SCHEME_PRIORITY,
> authPrefs);
>
> For details see:
>
> http://jakarta.apache.org/commons/httpclient/3.0/authentication.html#Alternat
> e%20authentication
>
> Oleg
>
> On Mon, May 30, 2005 at 05:18:21PM +0200, Pauline CANTALOUP wrote:
> > Thanks, but how can I force basic auth ?
> >
> > -----Message d'origine-----
> > De : Oleg Kalnichevski [mailto:[hidden email]] Envoy? : lundi 30 mai
> > 2005 15:26 ? : Jakarta Commons Users List Objet : Re: [HTTPClient]
> > Problems to connect to a proxy
> >
> > Pauline,
> >
> > As far as I can tell all the requests generated by HttpClient look
> > perfectly sane. The server simply does not seem to like the
> > credentials supplied by the client. Are you sure you are using the
> > correct user name / password / domain / host params? Any of these four
> > params being invalid will cause the NTLM scheme to fail.
> >
> > Actually this is the very time I see Squid proxy configured to use
> > NTLM authentication. Frankly, I do not know if HttpClient is
> > compatible with squid's implementation of NTLM auth. Consider using
> > BASIC auth, at least initially, to test the credentials
> >
> > Oleg
> >
> > >> "GET http://www.yahoo.fr/ HTTP/1.1[\r][\n]"
> > >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> > >> "Host: www.yahoo.fr[\r][\n]"
> > >> "Proxy-Connection: Keep-Alive[\r][\n]"
> > >> "[\r][\n]"
> >
> > << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> > << "Server: squid/2.5.STABLE9[\r][\n]"
> > << "Mime-Version: 1.0[\r][\n]"
> > << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> > << "Content-Type: text/html[\r][\n]"
> > << "Content-Length: 1462[\r][\n]"
> > << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> > << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> > << "Proxy-Authenticate: NTLM[\r][\n]"
> > << "Proxy-Authenticate: Basic realm="Squid proxy-caching web
> server"[\r][\n]"
> > << "X-Cache: MISS from ProxyA[\r][\n]"
> > << "Proxy-Connection: close[\r][\n]"
> >
> > >> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
> > >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> > >> "Proxy-Authorization: NTLM
> > >>
> TlRMTVNTUAABAAAABlIAAAMAAwAsAAAADAAMACAAAABQQy1DQU5UQUxPVVBUTFM=[\r][\n]"
> > >> "Host: www.yahoo.fr[\r][\n]"
> > >> "Proxy-Connection: Keep-Alive[\r][\n]"
> > >> "[\r][\n]"
> >
> > << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> > << "Server: squid/2.5.STABLE9[\r][\n]"
> > << "Mime-Version: 1.0[\r][\n]"
> > << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> > << "Content-Type: text/html[\r][\n]"
> > << "Content-Length: 1462[\r][\n]"
> > << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> > << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> > << "Proxy-Authenticate: NTLM
> > TlRMTVNTUAACAAAAAAAAADAAAAASAgAAE+F7GZvD+bAAAAAAAAAAAAAAAAAwAAAA[\r][\n]"
> > << "X-Cache: MISS from ProxyA[\r][\n]"
> > << "Proxy-Connection: keep-alive[\r][\n]"
> >
> > >> "GET http://www.yahoo.fr/ HTTP/1.0[\r][\n]"
> > >> "User-Agent: Jakarta Commons-HttpClient/3.0-rc2[\r][\n]"
> > >> "Proxy-Authorization: NTLM
> > >> TlRMTVNTUAADAAAAGAAYAGAAAAAAAAAAeAAAAAMAAwBAAAAAEQARAEMAAAAMAAwAVAA
> > >> AA
> > >> AAAAAB4A
> > >> AAABlIAAFRMU1BBVUxJTkUuQ0FOVEFMT1VQUEMtQ0FOVEFMT1VQA/uQagaqmRXdJR+B
> > >> Bq
> > >> xQ4gMONR
> > >> a81Qhc[\r][\n]"
> > >> "Host: www.yahoo.fr[\r][\n]"
> > >> "Proxy-Connection: Keep-Alive[\r][\n]"
> > >> "[\r][\n]"
> >
> > << "HTTP/1.0 407 Proxy Authentication Required[\r][\n]"
> > << "Server: squid/2.5.STABLE9[\r][\n]"
> > << "Mime-Version: 1.0[\r][\n]"
> > << "Date: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> > << "Content-Type: text/html[\r][\n]"
> > << "Content-Length: 1462[\r][\n]"
> > << "Expires: Mon, 30 May 2005 12:40:47 GMT[\r][\n]"
> > << "X-Squid-Error: ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> > << "Proxy-Authenticate: NTLM[\r][\n]"
> > << "Proxy-Authenticate: Basic realm="Squid proxy-caching web
> server"[\r][\n]"
> > << "X-Cache: MISS from ProxyA[\r][\n]"
> > << "Proxy-Connection: close[\r][\n]"
> >
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
> >
> > D?charge / Disclaimer
> >
> > Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont
> > confidentiels et ?tablis ? l'intention exclusive des destinataires.
> > Toute utilisation ou diffusion non autoris?e est interdite. Tout
> > message ?lectronique ?tant susceptible d'alt?ration,
> >
> > This message and any attachments (the "message") are confidential and
> > intended solely for the addressees. Any unauthorised use or
> > dissemination is prohibited. E-mails are susceptible to alteration.
> > Therefore neither 123Multim?dia nor any of its subsidiari
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
> D?charge / Disclaimer
>
> Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration,
>
> This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiari
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: [HTTPClient] Problems to connect to a proxy

Pauline CANTALOUP
In reply to this post by Pauline CANTALOUP
>Exactly what does not work? I know for a fact that Squid BASIC
authentication >works, because I regularly test HttpClient against Squid.
>I am also pretty sure that the code snippet I posted below should work

Sorry if I wasn't clear, your code works, but authentication doesn't, even
basic one - but I'm sure of login/password since I use them everyday to log
on my workstation ; moreover, when I set proxy in System properties and try a
simple URL.openStream, it works.

2005/05/31 09:17:19:974 CEST [DEBUG] HttpClient - Java version: 1.5.0_01
2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Java vendor: Sun
Microsystems Inc.
2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Java class path:
C:\eclipse\workspace\CheckHeaders\webapp\WEB-INF\classes;C:\eclipse\workspace
\CheckHeaders\webapp\WEB-INF\lib\commons-logging.jar;C:\eclipse\workspace\Che
ckHeaders\webapp\WEB-INF\lib\commons-httpclient-3.0-rc2.jar;C:\eclipse\worksp
ace\CheckHeaders\webapp\WEB-INF\lib\commons-codec-1.3.jar
2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Operating system name:
Windows XP
2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Operating system
architecture: x86
2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Operating system version:
5.1
2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SUN 1.5: SUN (DSA
key/parameter generation; DSA signing; SHA-1, MD5 digests; SecureRandom;
X.509 certificates; JKS keystore; PKIX CertPathValidator; PKIX
CertPathBuilder; LDAP, Collection CertStores)
2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunRsaSign 1.5: Sun RSA
signature provider
2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunJSSE 1.5: Sun JSSE
provider(PKCS12, SunX509 key/trust factories, SSLv3, TLSv1)
2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunJCE 1.5: SunJCE Provider
(implements RSA, DES, Triple DES, AES, Blowfish, ARCFOUR, RC2, PBE,
Diffie-Hellman, HMAC)
2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunJGSS 1.0: Sun (Kerberos
v5)
2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunSASL 1.5: Sun SASL
provider(implements client mechanisms for: DIGEST-MD5, GSSAPI, EXTERNAL,
PLAIN, CRAM-MD5; server mechanisms for: DIGEST-MD5, GSSAPI, CRAM-MD5)
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.useragent = Jakarta Commons-HttpClient/3.0-rc2
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.version = HTTP/1.1
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.connection-manager.class = class
org.apache.commons.httpclient.SimpleHttpConnectionManager
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.cookie-policy = rfc2109
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.element-charset = US-ASCII
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.protocol.content-charset = ISO-8859-1
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.method.retry-handler =
org.apache.commons.httpclient.DefaultHttpMethodRetryHandler@d251a3
2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
http.dateparser.patterns = [EEE, dd MMM yyyy HH:mm:ss zzz, EEEE, dd-MMM-yy
HH:mm:ss zzz, EEE MMM d HH:mm:ss yyyy, EEE, dd-MMM-yyyy HH:mm:ss z, EEE,
dd-MMM-yyyy HH-mm-ss z, EEE, dd MMM yy HH:mm:ss z, EEE dd-MMM-yyyy HH:mm:ss
z, EEE dd MMM yyyy HH:mm:ss z, EEE dd-MMM-yyyy HH-mm-ss z, EEE dd-MMM-yy
HH:mm:ss z, EEE dd MMM yy HH:mm:ss z, EEE,dd-MMM-yy HH:mm:ss z,
EEE,dd-MMM-yyyy HH:mm:ss z, EEE, dd-MM-yyyy HH:mm:ss z]
2005/05/31 09:17:20:396 CEST [DEBUG] DefaultHttpParams - Set parameter
http.auth.scheme-priority = [Digest, Basic]
2005/05/31 09:17:20:505 CEST [DEBUG] HttpConnection - Open connection to
192.168.10.225:8888
2005/05/31 09:17:21:162 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
HTTP/1.1[\r][\n]"
2005/05/31 09:17:21:162 CEST [DEBUG] HttpMethodBase - Adding Host request
header
2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.0-rc2[\r][\n]"
2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "Proxy-Connection:
Keep-Alive[\r][\n]"
2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "[\r][\n]"
2005/05/31 09:17:21:177 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
Authentication Required[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Server:
squid/2.5.STABLE9[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Date: Tue, 31 May 2005
07:17:21 GMT[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Content-Type:
text/html[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Content-Length:
1462[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Expires: Tue, 31 May 2005
07:17:21 GMT[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "X-Squid-Error:
ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Proxy-Authenticate:
NTLM[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Proxy-Authenticate: Basic
realm="Squid proxy-caching web server"[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "X-Cache: MISS from
ProxyA[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Proxy-Connection:
close[\r][\n]"
2005/05/31 09:17:21:193 CEST [DEBUG] HttpMethodDirector - Authorization
required
2005/05/31 09:17:21:193 CEST [DEBUG] AuthChallengeProcessor - Supported
authentication schemes in the order of preference: [Digest, Basic]
2005/05/31 09:17:21:193 CEST [DEBUG] AuthChallengeProcessor - Challenge for
Digest authentication scheme not available
2005/05/31 09:17:21:193 CEST [INFO] AuthChallengeProcessor - Basic
authentication scheme selected
2005/05/31 09:17:21:208 CEST [DEBUG] AuthChallengeProcessor - Using
authentication scheme: basic
2005/05/31 09:17:21:208 CEST [DEBUG] AuthChallengeProcessor - Authorization
challenge processed
2005/05/31 09:17:21:208 CEST [DEBUG] HttpMethodDirector - Proxy
authentication scope: BASIC 'Squid proxy-caching web
server'@192.168.10.225:8888
2005/05/31 09:17:21:208 CEST [DEBUG] HttpMethodDirector - Retry
authentication
2005/05/31 09:17:21:208 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<HTML><HEAD><META
HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
Acc&egrave;s au cache interdit</TITLE>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<STYLE
type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</HEAD>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<BODY>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
interdit</H2>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "En essayant de charger
l'URL&nbsp;:[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<A
HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "L'erreur suivante a
&eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<UL>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<LI>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<STRONG>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Acc&egrave;s au cache
interdit.[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</STRONG>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</UL>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</P>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "&agrave; demander[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<PRE>
http://www.yahoo.fr/</PRE>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "&agrave; ce cache tant que
vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</P>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Vous avez besoin de
Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
un "
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "navigateur conforme
&agrave; HTTP/1.1 pour que[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "si vous avez des
difficult&eacute;s &agrave; vous authentifier, ou[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<A
HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
passe.[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</P>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<BR clear="all">[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<ADDRESS>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Generated Tue, 31 May 2005
07:17:21 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</ADDRESS>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
2005/05/31 09:17:21:224 CEST [DEBUG] HttpMethodBase - Should close connection
in response to directive: close
2005/05/31 09:17:21:240 CEST [DEBUG] HttpConnection - Connection is locked.
Call to releaseConnection() ignored.
2005/05/31 09:17:21:240 CEST [DEBUG] HttpMethodDirector - Authenticating with
BASIC 'Squid proxy-caching web server'@192.168.10.225:8888
2005/05/31 09:17:21:240 CEST [DEBUG] HttpMethodParams - Credential charset
not configured, using HTTP element charset
2005/05/31 09:17:21:240 CEST [DEBUG] HttpConnection - Open connection to
192.168.10.225:8888
2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
HTTP/1.0[\r][\n]"
2005/05/31 09:17:21:240 CEST [DEBUG] HttpMethodBase - Adding Host request
header
2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "User-Agent: Jakarta
Commons-HttpClient/3.0-rc2[\r][\n]"
2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "Proxy-Authorization: Basic
ZnJhbmNvaXMubWV0ZW5pZXI6YmUyMDAz[\r][\n]"
2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "Proxy-Connection:
Keep-Alive[\r][\n]"
2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
Authentication Required[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Server:
squid/2.5.STABLE9[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Date: Tue, 31 May 2005
07:17:21 GMT[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Content-Type:
text/html[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Content-Length:
1462[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Expires: Tue, 31 May 2005
07:17:21 GMT[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "X-Squid-Error:
ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Proxy-Authenticate:
NTLM[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Proxy-Authenticate: Basic
realm="Squid proxy-caching web server"[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "X-Cache: MISS from
ProxyA[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Proxy-Connection:
close[\r][\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Authorization
required
2005/05/31 09:17:21:255 CEST [DEBUG] AuthChallengeProcessor - Using
authentication scheme: basic
2005/05/31 09:17:21:255 CEST [DEBUG] AuthChallengeProcessor - Authorization
challenge processed
2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Proxy
authentication scope: BASIC 'Squid proxy-caching web
server'@192.168.10.225:8888
2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Proxy credentials
required
2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Proxy credentials
provider not available
2005/05/31 09:17:21:255 CEST [INFO] HttpMethodDirector - Failure
authenticating with BASIC 'Squid proxy-caching web
server'@192.168.10.225:8888
2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodBase - Buffering response body
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
"-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<HTML><HEAD><META
HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
Acc&egrave;s au cache interdit</TITLE>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<STYLE
type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</HEAD>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<BODY>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
interdit</H2>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "En essayant de charger
l'URL&nbsp;:[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<A
HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "L'erreur suivante a
&eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<UL>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<LI>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<STRONG>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Acc&egrave;s au cache
interdit.[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</STRONG>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</UL>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</P>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "&agrave; demander[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<PRE>
http://www.yahoo.fr/</PRE>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "&agrave; ce cache tant que
vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</P>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Vous avez besoin de
Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
un navigateur conforme &agrave; HTTP/1.1 pour que[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "si vous avez des
difficult&eacute;s &agrave; vous authentifier, ou[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<A
HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
passe.[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</P>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<BR clear="all">[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<HR noshade
size="1px">[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<ADDRESS>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Generated Tue, 31 May 2005
07:17:21 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</ADDRESS>[\n]"
2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
2005/05/31 09:17:21:271 CEST [DEBUG] HttpMethodBase - Should close connection
in response to directive: close
2005/05/31 09:17:21:271 CEST [DEBUG] HttpConnection - Releasing connection
back to connection manager.
2005/05/31 09:17:21:287 CEST [DEBUG] HttpMethodBase - Default charset used:
ISO-8859-1

D?charge / Disclaimer

Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration, 123Multim?dia et ses filiales d?clinent toute responsabilit? au titre de ce message s'il a ?t? alt?r?, d?form? ou falsifi?.

This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiaries or affiliates shall be liable for the message if altered, changed or falsified.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: [HTTPClient] Problems to connect to a proxy

olegk
Pauline,

Same story as with the NTLM authentication. Everything looks absolutely
fine, except that the proxy just refuses to accept the credentials.

Do you by any chance have non-ASCII characters such as French accents
either in your user name or password. If this is the case you have to
configure HttpClient to use ISO-8859-1 charset instead of US-ASCII used
per default

http://jakarta.apache.org/commons/httpclient/3.0/apidocs/org/apache/commons/httpclient/params/HttpMethodParams.html#setCredentialCharset(java.lang.String)

Oleg


On Tue, May 31, 2005 at 09:30:53AM +0200, Pauline CANTALOUP wrote:

> >Exactly what does not work? I know for a fact that Squid BASIC
> authentication >works, because I regularly test HttpClient against Squid.
> >I am also pretty sure that the code snippet I posted below should work
>
> Sorry if I wasn't clear, your code works, but authentication doesn't, even
> basic one - but I'm sure of login/password since I use them everyday to log
> on my workstation ; moreover, when I set proxy in System properties and try a
> simple URL.openStream, it works.
>
> 2005/05/31 09:17:19:974 CEST [DEBUG] HttpClient - Java version: 1.5.0_01
> 2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Java vendor: Sun
> Microsystems Inc.
> 2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Java class path:
> C:\eclipse\workspace\CheckHeaders\webapp\WEB-INF\classes;C:\eclipse\workspace
> \CheckHeaders\webapp\WEB-INF\lib\commons-logging.jar;C:\eclipse\workspace\Che
> ckHeaders\webapp\WEB-INF\lib\commons-httpclient-3.0-rc2.jar;C:\eclipse\worksp
> ace\CheckHeaders\webapp\WEB-INF\lib\commons-codec-1.3.jar
> 2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Operating system name:
> Windows XP
> 2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Operating system
> architecture: x86
> 2005/05/31 09:17:19:990 CEST [DEBUG] HttpClient - Operating system version:
> 5.1
> 2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SUN 1.5: SUN (DSA
> key/parameter generation; DSA signing; SHA-1, MD5 digests; SecureRandom;
> X.509 certificates; JKS keystore; PKIX CertPathValidator; PKIX
> CertPathBuilder; LDAP, Collection CertStores)
> 2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunRsaSign 1.5: Sun RSA
> signature provider
> 2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunJSSE 1.5: Sun JSSE
> provider(PKCS12, SunX509 key/trust factories, SSLv3, TLSv1)
> 2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunJCE 1.5: SunJCE Provider
> (implements RSA, DES, Triple DES, AES, Blowfish, ARCFOUR, RC2, PBE,
> Diffie-Hellman, HMAC)
> 2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunJGSS 1.0: Sun (Kerberos
> v5)
> 2005/05/31 09:17:20:365 CEST [DEBUG] HttpClient - SunSASL 1.5: Sun SASL
> provider(implements client mechanisms for: DIGEST-MD5, GSSAPI, EXTERNAL,
> PLAIN, CRAM-MD5; server mechanisms for: DIGEST-MD5, GSSAPI, CRAM-MD5)
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.useragent = Jakarta Commons-HttpClient/3.0-rc2
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.protocol.version = HTTP/1.1
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.connection-manager.class = class
> org.apache.commons.httpclient.SimpleHttpConnectionManager
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.protocol.cookie-policy = rfc2109
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.protocol.element-charset = US-ASCII
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.protocol.content-charset = ISO-8859-1
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.method.retry-handler =
> org.apache.commons.httpclient.DefaultHttpMethodRetryHandler@d251a3
> 2005/05/31 09:17:20:380 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.dateparser.patterns = [EEE, dd MMM yyyy HH:mm:ss zzz, EEEE, dd-MMM-yy
> HH:mm:ss zzz, EEE MMM d HH:mm:ss yyyy, EEE, dd-MMM-yyyy HH:mm:ss z, EEE,
> dd-MMM-yyyy HH-mm-ss z, EEE, dd MMM yy HH:mm:ss z, EEE dd-MMM-yyyy HH:mm:ss
> z, EEE dd MMM yyyy HH:mm:ss z, EEE dd-MMM-yyyy HH-mm-ss z, EEE dd-MMM-yy
> HH:mm:ss z, EEE dd MMM yy HH:mm:ss z, EEE,dd-MMM-yy HH:mm:ss z,
> EEE,dd-MMM-yyyy HH:mm:ss z, EEE, dd-MM-yyyy HH:mm:ss z]
> 2005/05/31 09:17:20:396 CEST [DEBUG] DefaultHttpParams - Set parameter
> http.auth.scheme-priority = [Digest, Basic]
> 2005/05/31 09:17:20:505 CEST [DEBUG] HttpConnection - Open connection to
> 192.168.10.225:8888
> 2005/05/31 09:17:21:162 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
> HTTP/1.1[\r][\n]"
> 2005/05/31 09:17:21:162 CEST [DEBUG] HttpMethodBase - Adding Host request
> header
> 2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "User-Agent: Jakarta
> Commons-HttpClient/3.0-rc2[\r][\n]"
> 2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
> 2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "Proxy-Connection:
> Keep-Alive[\r][\n]"
> 2005/05/31 09:17:21:177 CEST [DEBUG] header - >> "[\r][\n]"
> 2005/05/31 09:17:21:177 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
> Authentication Required[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Server:
> squid/2.5.STABLE9[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Date: Tue, 31 May 2005
> 07:17:21 GMT[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Content-Type:
> text/html[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Content-Length:
> 1462[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Expires: Tue, 31 May 2005
> 07:17:21 GMT[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "X-Squid-Error:
> ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Proxy-Authenticate:
> NTLM[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Proxy-Authenticate: Basic
> realm="Squid proxy-caching web server"[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "X-Cache: MISS from
> ProxyA[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] header - << "Proxy-Connection:
> close[\r][\n]"
> 2005/05/31 09:17:21:193 CEST [DEBUG] HttpMethodDirector - Authorization
> required
> 2005/05/31 09:17:21:193 CEST [DEBUG] AuthChallengeProcessor - Supported
> authentication schemes in the order of preference: [Digest, Basic]
> 2005/05/31 09:17:21:193 CEST [DEBUG] AuthChallengeProcessor - Challenge for
> Digest authentication scheme not available
> 2005/05/31 09:17:21:193 CEST [INFO] AuthChallengeProcessor - Basic
> authentication scheme selected
> 2005/05/31 09:17:21:208 CEST [DEBUG] AuthChallengeProcessor - Using
> authentication scheme: basic
> 2005/05/31 09:17:21:208 CEST [DEBUG] AuthChallengeProcessor - Authorization
> challenge processed
> 2005/05/31 09:17:21:208 CEST [DEBUG] HttpMethodDirector - Proxy
> authentication scope: BASIC 'Squid proxy-caching web
> server'@192.168.10.225:8888
> 2005/05/31 09:17:21:208 CEST [DEBUG] HttpMethodDirector - Retry
> authentication
> 2005/05/31 09:17:21:208 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
> "-//W3C//DTD HTML 4.01 Transitional//EN"
> "http://www.w3.org/TR/html4/loose.dtd">[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<HTML><HEAD><META
> HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
> Acc&egrave;s au cache interdit</TITLE>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<STYLE
> type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
> rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</HEAD>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<BODY>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
> interdit</H2>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<HR noshade
> size="1px">[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "En essayant de charger
> l'URL&nbsp;:[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<A
> HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "L'erreur suivante a
> &eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<UL>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<LI>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<STRONG>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Acc&egrave;s au cache
> interdit.[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</STRONG>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</UL>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</P>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
> vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "&agrave; demander[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<PRE>
> http://www.yahoo.fr/</PRE>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "&agrave; ce cache tant que
> vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</P>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<P>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Vous avez besoin de
> Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
> un "
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "navigateur conforme
> &agrave; HTTP/1.1 pour que[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
> contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "si vous avez des
> difficult&eacute;s &agrave; vous authentifier, ou[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<A
> HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
> passe.[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</P>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<BR clear="all">[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<HR noshade
> size="1px">[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "<ADDRESS>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "Generated Tue, 31 May 2005
> 07:17:21 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</ADDRESS>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
> 2005/05/31 09:17:21:224 CEST [DEBUG] HttpMethodBase - Should close connection
> in response to directive: close
> 2005/05/31 09:17:21:240 CEST [DEBUG] HttpConnection - Connection is locked.
> Call to releaseConnection() ignored.
> 2005/05/31 09:17:21:240 CEST [DEBUG] HttpMethodDirector - Authenticating with
> BASIC 'Squid proxy-caching web server'@192.168.10.225:8888
> 2005/05/31 09:17:21:240 CEST [DEBUG] HttpMethodParams - Credential charset
> not configured, using HTTP element charset
> 2005/05/31 09:17:21:240 CEST [DEBUG] HttpConnection - Open connection to
> 192.168.10.225:8888
> 2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "GET http://www.yahoo.fr/
> HTTP/1.0[\r][\n]"
> 2005/05/31 09:17:21:240 CEST [DEBUG] HttpMethodBase - Adding Host request
> header
> 2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "User-Agent: Jakarta
> Commons-HttpClient/3.0-rc2[\r][\n]"
> 2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "Proxy-Authorization: Basic
> ZnJhbmNvaXMubWV0ZW5pZXI6YmUyMDAz[\r][\n]"
> 2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "Host: www.yahoo.fr[\r][\n]"
> 2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "Proxy-Connection:
> Keep-Alive[\r][\n]"
> 2005/05/31 09:17:21:240 CEST [DEBUG] header - >> "[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "HTTP/1.0 407 Proxy
> Authentication Required[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Server:
> squid/2.5.STABLE9[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Mime-Version: 1.0[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Date: Tue, 31 May 2005
> 07:17:21 GMT[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Content-Type:
> text/html[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Content-Length:
> 1462[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Expires: Tue, 31 May 2005
> 07:17:21 GMT[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "X-Squid-Error:
> ERR_CACHE_ACCESS_DENIED 0[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Proxy-Authenticate:
> NTLM[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Proxy-Authenticate: Basic
> realm="Squid proxy-caching web server"[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "X-Cache: MISS from
> ProxyA[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] header - << "Proxy-Connection:
> close[\r][\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Authorization
> required
> 2005/05/31 09:17:21:255 CEST [DEBUG] AuthChallengeProcessor - Using
> authentication scheme: basic
> 2005/05/31 09:17:21:255 CEST [DEBUG] AuthChallengeProcessor - Authorization
> challenge processed
> 2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Proxy
> authentication scope: BASIC 'Squid proxy-caching web
> server'@192.168.10.225:8888
> 2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Proxy credentials
> required
> 2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodDirector - Proxy credentials
> provider not available
> 2005/05/31 09:17:21:255 CEST [INFO] HttpMethodDirector - Failure
> authenticating with BASIC 'Squid proxy-caching web
> server'@192.168.10.225:8888
> 2005/05/31 09:17:21:255 CEST [DEBUG] HttpMethodBase - Buffering response body
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<!DOCTYPE HTML PUBLIC
> "-//W3C//DTD HTML 4.01 Transitional//EN"
> "http://www.w3.org/TR/html4/loose.dtd">[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<HTML><HEAD><META
> HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<TITLE>ERREUR&nbsp;:
> Acc&egrave;s au cache interdit</TITLE>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<STYLE
> type="text/css"><!--BODY{background-color:#ffffff;font-family:verdana,sans-se
> rif}PRE{font-family:sans-serif}--></STYLE>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</HEAD>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<BODY>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<H1>ERREUR</H1>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<H2>Acc&egrave;s au cache
> interdit</H2>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<HR noshade
> size="1px">[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "En essayant de charger
> l'URL&nbsp;:[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<A
> HREF="http://www.yahoo.fr/">http://www.yahoo.fr/</A>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "L'erreur suivante a
> &eacute;t&eacute; rencontr&eacute;e&nbsp;:[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<UL>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<LI>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<STRONG>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Acc&egrave;s au cache
> interdit.[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</STRONG>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</UL>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</P>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>D&eacute;sol&eacute;,
> vous n'&ecirc;tes actuellement pas autoris&eacute;[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "&agrave; demander[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<PRE>
> http://www.yahoo.fr/</PRE>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "&agrave; ce cache tant que
> vous ne vous &ecirc;tes pas identifi&eacute;.[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</P>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<P>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Vous avez besoin de
> Netscape version 2.0 ou sup&eacute;rieure, ou Microsoft[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Internet Explorer 3.0, ou
> un navigateur conforme &agrave; HTTP/1.1 pour que[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "ceci fonctionne.  Veuillez
> contacter l'<A HREF="mailto:webmaster">administrateur du cache</a>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "si vous avez des
> difficult&eacute;s &agrave; vous authentifier, ou[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<A
> HREF="http://ProxyA/cgi-bin/chpasswd.cgi">changez</a> votre mot de
> passe.[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</P>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<BR clear="all">[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<HR noshade
> size="1px">[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "<ADDRESS>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "Generated Tue, 31 May 2005
> 07:17:21 GMT by ProxyA (squid/2.5.STABLE9)[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</ADDRESS>[\n]"
> 2005/05/31 09:17:21:255 CEST [DEBUG] content - << "</BODY></HTML>[\n]"
> 2005/05/31 09:17:21:271 CEST [DEBUG] HttpMethodBase - Should close connection
> in response to directive: close
> 2005/05/31 09:17:21:271 CEST [DEBUG] HttpConnection - Releasing connection
> back to connection manager.
> 2005/05/31 09:17:21:287 CEST [DEBUG] HttpMethodBase - Default charset used:
> ISO-8859-1
>
> D?charge / Disclaimer
>
> Ce message et toutes les pi?ces jointes (ci-apr?s le "message") sont confidentiels et ?tablis ? l'intention exclusive des destinataires. Toute utilisation ou diffusion non autoris?e est interdite. Tout message ?lectronique ?tant susceptible d'alt?ration,
>
> This message and any attachments (the "message") are confidential and intended solely for the addressees. Any unauthorised use or dissemination is prohibited. E-mails are susceptible to alteration. Therefore neither 123Multim?dia nor any of its subsidiari
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]