requests

package
v0.0.0-...-a01d22e Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2019 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AadInstanceDiscovery

type AadInstanceDiscovery struct {
	// contains filtered or unexported fields
}

func CreateAadInstanceDiscovery

func CreateAadInstanceDiscovery() *AadInstanceDiscovery

func (*AadInstanceDiscovery) GetMetadataEntry

func (d *AadInstanceDiscovery) GetMetadataEntry(authorityInfo *msalbase.AuthorityInfo) (*instanceDiscoveryMetadata, error)

type AuthorityEndpointResolutionManager

type AuthorityEndpointResolutionManager struct {
	// contains filtered or unexported fields
}

func (*AuthorityEndpointResolutionManager) ResolveEndpoints

func (m *AuthorityEndpointResolutionManager) ResolveEndpoints(authorityInfo *msalbase.AuthorityInfo, userPrincipalName string) (*msalbase.AuthorityEndpoints, error)

type CloudEnvironmentInfo

type CloudEnvironmentInfo struct {
	// contains filtered or unexported fields
}

func CreateCloudEnvironmentInfo

func CreateCloudEnvironmentInfo(preferredNetwork string, preferredCache string, aliases []string) *CloudEnvironmentInfo

func (*CloudEnvironmentInfo) GetAliases

func (c *CloudEnvironmentInfo) GetAliases() map[string]bool

func (*CloudEnvironmentInfo) GetPreferredCache

func (c *CloudEnvironmentInfo) GetPreferredCache() string

func (*CloudEnvironmentInfo) GetPreferredNetwork

func (c *CloudEnvironmentInfo) GetPreferredNetwork() string

type ContentType

type ContentType int

ContentType stuff

const (
	// SoapXMLUtf8 stuff
	SoapXMLUtf8 ContentType = iota
	// URLEncodedUtf8 stuff
	URLEncodedUtf8
)

type DeviceCodeRequest

type DeviceCodeRequest struct {
	// contains filtered or unexported fields
}

DeviceCodeRequest stuff

func CreateDeviceCodeRequest

func CreateDeviceCodeRequest(
	webRequestManager IWebRequestManager,
	cacheManager msalbase.ICacheManager,
	authParameters *msalbase.AuthParametersInternal) *DeviceCodeRequest

CreateDeviceCodeRequest stuff

func (*DeviceCodeRequest) Execute

func (req *DeviceCodeRequest) Execute() (*msalbase.TokenResponse, error)

Execute stuff

type EnvironmentMetadata

type EnvironmentMetadata struct {
	// contains filtered or unexported fields
}

func CreateEnvironmentMetadata

func CreateEnvironmentMetadata(webRequestManager IWebRequestManager) *EnvironmentMetadata

func (*EnvironmentMetadata) QueryCloudEnvironmentInfoFromServer

func (em *EnvironmentMetadata) QueryCloudEnvironmentInfoFromServer(environment string) *CloudEnvironmentInfo

type IAadInstanceDiscovery

type IAadInstanceDiscovery interface {
	GetMetadataEntry(authorityInfo *msalbase.AuthorityInfo) (*instanceDiscoveryMetadata, error)
}

type IAuthorityEndpointResolutionManager

type IAuthorityEndpointResolutionManager interface {
	ResolveEndpoints(authorityInfo *msalbase.AuthorityInfo, userPrincipalName string) (*msalbase.AuthorityEndpoints, error)
}

func CreateAuthorityEndpointResolutionManager

func CreateAuthorityEndpointResolutionManager(webRequestManager IWebRequestManager) IAuthorityEndpointResolutionManager

type IOpenIdConfigurationEndpointManager

type IOpenIdConfigurationEndpointManager interface {
	// contains filtered or unexported methods
}

type IRealmMetadata

type IRealmMetadata interface {
	QueryCanonicalRealmFromServer(authParameters *msalbase.AuthParametersInternal) (string, error)
}

type ITokenRequester

type ITokenRequester interface {
	Execute() (*msalbase.TokenResponse, error)
}

type IWebRequestManager

