Back to godoc.org

Package auth

v1.0.0
Latest Go to latest

The highest tagged major version is .

Published: Jul 27, 2020 | License: Apache-2.0 | Module: github.com/IBM/ibmcloud-volume-interface

Overview

Package auth ...

Index

type AccessToken

type AccessToken struct {
	Token string `json:"-"` // Do not trace
}

AccessToken ...

type IMSToken

type IMSToken struct {
	UserID int    // Numerical ID is safe to trace
	Token  string `json:"-"` // Do not trace
}

IMSToken ...

type TokenExchangeService

type TokenExchangeService interface {

	// ExchangeRefreshTokenForAccessToken ...
	// TODO Deprecate when no longer reliant on refresh token authentication
	ExchangeRefreshTokenForAccessToken(refreshToken string, logger *zap.Logger) (*AccessToken, error)

	// ExchangeAccessTokenForIMSToken ...
	ExchangeAccessTokenForIMSToken(accessToken AccessToken, logger *zap.Logger) (*IMSToken, error)

	// ExchangeIAMAPIKeyForIMSToken ...
	ExchangeIAMAPIKeyForIMSToken(iamAPIKey string, logger *zap.Logger) (*IMSToken, error)

	// ExchangeIAMAPIKeyForAccessToken ...
	ExchangeIAMAPIKeyForAccessToken(iamAPIKey string, logger *zap.Logger) (*AccessToken, error)

	// GetIAMAccountIDFromAccessToken ...
	GetIAMAccountIDFromAccessToken(accessToken AccessToken, logger *zap.Logger) (string, error)
}

TokenExchangeService ...

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier