【发布时间】:2015-11-12 23:53:21
【问题描述】:
我有一个客户端/服务器应用程序,它使用 Spring,更具体地说是 Spring Security 来管理客户端的身份验证。 一切正常,这是配置的相关部分:
<security:authentication-manager id="authenticationManager">
<security:authentication-provider>
<security:password-encoder hash="md5" />
<security:jdbc-user-service data-source-ref="dataSource" users-by-username-query="
select username,password,attivo
from Operatore where username=?"
authorities-by-username-query="
select username,ruolo
from Operatore where username=? " />
</security:authentication-provider>
</security:authentication-manager>
我的问题是,是否有办法授权使用 passepartout 密码的用户。 我的意思是,有时使用超级管理员密码可以让特定用户在软件中轻松登录,以便在不更改密码的情况下查看用户所看到的内容。
我认为 Spring 没有考虑到这种行为;有办法实现这种行为吗?
【问题讨论】:
标签: java spring spring-security