authentication - Spring Security Core不会解密密码

标签 authentication grails

我按照彼得·莱德布鲁克(Peter Ledbrook)使用 Spring 安全核心的示例进行了截屏。我为用户设置密码,如下所示:

    springSecurityService.encodePassword("password")

当我尝试登录时,它无法正确解密密码。如果我更改了应用程序以不对密码进行加密,它将完美登录。

我看着自动生成的Login Controller ,但看不到它在哪里解密密码。有没有其他人有这个问题?使我无法进行这项工作吗?

谢谢!

最佳答案

从1.2版开始,User域类对密码进行加密,因此,使用springSecurityService.encodePassword可以进行双重编码。查看文档:http://grails-plugins.github.com/grails-spring-security-core/docs/manual/

关于authentication - Spring Security Core不会解密密码,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8564560/

相关文章:

grails - 在grails条件下显示 View 中的消息

grails - Grails-使用sortableColumn对gsp上的实体进行排序

php - 如何以编程方式登录然后使用 Laravel 5.5 重定向?

android - 如果我安装了 Facebook 应用程序,我的 Facebook 登录 Android 应用程序将不会打开 session

ios - 使用自定义后端进行 Firebase 身份验证

grails - 带有navbar-fixed-top的Grails Twitter Bootstrap插件问题

amazon-web-services - 如何在 Facebook 应用等应用上使用 aws cognito 永久登录用户

linux - 我们如何存储明文以外的密码?

json - 在 grails 2.3.4 中使用 rest 客户端生成器的特定名称出错

grails - 显示闪现信息