We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 744cf52 commit 9b9504eCopy full SHA for 9b9504e
internal/api/handlers/v0/auth/http.go
@@ -43,6 +43,11 @@ func NewDefaultHTTPKeyFetcher() *DefaultHTTPKeyFetcher {
43
return &DefaultHTTPKeyFetcher{
44
client: &http.Client{
45
Timeout: 10 * time.Second,
46
+ // Disable redirects for security purposes:
47
+ // Prevents people doing weird things like sending us to internal endpoints at different paths
48
+ CheckRedirect: func(req *http.Request, via []*http.Request) error {
49
+ return http.ErrUseLastResponse
50
+ },
51
},
52
}
53
0 commit comments