Hsnmohd commented on PR #925: URL: https://github.com/apache/httpcomponents-client/pull/925#issuecomment-6708136081
@ok2c Fair, the host:port check was the wrong tool for that. Reworked it the way you suggested: `AuthScope` now carries an optional `ChallengeType` (null applies to both), Basic, Digest, Bearer and SCRAM set it from the challenge they processed, and `SystemDefaultCredentialsProvider` asks the `Authenticator` for `SERVER` on target challenges and `PROXY` on proxy challenges. Untyped scopes keep the existing SERVER-then-PROXY lookup. The challenge type is left out of `equals`/`hashCode`/`match`, since including it breaks exact-scope lookups in existing providers (it tripped the `eq(new AuthScope(...))` stubs in `TestAuthenticationHandler`). I can make it part of `match` if you want `BasicCredentialsProvider` to honor it too. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
