keystone

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Dec 31, 2021 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PROTOCOL        = "http://"
	AK_LENGTH       = 16
	SK_LENGTH       = 32
	POST            = "POST"
	GET             = "GET"
	DELETE          = "DELETE"
	AUTH_TOKEN      = "X-Auth-Token"
	CONTENT_TYPE    = "Content-Type"
	APPL_JSON       = "application/json"
	USER_QUERY_STR  = "?user_id="
	USER_DETAILS    = "/identity/v3/users/"
	TENANT_DETAILS  = "/identity/v3/projects/"
	SEPERATOR       = "/"
	CREDENTIAL_TYPE = "ec2"
	CREDS_URI       = "/identity/v3/credentials"
)

Variables

View Source
var Keystone = &KeystoneIam{}

Functions

This section is empty.

Types

type Client

type Client struct {
}

type KeystoneIam

type KeystoneIam struct {
	Host   string
	URI    string
	Client http.Client
}

func Init

func Init(host string) *KeystoneIam

func (*KeystoneIam) CreateAkSk

func (iam *KeystoneIam) CreateAkSk(aksk *model.AkSk, req *pb.AkSkCreateRequest) (*model.Blob, error)

func (*KeystoneIam) DeleteAkSk

func (iam *KeystoneIam) DeleteAkSk(ctx context.Context, in *pb.DeleteAkSkRequest) error

func (*KeystoneIam) DownloadAkSk

func (iam *KeystoneIam) DownloadAkSk(ctx context.Context, in *pb.GetAkSkRequest) (*model.AkSkListOut, error)

func (*KeystoneIam) GetAkSk

func (iam *KeystoneIam) GetAkSk(ctx context.Context, in *pb.GetAkSkRequest) (model.Credentials, error)

func (*KeystoneIam) ValidateId added in v1.4.1

func (iam *KeystoneIam) ValidateId(id string, token string, uri string) (bool, error)

Jump to

Keyboard shortcuts

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