通过 LDAP 中的容器检索对象
有谁知道是否可以在 LDAP 查询中根据对象所在的容器来过滤对象?
例如,我想返回 OU 中名为 Staff 的所有用户,也许是这样的:
(& (objectCategory=user) (containerOU=Staff))
显然我只是编造了 containerOU 位,我只是想说明我的意思。
目前,我能做到这一点的唯一方法是带回整个 Staff OU 并迭代它。我是一个 SQL 人,我习惯于能够准确地指定我想要的内容。
谢谢
大卫
Does anyone know if it is possible in an LDAP query to filter objects according to the container they are in?
For example, I would like to return all users in the OU called staff, maybe something like this:
(& (objectCategory=user) (containerOU=Staff))
Obviously I just made up the containerOU bit, I'm just trying to illustrate what I mean.
At the moment, the only way I could do this is the bring back the entire Staff OU and iterate through it. I'm a SQL man, I'm used to being able to specify exactly what I want.
Thanks
David
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以通过对象的distinguishedName 进行搜索。
(distinguishedName=*OU=Staff, DC = blabla, DC = com)
You could search by the objects distinguishedName.
(distinguishedName=*OU=Staff, DC = blabla, DC = com)