Initial addition of groups to user/policy

This commit is contained in:
Jordan Liggitt
2014-12-16 10:20:05 -05:00
parent 3f926e943a
commit 9d8d313113
4 changed files with 162 additions and 6 deletions

View File

@@ -25,13 +25,16 @@ type Info interface {
// if the user is removed from the system and another user is added with
// the same name.
GetUID() string
// GetGroups returns the names of the groups the user is a member of
GetGroups() []string
}
// DefaultInfo provides a simple user information exchange object
// for components that implement the UserInfo interface.
type DefaultInfo struct {
Name string
UID string
Name string
UID string
Groups []string
}
func (i *DefaultInfo) GetName() string {
@@ -41,3 +44,7 @@ func (i *DefaultInfo) GetName() string {
func (i *DefaultInfo) GetUID() string {
return i.UID
}
func (i *DefaultInfo) GetGroups() []string {
return i.Groups
}