NewBasicAuthRoundTripper will apply a BASIC auth authorization header to a request unless it has already been set.
(username string, password Secret, usernameFile, passwordFile string, rt http.RoundTripper)
| 658 | // NewBasicAuthRoundTripper will apply a BASIC auth authorization header to a request unless it has |
| 659 | // already been set. |
| 660 | func NewBasicAuthRoundTripper(username string, password Secret, usernameFile, passwordFile string, rt http.RoundTripper) http.RoundTripper { |
| 661 | return &basicAuthRoundTripper{username, password, usernameFile, passwordFile, rt} |
| 662 | } |
| 663 | |
| 664 | func (rt *basicAuthRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) { |
| 665 | var username string |
no outgoing calls
no test coverage detected