Documentation
¶
Index ¶
- Constants
- func Middleware(blockOnFailure bool) echo.MiddlewareFunc
- type Account
- type AccountType
- type AuthenticationContext
- func (c *AuthenticationContext) Account() *Account
- func (c *AuthenticationContext) EntityType() EntityType
- func (c *AuthenticationContext) ImpersonationContext() *AuthenticationContext
- func (c *AuthenticationContext) IsAdminEntity() bool
- func (c *AuthenticationContext) IsBrandAccount() bool
- func (c *AuthenticationContext) IsFromAdminIdentityProvider() bool
- func (c *AuthenticationContext) IsFromGuestIdentityProvider() bool
- func (c *AuthenticationContext) IsFromImpersonationIdentityProvider() bool
- func (c *AuthenticationContext) IsFromMachineIdentityProvider() bool
- func (c *AuthenticationContext) IsFromUserIdentityProvider() bool
- func (c *AuthenticationContext) IsGuestEntity() bool
- func (c *AuthenticationContext) IsImpersonation() bool
- func (c *AuthenticationContext) IsMachineEntity() bool
- func (c *AuthenticationContext) IsRetailerAccount() bool
- func (c *AuthenticationContext) IsUserEntity() bool
- type EntityType
- type IdentityProviderType
Constants ¶
View Source
const AuthenticationContextKey = "_authentication_context"
Variables ¶
This section is empty.
Functions ¶
func Middleware ¶
func Middleware(blockOnFailure bool) echo.MiddlewareFunc
Types ¶
type Account ¶
type Account struct {
Uuid string `json:"id"`
AccountType AccountType `json:"type"`
}
type AccountType ¶
type AccountType int
const ( UnknownAccount AccountType = iota BrandAccount RetailerAccount )
func (AccountType) String ¶
func (a AccountType) String() string
func (*AccountType) UnmarshalJSON ¶
func (a *AccountType) UnmarshalJSON(data []byte) error
type AuthenticationContext ¶
type AuthenticationContext struct {
Uuid string `json:"sub"`
ClientId string `json:"cid,omitempty"`
IdentityProviderType IdentityProviderType `json:"idp"`
Aks struct {
EntityType EntityType `json:"entity"`
Account *Account `json:"account,omitempty"`
ImpersonationContext *AuthenticationContext `json:"imp,omitempty"`
} `json:"aks"`
}
func (*AuthenticationContext) Account ¶
func (c *AuthenticationContext) Account() *Account
func (*AuthenticationContext) EntityType ¶
func (c *AuthenticationContext) EntityType() EntityType
func (*AuthenticationContext) ImpersonationContext ¶
func (c *AuthenticationContext) ImpersonationContext() *AuthenticationContext
func (*AuthenticationContext) IsAdminEntity ¶
func (c *AuthenticationContext) IsAdminEntity() bool
func (*AuthenticationContext) IsBrandAccount ¶
func (c *AuthenticationContext) IsBrandAccount() bool
func (*AuthenticationContext) IsFromAdminIdentityProvider ¶
func (c *AuthenticationContext) IsFromAdminIdentityProvider() bool
func (*AuthenticationContext) IsFromGuestIdentityProvider ¶
func (c *AuthenticationContext) IsFromGuestIdentityProvider() bool
func (*AuthenticationContext) IsFromImpersonationIdentityProvider ¶
func (c *AuthenticationContext) IsFromImpersonationIdentityProvider() bool
func (*AuthenticationContext) IsFromMachineIdentityProvider ¶
func (c *AuthenticationContext) IsFromMachineIdentityProvider() bool
func (*AuthenticationContext) IsFromUserIdentityProvider ¶
func (c *AuthenticationContext) IsFromUserIdentityProvider() bool
func (*AuthenticationContext) IsGuestEntity ¶
func (c *AuthenticationContext) IsGuestEntity() bool
func (*AuthenticationContext) IsImpersonation ¶
func (c *AuthenticationContext) IsImpersonation() bool
func (*AuthenticationContext) IsMachineEntity ¶
func (c *AuthenticationContext) IsMachineEntity() bool
func (*AuthenticationContext) IsRetailerAccount ¶
func (c *AuthenticationContext) IsRetailerAccount() bool
func (*AuthenticationContext) IsUserEntity ¶
func (c *AuthenticationContext) IsUserEntity() bool
type EntityType ¶
type EntityType int
const ( UnknownEntity EntityType = iota GuestEntity UserEntity AdminEntity MachineEntity )
func (EntityType) String ¶
func (e EntityType) String() string
func (*EntityType) UnmarshalJSON ¶
func (e *EntityType) UnmarshalJSON(data []byte) error
type IdentityProviderType ¶
type IdentityProviderType int
const ( UnknownIdentityProvider IdentityProviderType = iota GuestIdentityProvider UserIdentityProvider AdminIdentityProvider MachineIdentityProvider ImpersonationIdentityProvider )
func (IdentityProviderType) String ¶
func (i IdentityProviderType) String() string
func (*IdentityProviderType) UnmarshalJSON ¶
func (i *IdentityProviderType) UnmarshalJSON(data []byte) error
Click to show internal directories.
Click to hide internal directories.