Documentation ¶
Index ¶
- Constants
- func ConvertStringToPrivateKey(privateKey string) *rsa.PrivateKey
- func ConvertStringToPublicKey(publicKey string) *rsa.PublicKey
- func NewBasicAuthenticator(cfg configlib.Configer, keyProvider KeyProvider) *basicAuthenticator
- type ApplicationToken
- type Authenticator
- type JWTHeader
- type JWTPayload
- type KeyProvider
- type ObjectPermission
- type Permission
- type Roles
- type TokenParser
- type UserToken
Constants ¶
View Source
const ( KeyUserName = "uname" KeyUserUID = "uid" KeyEmail = "email" KeyRoles = "roles" KeyPermission = "permission" KeyValidUntil = "validuntil" KeyApplicationID = "applicationid" KeyToken = "token" UserAuthServiceID = 1 )
Variables ¶
This section is empty.
Functions ¶
func ConvertStringToPrivateKey ¶
func ConvertStringToPrivateKey(privateKey string) *rsa.PrivateKey
func NewBasicAuthenticator ¶
func NewBasicAuthenticator(cfg configlib.Configer, keyProvider KeyProvider) *basicAuthenticator
Types ¶
type ApplicationToken ¶
type Authenticator ¶
type JWTPayload ¶
type KeyProvider ¶
type ObjectPermission ¶
func (ObjectPermission) HasRoleOn ¶
func (o ObjectPermission) HasRoleOn(object, role string) bool
type Permission ¶
type Permission map[string]ObjectPermission
func (Permission) HasRoleOnOjbectType ¶
func (p Permission) HasRoleOnOjbectType(objectType, object, role string) bool
type TokenParser ¶
Click to show internal directories.
Click to hide internal directories.