SetBasicAuth set basic auth for the request.
(username, password string)
| 444 | |
| 445 | // SetBasicAuth set basic auth for the request. |
| 446 | func (r *Request) SetBasicAuth(username, password string) *Request { |
| 447 | return r.SetHeader(header.Authorization, util.BasicAuthHeaderValue(username, password)) |
| 448 | } |
| 449 | |
| 450 | // SetDigestAuth sets the Digest Access auth scheme for the HTTP request. If a server responds with 401 and sends a |
| 451 | // Digest challenge in the WWW-Authenticate Header, the request will be resent with the appropriate Authorization Header. |