Documentation
¶
Index ¶
- type Auth
- func (r *Auth) Authenticate(credential identsdk.CredentialIfc) (sesssdk.SessionIfc, error)
- func (r *Auth) AuthorizeSessionRequest(sessionId sesssdk.SessionId, requestMetadata metadata.MetadataIfc) (bool, error)
- func (r *Auth) CheckIDPIdentity(identity identsdk.IdentityIfc) bool
- func (r *Auth) GetSessionIdentity(sessionId sesssdk.SessionId) (identsdk.IdentityIfc, error)
- func (r *Auth) Start() error
- type AuthFactory
- type AuthIfc
- type AuthorizorIfc
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Auth ¶
type Auth struct {
// Embedded struct(s)
*dep.DependencyInjectable
*startable.Startable
// contains filtered or unexported fields
}
Exported to support embedding
func (*Auth) Authenticate ¶
func (r *Auth) Authenticate(credential identsdk.CredentialIfc) (sesssdk.SessionIfc, error)
Authenticate Credential, return (Session, nil) on success, or (nil, error)
func (*Auth) AuthorizeSessionRequest ¶
func (r *Auth) AuthorizeSessionRequest(sessionId sesssdk.SessionId, requestMetadata metadata.MetadataIfc) (bool, error)
Authorize Session for action against Resource; return (true, nil) on success, or (false, error)
func (*Auth) CheckIDPIdentity ¶
func (r *Auth) CheckIDPIdentity(identity identsdk.IdentityIfc) bool
Check this Identity against the IDP
func (*Auth) GetSessionIdentity ¶
Get the identity for the Session
type AuthFactory ¶
A Factory function to unpack provided Config into an initialized Auth package
type AuthIfc ¶
type AuthIfc interface {
// Embedded interface(s)
dep.DependencyInjectableIfc
startable.StartableIfc
// Our own interface
// Authenticate Credentiail (convert a Credential into a Session)
Authenticate(credential identsdk.CredentialIfc) (sesssdk.SessionIfc, error)
// Get Session Identity (convert a Session into an Identity)
GetSessionIdentity(sessionId sesssdk.SessionId) (identsdk.IdentityIfc, error)
// Is the Identity for the Session with this sessionId Authorized for the given Resource?
AuthorizeSessionRequest(sessionId sesssdk.SessionId, requestMetadata metadata.MetadataIfc) (bool, error)
// Check this Identity against the IDP
CheckIDPIdentity(identity identsdk.IdentityIfc) bool
}
type AuthorizorIfc ¶
type AuthorizorIfc interface {
// Embedded Interface(s)
startable.StartableIfc
// Our own interface
// Is this Identity's Grants Authorized for the given Resource?
IsAuthorized(identity identsdk.IdentityIfc, requestMetadata metadata.MetadataIfc) (bool, error)
}
Click to show internal directories.
Click to hide internal directories.