DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=29439>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=29439

Credentials ignored if realm specified in preemptive authentication





------- Additional Comments From [EMAIL PROTECTED]  2004-06-12 18:22 -------
Hi Oleg,

I like it.  It definitely cleans things up.  There are only two problems that I see:

 - The various static variables in AuthScope should be final I think
 - HttpState.matchCredentials() doesn't handle all combinations of AuthScopes.  This 
is not a new 
problem I think.  For example the following assertion fails:

        AuthScope scope = new AuthScope("host", 80, "Realm", "Scheme");
        Credentials creds = new UsernamePasswordCredentials("name", "password");       
 
        HttpState state = new HttpState();
        state.setCredentials(new AuthScope("host", 80, AuthScope.ANY_REALM, "Scheme"), 
creds);        
        assertEquals(creds, state.getCredentials(scope));

It may be better to just iterate over the set of credentials and do a more manual 
match, instead of 
relying on hashCode().

Mike

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to