request

package
v0.1.9 Latest Latest
Warning

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

Go to latest
Published: May 30, 2021 License: BSD-3-Clause Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessGrantType

type AccessGrantType string
const (
	ACCESS_GRANT_AUTHORIZATION_CODE AccessGrantType = "authorization_code"
	ACCESS_GRANT_REFRESH_TOKEN      AccessGrantType = "refresh_token"
	ACCESS_GRANT_PASSWORD           AccessGrantType = "password"
	ACCESS_GRANT_CLIENT_CREDENTIALS AccessGrantType = "client_credentials"
	ACCESS_GRANT_ASSERTION          AccessGrantType = "assertion"
	ACCESS_GRANT_IMPLICIT           AccessGrantType = "__implicit"
)

type AccessRequest

type AccessRequest struct {
	Username  string
	Password  string
	Code      string
	GrantType AccessGrantType

	ClientId     string
	ClientSecret string

	Scope string
	State string

	// Set if request is authorized
	Authorized bool

	// Token expiration in seconds. Change if different from default.
	// If type = TOKEN, this expiration will be for the ACCESS token.
	Expiration int32

	// Optional code_verifier as described in rfc7636
	CodeVerifier string

	// Optional code_verifier as described in rfc7636
	CodeVerifierMethod string
}

Authorize request information

type AllowedAccessGrantType

type AllowedAccessGrantType []AccessGrantType

AllowedAuthorizeType is a collection of allowed auth request types

func (AllowedAccessGrantType) Exists

Exists returns true if the auth type exists in the list

type AllowedAuthorizeResponseType

type AllowedAuthorizeResponseType []AuthorizeResponseType

AllowedAuthorizeType is a collection of allowed auth request types

func (AllowedAuthorizeResponseType) Exists

Exists returns true if the auth type exists in the list

type AuthorizeRequest

type AuthorizeRequest struct {
	ClientId     string
	ClientSecret string
	ResponseType AuthorizeResponseType
	RedirectUri  string
	Scope        string
	State        string
	Username     string
	Password     string
	EMail        string
	Mobile       string

	// Optional code_challenge as described in rfc7636
	CodeChallenge string

	// Optional code_challenge_method as described in rfc7636
	CodeChallengeMethod string
}

Authorize request information

type AuthorizeResponseType

type AuthorizeResponseType string
const (
	AUTHORIZE_RESPONSE_CODE     AuthorizeResponseType = "code"
	AUTHORIZE_RESPONSE_LOGIN    AuthorizeResponseType = "login"
	AUTHORIZE_RESPONSE_REGISTER AuthorizeResponseType = "register"
	AUTHORIZE_RESPONSE_TOKEN    AuthorizeResponseType = "token"
)

type InfoRequest

type InfoRequest struct {
	Code  string
	State string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL