obtainer

package
v0.0.0-...-7350472 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2017 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TicketPath = "/protocol/openid-connect/token"
	DriverName = "keycloak"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type KeycloakObtainer

type KeycloakObtainer struct{}

func (*KeycloakObtainer) Login

func (o *KeycloakObtainer) Login(serverAddr, username, password, clientID string) (string, error)

Login queries and returns the token object

func (*KeycloakObtainer) Logout

func (o *KeycloakObtainer) Logout(_, _ string) error

Logout expires the ticket (Not applicable in the current flow)

func (*KeycloakObtainer) RequestTicket

func (o *KeycloakObtainer) RequestTicket(serverAddr, sToken, clientID string) (string, error)

RequestTicket returns the id_token

acquired either from the token object given in the parameter sToken or by requesting it from the server

type Token

type Token struct {
	RefreshToken string `json:"refresh_token"`
	IdToken      string `json:"id_token"`
}

Jump to

Keyboard shortcuts

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