Skip to content
This repository was archived by the owner on Jan 24, 2019. It is now read-only.

Commit 6b842a5

Browse files
committed
Redirect to root if redirect URI equals the sign in page
1 parent d06567b commit 6b842a5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

oauthproxy.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,9 @@ func (p *OAuthProxy) GetRedirect(req *http.Request) (redirect string, err error)
419419
if redirect == "" || !strings.HasPrefix(redirect, "/") || strings.HasPrefix(redirect, "//") {
420420
redirect = req.URL.RequestURI()
421421
}
422+
if redirect == p.SignInPath {
423+
redirect = "/"
424+
}
422425

423426
return
424427
}

0 commit comments

Comments
 (0)