loginserver

package
v1.1.7 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2017 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrSignUpEmailConfirmation = errors.New(`sign up on WeDeploy requested: try "we login" once you confirm your email`)

ErrSignUpEmailConfirmation tells that sign up was canceled because user is signing up

Functions

func OAuthTokenFromBasicAuth

func OAuthTokenFromBasicAuth(c config.Context, remoteAddress, username, password string) (token string, err error)

OAuthTokenFromBasicAuth gets a token from a Basic Auth flow

Types

type Service

type Service struct {
	Infrastructure string
	// contains filtered or unexported fields
}

Service server for receiving JSON Web Token

func (*Service) Credentials

func (s *Service) Credentials() (username string, token string, err error)

Credentials for authenticated user or error, it blocks until the information is available

func (*Service) Listen

func (s *Service) Listen(ctx context.Context) (address string, err error)

Listen for requests

func (*Service) Serve

func (s *Service) Serve() error

Serve HTTP requests

Jump to

Keyboard shortcuts

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