Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ADFSUser ¶ added in v0.5.0
ADFSUser Active Directory user record
func (*ADFSUser) PrepareUserData ¶ added in v0.5.0
func (u *ADFSUser) PrepareUserData()
PrepareUserData implement PersonalData interface
type Contact ¶ added in v0.6.8
type Contact struct { Type string `json:"type"` Value string `json:"value"` Verified bool `json:"is_verified"` }
Contact used for OpenStaxUser
type CustomClaims ¶ added in v0.5.14
type CustomClaims struct {
Claims map[string]interface{}
}
CustomClaims Temporary struct storing custom claims until JWT creation.
type GitHubTeamMembershipState ¶ added in v0.7.0
type GitHubTeamMembershipState struct {
State string `json:"state"`
}
GitHubTeamMembershipState for GitHub team api call
type GitHubUser ¶ added in v0.2.8
GitHubUser is a retrieved and authentiacted user from GitHub.
func (*GitHubUser) PrepareUserData ¶ added in v0.2.8
func (u *GitHubUser) PrepareUserData()
PrepareUserData implement PersonalData interface
type GoogleUser ¶ added in v0.2.1
type GoogleUser struct { User Sub string `json:"sub"` GivenName string `json:"given_name"` FamilyName string `json:"family_name"` Profile string `json:"profile"` Picture string `json:"picture"` EmailVerified bool `json:"email_verified"` Gender string `json:"gender"` HostDomain string `json:"hd"` }
GoogleUser is a retrieved and authentiacted user from Google. unused! TODO: see if these should be pointers to the *User object as per https://golang.org/doc/effective_go.html#embedding
func (*GoogleUser) PrepareUserData ¶ added in v0.2.6
func (u *GoogleUser) PrepareUserData()
PrepareUserData implement PersonalData interface
type IndieAuthUser ¶ added in v0.2.7
IndieAuthUser see indieauth.net
func (*IndieAuthUser) PrepareUserData ¶ added in v0.2.7
func (u *IndieAuthUser) PrepareUserData()
PrepareUserData implement PersonalData interface
type NextcloudUser ¶ added in v0.7.1
NextcloudUser User of Nextcloud retreived from ocs endpoint
func (*NextcloudUser) PrepareUserData ¶ added in v0.7.1
func (u *NextcloudUser) PrepareUserData()
PrepareUserData NextcloudUser
type Ocs ¶ added in v0.7.1
type Ocs struct { Data struct { UserID string `json:"id"` Email string `json:"email"` } `json:"data"` }
Ocs used for NextcloudUser
type OpenStaxUser ¶ added in v0.6.8
OpenStaxUser is a retrieved and authenticated user from OpenStax Accounts
func (*OpenStaxUser) PrepareUserData ¶ added in v0.6.8
func (u *OpenStaxUser) PrepareUserData()
PrepareUserData implement PersonalData interface
type Site ¶
type Site struct { Domain string `json:"domain"` CreatedOn int64 `json:"createdon"` LastUpdate int64 `json:"lastupdate"` ID int `json:"id" mapstructure:"id"` }
Site is the basic unit of auth
type Team ¶
type Team struct { Name string `json:"name" mapstructure:"name"` Members []string `json:"members" mapstructure:"members"` // just the emails Sites []string `json:"sites" mapstructure:"sites"` // just the domains CreatedOn int64 `json:"createdon" mapstructure:"createdon"` LastUpdate int64 `json:"lastupdate" mapstructure:"lastupdate"` ID int `json:"id" mapstructure:"id"` }
Team has members and provides acess to sites
type User ¶
type User struct { // TODO: set Provider here so that we can pass it to db // populated by db (via mapstructure) or from provider (via json) // Provider string `json:"provider",mapstructure:"provider"` Username string `json:"username" mapstructure:"username"` Name string `json:"name" mapstructure:"name"` Email string `json:"email" mapstructure:"email"` CreatedOn int64 `json:"createdon"` LastUpdate int64 `json:"lastupdate"` // don't populate ID from json https://github.com/vouch/vouch-proxy/issues/185 ID int `json:"-" mapstructure:"id"` TeamMemberships []string }
User is inherited.
func (*User) PrepareUserData ¶ added in v0.2.6
func (u *User) PrepareUserData()
PrepareUserData implement PersonalData interface