login

package
v2.0.0-alpha.2 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// OAuth2AuthURLFlag is the viper flag for the OAuth 2.0 authorization endpoint.
	OAuth2AuthURLFlag = "oauth2-auth-url"

	// OAuth2TokenURLFlag is the viper flag for the OAuth 2.0 token endpoint.
	OAuth2TokenURLFlag = "oauth2-token-url"

	// OAuth2ClientIDFlag is the viper flag for the OAuth 2.0 client ID.
	OAuth2ClientIDFlag = "oauth2-client-id"

	// DefaultOAuth2Server is the default OAuth 2.0 authorization endpoint.
	DefaultOAuth2AuthURL = "http://localhost:8080/v1/auth/authorize"

	// DefaultOAuth2TokenURL is the default OAuth 2.0 token endpoint.
	DefaultOAuth2TokenURL = "http://localhost:8080/v1/auth/token"

	// DefaultClientID is the default OAuth 2.0 client ID for the CLI.
	DefaultClientID = "cli"

	// DefaultCallbackServerAddress is the default address for the callback server.
	DefaultCallbackServerAddress = "localhost:10000"
)

Variables

View Source
var (
	// DefaultCallback is the default callback URL of the callback server.
	DefaultCallback = fmt.Sprintf("http://%s/callback", DefaultCallbackServerAddress)

	// VerifierGenerator is a function that generates a new verifier.
	VerifierGenerator = oauth2.GenerateSecret
)

Functions

func NewLoginCommand

func NewLoginCommand() *cobra.Command

NewLoginCommand returns a cobra command for `login` subcommands

Types

This section is empty.

Jump to

Keyboard shortcuts

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