keystone

package
v1.0.0-alpha4 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2018 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Overview

Package keystone contains identity providers that validate against keystone servers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewIdentityProvider

func NewIdentityProvider(p Params) idp.IdentityProvider

NewIdentityProvider creates an interactive keystone identity provider with the configuration defined by p.

func NewTokenIdentityProvider

func NewTokenIdentityProvider(p Params) idp.IdentityProvider

NewTokenIdentityProvider creates a idp.IdentityProvider which will authenticate against a keystone server using existing tokens.

func NewUserpassIdentityProvider

func NewUserpassIdentityProvider(p Params) idp.IdentityProvider

NewTokenIdentityProvider creates a idp.IdentityProvider which will authenticate against a keystone server using a httpbakery.form compatible login method.

func NewV3TokenIdentityProvider

func NewV3TokenIdentityProvider(p Params) idp.IdentityProvider

NewV3TokenIdentityProvider creates a idp.IdentityProvider which will authenticate against a keystone (version 3) server using existing tokens.

Types

type Params

type Params struct {
	// Name is the name that the identity provider will have within
	// the identity manager. The name is used as part of the url for
	// communicating with the identity provider.
	Name string `yaml:"name"`

	// If Domain is set it will be appended to any usernames or
	// groups provided by the identity provider. A user created by
	// this identity provide would be username@domain.
	Domain string `yaml:"domain"`

	// Description is a human readable description that will be used
	// if a list of providers is shown for a user to choose.
	Description string `yaml:"description"`

	// URL is the address of the keystone server.
	URL string `yaml:"url"`
}

Params holds the parameters to use with keystone identity providers.

type Token

type Token struct {
	Login struct {
		Domain idName `json:"domain"`
		User   idName `json:"user"`
		Tenant idName `json:"tenant"`
		ID     string `json:"id"`
	} `json:"login"`
}

Token is the token sent to use to login to the keystone server. The only part that is used is Login.ID.

type TokenInteractionInfo

type TokenInteractionInfo struct {
	URL string `json:"url"`
}

TokenInteractionInfo is the interaction info for a token interactor.

type TokenLoginRequest

type TokenLoginRequest struct {
	httprequest.Route `httprequest:"POST"`
	Token             Token `httprequest:",body"`
}

TokenLoginRequest is the request sent for a token login.

type TokenLoginResponse

type TokenLoginResponse struct {
	DischargeToken *httpbakery.DischargeToken `json:"discharge-token"`
}

TokenLoginResponse is the response sent for a token login.

Directories

Path Synopsis
internal
keystone
Package keystone implements a keystone client.
Package keystone implements a keystone client.

Jump to

Keyboard shortcuts

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