auth

package
v0.0.0-...-7426b64 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: BSD-3-Clause Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var OpenURI = osutils.OpenURI

OpenURI aliases to osutils.OpenURI which opens the given URI in your browser. This is being exposed so that it can be overwritten in tests

Functions

func Authenticate

func Authenticate(cfg keypairs.Configurable, out output.Outputer, prompt prompt.Prompter, auth *authentication.Auth) error

Authenticate will prompt the user for authentication

func AuthenticateWithBrowser

func AuthenticateWithBrowser(out output.Outputer, auth *authentication.Auth, prompt prompt.Prompter, cfg keypairs.Configurable) error

AuthenticateWithBrowser attempts to authenticate this device with the Platform.

func AuthenticateWithCredentials

func AuthenticateWithCredentials(credentials *mono_models.Credentials, auth *authentication.Auth) error

AuthenticateWithCredentials will attempt authenticate using the given credentials

func AuthenticateWithInput

func AuthenticateWithInput(
	username, password, totp string,
	nonInteractive bool,
	cfg keypairs.Configurable,
	out output.Outputer,
	prompt prompt.Prompter,
	auth *authentication.Auth,
) error

AuthenticateWithInput will prompt the user for authentication if the input doesn't already provide it

func AuthenticateWithToken

func AuthenticateWithToken(token string, auth *authentication.Auth) error

AuthenticateWithToken will try to authenticate with the provided token

func RequireAuthentication

func RequireAuthentication(message string, cfg keypairs.Configurable, out output.Outputer, prompt prompt.Prompter, auth *authentication.Auth) error

RequireAuthentication will prompt the user for authentication if they are not already authenticated. If the authentication is not successful it will return a failure

func SignupWithBrowser

func SignupWithBrowser(out output.Outputer, auth *authentication.Auth, prompt prompt.Prompter, cfg keypairs.Configurable) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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