mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-06 10:21:05 +02:00
Desimone/authenticate default logout (#1390)
* authenticate: fix unset post_logout_redirect_uri * don't show url if does not exist Signed-off-by: Bobby DeSimone <bobbydesimone@gmail.com>
This commit is contained in:
parent
0834f24907
commit
7d10b3ddd4
3 changed files with 6 additions and 6 deletions
|
@ -270,7 +270,7 @@ func (a *Authenticate) SignOut(w http.ResponseWriter, r *http.Request) error {
|
|||
a.sessionStore.ClearSession(w, r)
|
||||
redirectString := r.FormValue(urlutil.QueryRedirectURI)
|
||||
endSessionURL, err := a.provider.LogOut()
|
||||
if err == nil {
|
||||
if err == nil && redirectString != "" {
|
||||
params := url.Values{}
|
||||
params.Add("post_logout_redirect_uri", redirectString)
|
||||
endSessionURL.RawQuery = params.Encode()
|
||||
|
|
|
@ -27,11 +27,12 @@
|
|||
<section>
|
||||
<p class="message">Your current session details.</p>
|
||||
<fieldset>
|
||||
{{if .RedirectURL}}
|
||||
<label>
|
||||
<span>URL</span>
|
||||
<a href="{{.RedirectURL}}">{{.RedirectURL}}</a>
|
||||
</label>
|
||||
|
||||
{{end}}
|
||||
{{if .User.Name}}
|
||||
<label>
|
||||
<span>Name</span>
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Add table
Add a link
Reference in a new issue