summaryrefslogtreecommitdiffstats
path: root/modules/auth/pam
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2016-11-27 14:03:59 +0800
committerLunny Xiao <xiaolunwen@gmail.com>2016-11-27 21:39:06 +0800
commitec87a75c000d52bfc2a8dcfc7097c14fe872c376 (patch)
treed849fb1070fe15136538404127099e9a7e0dd302 /modules/auth/pam
parente6da2cf2cbff4d550cf938548233a59ceef6528e (diff)
downloadgitea-ec87a75c000d52bfc2a8dcfc7097c14fe872c376.tar.gz
gitea-ec87a75c000d52bfc2a8dcfc7097c14fe872c376.zip
golint fixed for modules/auth
Diffstat (limited to 'modules/auth/pam')
-rw-r--r--modules/auth/pam/pam.go3
-rw-r--r--modules/auth/pam/pam_stub.go3
2 files changed, 4 insertions, 2 deletions
diff --git a/modules/auth/pam/pam.go b/modules/auth/pam/pam.go
index 7f326d42f5..6f0f7240ae 100644
--- a/modules/auth/pam/pam.go
+++ b/modules/auth/pam/pam.go
@@ -12,7 +12,8 @@ import (
"github.com/msteinert/pam"
)
-func PAMAuth(serviceName, userName, passwd string) error {
+// Auth pam auth service
+func Auth(serviceName, userName, passwd string) error {
t, err := pam.StartFunc(serviceName, userName, func(s pam.Style, msg string) (string, error) {
switch s {
case pam.PromptEchoOff:
diff --git a/modules/auth/pam/pam_stub.go b/modules/auth/pam/pam_stub.go
index 33ac751a34..ee2527dd89 100644
--- a/modules/auth/pam/pam_stub.go
+++ b/modules/auth/pam/pam_stub.go
@@ -10,6 +10,7 @@ import (
"errors"
)
-func PAMAuth(serviceName, userName, passwd string) error {
+// Auth not supported lack of pam tag
+func Auth(serviceName, userName, passwd string) error {
return errors.New("PAM not supported")
}