type IWebRequestManager interface {
	GetUserRealm(authParameters *msalbase.AuthParametersInternal) (*msalbase.UserRealm, error)
	GetMex(federationMetadataURL string) (*wstrust.WsTrustMexDocument, error)
	GetWsTrustResponse(authParameters *msalbase.AuthParametersInternal, cloudAudienceURN string, endpoint *wstrust.WsTrustEndpoint) (*wstrust.WsTrustResponse, error)

	GetAccessTokenFromSamlGrant(authParameters *msalbase.AuthParametersInternal, samlGrant *wstrust.SamlTokenInfo) (*msalbase.TokenResponse, error)
	GetAccessTokenFromUsernamePassword(authParameters *msalbase.AuthParametersInternal) (*msalbase.TokenResponse, error)
	GetAccessTokenFromAuthCode(authParameters *msalbase.AuthParametersInternal, authCode string) (*msalbase.TokenResponse, error)
	GetAccessTokenFromRefreshToken(authParameters *msalbase.AuthParametersInternal, refreshToken string) (*msalbase.TokenResponse, error)
	GetAccessTokenWithCertificate(authParameters *msalbase.AuthParametersInternal, certificate *msalbase.ClientCertificate) (*msalbase.TokenResponse, error)
	GetDeviceCodeResult(authParameters *msalbase.AuthParametersInternal) (*msalbase.DeviceCodeResult, error)
	GetAccessTokenFromDeviceCodeResult(authParameters *msalbase.AuthParametersInternal, deviceCodeResult *msalbase.DeviceCodeResult) (*msalbase.TokenResponse, error)

	GetTenantDiscoveryResponse(openIDConfigurationEndpoint string) (*TenantDiscoveryResponse, error)
	GetAadinstanceDiscoveryResponse(authorityInfo *msalbase.AuthorityInfo) (*InstanceDiscoveryResponse, error)

	GetProviderConfigurationInformation(authParameters *msalbase.AuthParametersInternal) (*ProviderConfigurationInformation, error)
}

IWebRequestManager interface

func CreateWebRequestManager

func CreateWebRequestManager(httpManager *msalbase.HTTPManager) IWebRequestManager

CreateWebRequestManager stuff

type InstanceDiscoveryResponse

type InstanceDiscoveryResponse struct {
	TenantDiscoveryEndpoint string                      `json:"tenant_discovery_endpoint"`
	Metadata                []instanceDiscoveryMetadata `json:"metadata"`
}

InstanceDiscoveryResponse stuff

type InteractiveRequest

type InteractiveRequest struct {
	// contains filtered or unexported fields
}

InteractiveRequest stuff

func CreateInteractiveRequest

func CreateInteractiveRequest(
	webRequestManager IWebRequestManager,
	cacheManager msalbase.ICacheManager,
	authParameters *msalbase.AuthParametersInternal) *InteractiveRequest

CreateInteractiveRequest stuff

func (*InteractiveRequest) Execute

func (req *InteractiveRequest) Execute() (*msalbase.TokenResponse, error)

Execute stuff

type NetworkedCacheManager

type NetworkedCacheManager struct {
	// contains filtered or unexported fields
}

type ProviderConfigurationInformation

type ProviderConfigurationInformation struct {
	AuthorizationEndpoint string `json:"authorization_endpoint"`
}

type RealmMetadata

type RealmMetadata struct {
	// contains filtered or unexported fields
}

func CreateRealmMetadata

func CreateRealmMetadata(webRequestManager IWebRequestManager) *RealmMetadata

func (*RealmMetadata) QueryCanonicalRealmFromServer

func (meta *RealmMetadata) QueryCanonicalRealmFromServer(authParameters *msalbase.AuthParametersInternal) (string, error)

type RefreshTokenExchangeRequest

type RefreshTokenExchangeRequest struct {
	// contains filtered or unexported fields
}

RefreshTokenExchangeRequest stuff

func CreateRefreshTokenExchangeRequest

func CreateRefreshTokenExchangeRequest(
	webRequestManager IWebRequestManager,
	cacheManager msalbase.ICacheManager,
	authParameters *msalbase.AuthParametersInternal) *RefreshTokenExchangeRequest

CreateRefreshTokenExchangeRequest stuff

func (*RefreshTokenExchangeRequest) Execute

Execute stuff

type TenantDiscoveryResponse

type TenantDiscoveryResponse struct {
	BaseResponse *msalbase.OAuthResponseBase

	AuthorizationEndpoint string `json:"authorization_endpoint"`
	TokenEndpoint         string `json:"token_endpoint"`
	Issuer                string `json:"issuer"`
}

TenantDiscoveryResponse stuff

func (*TenantDiscoveryResponse) HasAuthorizationEndpoint

func (r *TenantDiscoveryResponse) HasAuthorizationEndpoint() bool

HasAuthorizationEndpoint stuff

func (*TenantDiscoveryResponse) HasIssuer

func (r *TenantDiscoveryResponse) HasIssuer() bool

HasIssuer stuff

func (*TenantDiscoveryResponse) HasTokenEndpoint

