是否有支持嵌套组的 Spring Security DefaultLdapAuthoritiesPopulator 实现?
我正在尝试获取一个使用 Spring Security 来支持嵌套 LDAP 角色的 Pentaho-BI 服务器。我的组结构如下:
- PentahoAdmins(组)
- 成员:域管理员
- 域管理员(组)
- 成员:用户1
- User1(用户)
我想验证 User1 是否是 PentahoAdmins 组的一部分,而不必直接将用户添加到该组中。根据我的在线研究,Spring 的 DefaultLdapAuthoritiesPopulator 似乎不支持嵌套组。我确信可以创建一个支持组嵌套的子类,但是有人已经遇到了这个麻烦并将其发布在开源项目中吗?
I am trying to get a Pentaho-BI server which uses spring security to support nested LDAP roles. My group structure is as follows:
- PentahoAdmins (group)
- Members: Domain Admins
- Domain Admins (group)
- Members: User1
- User1 (user)
I would like to verify that User1 is part of the PentahoAdmins group, without having to add the user to the group directly. From my research online, it doesn't seem like Spring's DefaultLdapAuthoritiesPopulator supports nested groups. I'm sure it's possible to create a subclass that supports group nesting, but has someone already gone to this trouble and published it in an open source project?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
按如下方式配置 LDAP 权限填充器,它将与嵌套组一起使用:
groupSearchFilter 值意味着:
Configure the LDAP authorities populator as below and it will work with nested groups:
The groupSearchFilter value means:
我找到了这篇文章 关于 Microsoft 的 Active Directory。搜索 LDAP_MATCHING_RULE_IN_CHAIN 或上面的链接将显示有关该主题的更多信息。这个想法是,您可以在 Spring Security 配置中为父组和用户的 uid 添加组搜索过滤器:
我使用 Spring LDAP 使用只读上下文来搜索 MS Active Directory 进行了测试,但我尚未确认这一点还没有在 Spring Security 中使用 group-search-filter 。我希望这有帮助。
I found this article in regards to Microsoft's Active Directory. A search for LDAP_MATCHING_RULE_IN_CHAIN or the link above will present more information on the topic. The idea is that you can add a group search filter for the parent group and the uid of the user in your Spring Security config:
I tested this with Spring LDAP using a read-only context to search MS Active Directory but I have not confirmed this with group-search-filter in Spring Security, yet. I hope this helps.