(config AuthServiceConfig, docker *DockerService, ldap *LdapService, queries *repository.Queries, oauthBroker *OAuthBrokerService)
| 98 | } |
| 99 | |
| 100 | func NewAuthService(config AuthServiceConfig, docker *DockerService, ldap *LdapService, queries *repository.Queries, oauthBroker *OAuthBrokerService) *AuthService { |
| 101 | return &AuthService{ |
| 102 | config: config, |
| 103 | docker: docker, |
| 104 | loginAttempts: make(map[string]*LoginAttempt), |
| 105 | ldapGroupsCache: make(map[string]*LdapGroupsCache), |
| 106 | oauthPendingSessions: make(map[string]*OAuthPendingSession), |
| 107 | ldap: ldap, |
| 108 | queries: queries, |
| 109 | oauthBroker: oauthBroker, |
| 110 | } |
| 111 | } |
| 112 | |
| 113 | func (auth *AuthService) Init() error { |
| 114 | go auth.CleanupOAuthSessionsRoutine() |
no outgoing calls