func (r *TenantDiscoveryResponse) HasTokenEndpoint() bool

HasTokenEndpoint stuff

type UsernamePasswordRequest

type UsernamePasswordRequest struct {
	// contains filtered or unexported fields
}

UsernamePasswordRequest stuff

func CreateUsernamePasswordRequest

func CreateUsernamePasswordRequest(
	webRequestManager IWebRequestManager,
	cacheManager msalbase.ICacheManager,
	authParameters *msalbase.AuthParametersInternal) *UsernamePasswordRequest

CreateUsernamePasswordRequest stuff

func (*UsernamePasswordRequest) Execute

Execute stuff

type WebRequestManager

type WebRequestManager struct {
	// contains filtered or unexported fields
}

WebRequestManager stuff

func (*WebRequestManager) GetAadinstanceDiscoveryResponse

func (wrm *WebRequestManager) GetAadinstanceDiscoveryResponse(
	authorityInfo *msalbase.AuthorityInfo) (*InstanceDiscoveryResponse, error)

GetAadinstanceDiscoveryResponse stuff

func (*WebRequestManager) GetAccessTokenFromAuthCode

func (wrm *WebRequestManager) GetAccessTokenFromAuthCode(authParameters *msalbase.AuthParametersInternal, authCode string) (*msalbase.TokenResponse, error)

GetAccessTokenFromAuthCode stuff

func (*WebRequestManager) GetAccessTokenFromDeviceCodeResult

func (wrm *WebRequestManager) GetAccessTokenFromDeviceCodeResult(authParameters *msalbase.AuthParametersInternal, deviceCodeResult *msalbase.DeviceCodeResult) (*msalbase.TokenResponse, error)

GetAccessTokenFromDeviceCodeResult stuff

func (*WebRequestManager) GetAccessTokenFromRefreshToken

func (wrm *WebRequestManager) GetAccessTokenFromRefreshToken(authParameters *msalbase.AuthParametersInternal, refreshToken string) (*msalbase.TokenResponse, error)

GetAccessTokenFromRefreshToken stuff

func (*WebRequestManager) GetAccessTokenFromSamlGrant

func (wrm *WebRequestManager) GetAccessTokenFromSamlGrant(authParameters *msalbase.AuthParametersInternal, samlGrant *wstrust.SamlTokenInfo) (*msalbase.TokenResponse, error)

GetAccessTokenFromSamlGrant stuff

func (*WebRequestManager) GetAccessTokenFromUsernamePassword

func (wrm *WebRequestManager) GetAccessTokenFromUsernamePassword(
	authParameters *msalbase.AuthParametersInternal) (*msalbase.TokenResponse, error)

GetAccessTokenFromUsernamePassword stuff

func (*WebRequestManager) GetAccessTokenWithCertificate

func (wrm *WebRequestManager) GetAccessTokenWithCertificate(authParameters *msalbase.AuthParametersInternal, certificate *msalbase.ClientCertificate) (*msalbase.TokenResponse, error)

GetAccessTokenWithCertificate stuff

func (*WebRequestManager) GetDeviceCodeResult

func (wrm *WebRequestManager) GetDeviceCodeResult(authParameters *msalbase.AuthParametersInternal) (*msalbase.DeviceCodeResult, error)

GetDeviceCodeResult stuff

func (*WebRequestManager) GetMex

func (wrm *WebRequestManager) GetMex(federationMetadataURL string) (*wstrust.WsTrustMexDocument, error)

GetMex stuff

func (*WebRequestManager) GetProviderConfigurationInformation

func (wrm *WebRequestManager) GetProviderConfigurationInformation(authParameters *msalbase.AuthParametersInternal) (*ProviderConfigurationInformation, error)

func (*WebRequestManager) GetTenantDiscoveryResponse

func (wrm *WebRequestManager) GetTenantDiscoveryResponse(
	openIDConfigurationEndpoint string) (*TenantDiscoveryResponse, error)

GetTenantDiscoveryResponse stuff

func (*WebRequestManager) GetUserRealm

func (wrm *WebRequestManager) GetUserRealm(authParameters *msalbase.AuthParametersInternal) (*msalbase.UserRealm, error)

GetUserRealm stuff

func (*WebRequestManager) GetWsTrustResponse

func (wrm *WebRequestManager) GetWsTrustResponse(
	authParameters *msalbase.AuthParametersInternal,
	cloudAudienceURN string,
	endpoint *wstrust.WsTrustEndpoint) (*wstrust.WsTrustResponse, error)

GetWsTrustResponse stuff

Jump to

Keyboard shortcuts

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