Documentation
¶
Index ¶
- Variables
- type Profile
- type ProfileBase
- type ProfileOption
- func AccessKey(s string) ProfileOption
- func Affiliation(s string) ProfileOption
- func AppSecret(s string) ProfileOption
- func Email(s string) ProfileOption
- func Firstname(s string) ProfileOption
- func Lastname(s string) ProfileOption
- func Password(s string) ProfileOption
- func ProfilePath(s string) ProfileOption
- func Role(s acl.Role) ProfileOption
- func SecretKey(s string) ProfileOption
- func TeamName(s string) ProfileOption
- func Username(s string) ProfileOption
- type ProfileOptions
- type Provider
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Config = &authConfig{ done: make(chan struct{}), } )
Config ...
View Source
var (
DefaultProfilePath string
)
DefaultProfilePath ...
Functions ¶
This section is empty.
Types ¶
type Profile ¶
type Profile interface {
// Create a profile using the provider specified
Create() error
// Delete a profile
Delete() error
// Information on the profile
Info() ProfileBase
// Verify the profile by looking
// at the provider and checking if the
// credentials match
Verify() (bool, error)
// Profile options
Options() ProfileOptions
// Get the role of the user
// roles are essentially permission
// groups
GetRole() (acl.Role, error)
// Find a profile by an email. The
// profile is found by querying the
// profile provier
FindByEmail() error
}
Profiles are in effect users for rai each user has a profile that's backed by a profile provider
type ProfileBase ¶
type ProfileBase struct {
ProfileOptions `json:"-" bson:",inline" toml:"profile" yaml:"profile"`
}
ProfileBase ...
func NewProfileBase ¶
func NewProfileBase(iopts ...ProfileOption) (*ProfileBase, error)
NewProfileBase ...
Source Files
¶
Click to show internal directories.
Click to hide internal directories.