flow

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2025 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrInvalidGrantType = credstackError.NewError(400, "ERR_INVALID_GRANT", "token: Failed to issue token. The specified grant type does not exist")

ErrInvalidGrantType - A named error that gets returned when an unrecognized grant type is used to attempt to issue tokens

View Source
var ErrInvalidTokenRequest = credstackError.NewError(400, "ERR_INVALID_TOKEN_REQ", "token: Failed to issue token. One or more parts of the token request is missing")

ErrInvalidTokenRequest - An error that gets returned if one or more elements of the token request are missing

View Source
var ErrUnauthorizedAudience = credstackError.NewError(403, "ERR_UNAUTHORIZED_AUDIENCE", "token: Unable to issue token for the specified audience. Application is not authorized too")

ErrUnauthorizedAudience - An error that gets returned when an application tries to issue tokens for an audience that it is not authorized too

View Source
var ErrUnauthorizedGrantType = credstackError.NewError(403, "ERR_UNAUTHORIZED_GRANT_TYPE", "token: Invalid grant type for the specified application")

ErrUnauthorizedGrantType - An error that gets returned when an application tries to issue tokens for a grant type that it is not authorized too

Functions

func ClientCredentialsFlow added in v1.3.1

func ClientCredentialsFlow(serv *server.Server, request *request.TokenRequest, issuer string) (*tokenModel.TokenResponse, error)

ClientCredentialsFlow - Attempts to issue a token under Client Credentials flow and begins any validation required for ensuring that the request received was valid.

func IssueTokenForFlow added in v1.3.1

func IssueTokenForFlow(serv *server.Server, request *request.TokenRequest, issuer string) (*tokenModel.TokenResponse, error)

IssueTokenForFlow - Responsible for issuing access tokens under a specific OAuth authentication flow. Handles validating token requests and marshaling access tokens to a token.TokenResponse structure. Any errors that are returned from this function are wrapped with errors.CredstackError.

Types

This section is empty.

Jump to

Keyboard shortcuts

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