redirector

package
Version: v3.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewChallenger

func NewChallenger(baseRequestURL *url.URL, redirectURL string) oauthhandlers.AuthenticationChallenger

NewChallenger returns an oauthhandlers.AuthenticationChallenger that returns a Location header to the specified redirectURL. Request URLs missing scheme/host, or with relative paths are resolved relative to the baseRequestURL, if specified. The following tokens are replaceable in the query of the redirectURL:

${url} is replaced with the current request URL, escaped as a query parameter. Example: https://www.example.com/login?then=${url}
${query} is replaced with the current request query, unescaped. Example: https://www.example.com/sso/oauth/authorize?${query}

func NewRedirector

func NewRedirector(baseRequestURL *url.URL, redirectURL string) oauthhandlers.AuthenticationRedirector

NewRedirector returns an oauthhandlers.AuthenticationRedirector that redirects to the specified redirectURL. Request URLs missing scheme/host, or with relative paths are resolved relative to the baseRequestURL, if specified. The following tokens are replaceable in the query of the redirectURL:

${url} is replaced with the current request URL, escaped as a query parameter. Example: https://www.example.com/login?then=${url}
${query} is replaced with the current request query, unescaped. Example: https://www.example.com/sso/oauth/authorize?${query}

Types

This section is empty.

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL