mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-03 12:30:19 +08:00
Support cred auto-login.
This commit is contained in:
@ -67,7 +67,7 @@ func checkPassword(user *User, password string) string {
|
||||
return "password incorrect"
|
||||
}
|
||||
} else if organization.PasswordType == "salt" {
|
||||
if getSaltedPassword(password, organization.PasswordSalt) == user.Password {
|
||||
if password == user.Password || getSaltedPassword(password, organization.PasswordSalt) == user.Password {
|
||||
return ""
|
||||
} else {
|
||||
return "password incorrect"
|
||||
|
Reference in New Issue
Block a user