summaryrefslogtreecommitdiffstats
path: root/services/auth/sspi_windows.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2022-01-02 21:12:35 +0800
committerGitHub <noreply@github.com>2022-01-02 21:12:35 +0800
commitde8e3948a5e38f7eaf82d3c0cfd10e995bf68e92 (patch)
treebbcb011d264e0d614d49c734856b446360c5a4a3 /services/auth/sspi_windows.go
parente61b390d545919244141b699b28e3fbc42adc66f (diff)
downloadgitea-de8e3948a5e38f7eaf82d3c0cfd10e995bf68e92.tar.gz
gitea-de8e3948a5e38f7eaf82d3c0cfd10e995bf68e92.zip
Refactor auth package (#17962)
Diffstat (limited to 'services/auth/sspi_windows.go')
-rw-r--r--services/auth/sspi_windows.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/services/auth/sspi_windows.go b/services/auth/sspi_windows.go
index 19f2349122..cadf721796 100644
--- a/services/auth/sspi_windows.go
+++ b/services/auth/sspi_windows.go
@@ -9,8 +9,8 @@ import (
"net/http"
"strings"
+ "code.gitea.io/gitea/models/auth"
"code.gitea.io/gitea/models/avatars"
- "code.gitea.io/gitea/models/login"
user_model "code.gitea.io/gitea/models/user"
"code.gitea.io/gitea/modules/base"
"code.gitea.io/gitea/modules/log"
@@ -154,7 +154,7 @@ func (s *SSPI) Verify(req *http.Request, w http.ResponseWriter, store DataStore,
// getConfig retrieves the SSPI configuration from login sources
func (s *SSPI) getConfig() (*sspi.Source, error) {
- sources, err := login.ActiveSources(login.SSPI)
+ sources, err := auth.ActiveSources(auth.SSPI)
if err != nil {
return nil, err
}
@@ -250,7 +250,7 @@ func sanitizeUsername(username string, cfg *sspi.Source) string {
// fails (or if negotiation should continue), which would prevent other authentication methods
// to execute at all.
func specialInit() {
- if login.IsSSPIEnabled() {
+ if auth.IsSSPIEnabled() {
Register(&SSPI{})
}
}