本文介绍了LDAP:过滤多个UID的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试为一个团队建立MediaWiki,并且希望LDAP仅对一组用户进行身份验证.我知道我可以提出一个组LDAP身份验证.
I am trying to set up mediawiki for a team and would like to LDAP authenticate only a set of users. I am aware I could come up with a group LDAP authentication.
但是有没有一种捷径可以只过滤一组uid进行身份验证.
But is there a shortcut to filter only a set of uids to authenticate.
推荐答案
您可以使用的LDAP搜索过滤器是:
The LDAP search filter you could use is:
(|(uid=a)(uid=b)(uid=c)(uid=...))
但是,正如评论中所指出的,一个组更容易维护.但是,如果您不能使用组,请考虑使用用户的属性,例如description
,从而导致此过滤器:
But as noted in the comments, a group is much easier and more maintainable.However if you cannot use a group, consider using an attribute of the users, like description
, resulting in this filter:
(description=mediawiki)
这篇关于LDAP:过滤多个UID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!