1.1抢先认证(Preemptive Authentication)在这种模式时,HttpClient会主动将basic认证应答信息传给服务器,即使在某种情况下服务器可能返回认证失败的应答,这样做主要是为...
基于38个网页-相关网页
Listing 6 shows sample code to enable preemptive authentication.
清单6中显示的样例代码可以启用先占式认证。
To use OAuth authentication you need to use preemptive authentication.
要使用OAuth认证,您需要使用先占式认证。
HttpClient does not support preemptive authentication out of the box, but you can use a protocol interceptor to preemptively introduce an AuthScheme instance to the execution context.
HttpClient不支持开箱即用的先占式认证,但是您可以使用一个协议拦截器事先引入一个AuthScheme实例到执行上下文。
应用推荐