This commit is contained in:
laodaming
2023-11-22 10:19:27 +08:00
parent 53a99c36b1
commit 50e8a42e34
15 changed files with 16 additions and 16 deletions

View File

@@ -6,9 +6,9 @@ import (
)
// 验证权限
func (l *Ldap) VerifyAuthority(r *http.Request, jwtSecret string) bool {
func (l *Ldap) VerifyAuthority(r *http.Request) bool {
token := r.Header.Get("Ldap-Authorization")
info, err := l.ParseJwtToken(token, jwtSecret)
info, err := l.ParseJwtToken(token, l.jwtSecret)
if err != nil {
logx.Error("解析token失败", err, "----token:", token)
return false