LDAP 中如何识别计算机名称属性? (活动目录)
使用.net,我试图从这个 AD 字段中提取信息:计算机名称(Windows 2000 之前的版本)。但是,我不知道它的属性标识符是什么。
例如,如果您想查找城市属性,请使用“l”。我想知道计算机名称对应的标识符是什么。
dSearch.PropertiesToLoad.Add("l"); //load city property
dSearch.PropertiesToLoad.Add("?"); //what is computer name?
有谁知道这里可以用什么吗?非常感谢您的帮助。
Using .net, I'm trying to pull info from this AD field: Computer Name(pre-Windows 2000). However, I don't know what the property identifier for it is.
For instance, if you want to look for the city property, you use "l". I'm wondering what the corresponding identifier is for computer name.
dSearch.PropertiesToLoad.Add("l"); //load city property
dSearch.PropertiesToLoad.Add("?"); //what is computer name?
Does anyone know what to use here? Help would be much appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
在我们的环境中,这两个都返回计算机名称,但我无法分辨哪个与计算机名称(Windows 2000 之前的版本)相关。
In our environment both of these return the computer name but I can't tell which is tied to Computer Name(pre-Windows 2000).
结果标识符是“employeeID”。
Turns out the identifier was "employeeID".
Windows 2000 之前版本的计算机名称的 AD ldap 属性是“sAMAccountName”。我自己在 AD 上验证了它,方法是创建一个虚假的计算机帐户,为其指定一个唯一的 pre-win 2000 名称,然后使用 LDAP 管理员。
The AD ldap attribute for the pre-Windows 2000 computer name is "sAMAccountName". I verified it myself on AD by creating a bogus computer account, giving it a unique pre-win 2000 name, and then checking the AD attributes using LDAP Admin.