views:

1195

answers:

3

Hi, i am using the apache commons httpclient in a lotus notes java agent and it works fine. BUT when establishing a proxy connection the log will be spamed with the following line :

[INFO] AuthChallengeProcessor - basic authentication scheme selected

Do you know how to disable the integrated loging or how to set a lower debug level ? Its a "feature" from the httpclient itself, so code from my side is not needed :-)

Thanks.

A: 

you should be able to set the logging level to something less spammy. there are a few default logging options, so it depends on the logging method you chose.

it sounds like your logging level is set to "debug" or "info" and should be set at "notice" or above (to avoid info and below level warnings)

Owen
A: 

i have had a look into a authentification rfc and read that this is a warning not to use basic authentification. so i think i need to change the authentification to not submit the login information in readable text.

JimmyTudeski
A: 

It is possible to set a AuthPolicy Priority :

... snipp....

client.getState().setProxyCredentials(
                      new AuthScope(conParm.getProxyServer(), conParm.getProxyPort()),
                      new UsernamePasswordCredentials(conParm.getProxyUser(), conParm.getProxyPw()));

    **ArrayList authPrefs = new ArrayList(2);
    authPrefs.add(AuthPolicy.DIGEST);
    authPrefs.add(AuthPolicy.BASIC);

         client.getParams().setParameter(AuthPolicy.AUTH_SCHEME_PRIORITY, authPrefs);
         client.getParams().setParameter("http.protocol.expect-continue", new Boolean(true));**

..snapp....

JimmyTudeski