开发者

Query roles on a Windows machine using LDAP

Anyone know how I can write an LDAP query to determine what roles exist on a Windows machine (which may or may not be on a domain)? I would like to do this in Ruby, although if it's only possible to do in .开发者_如何转开发NET, that is a possibility.


You can't use LDAP to query a local machine. You use LDAP for querying a directory on a (in the case of Windows) Active Directory Domain Controller. I think you're probably getting your terms a bit muddled. The most common way of querying AD from Windows goes via ADSI. You can also use ADSI to query the local security database. When using ADSI to query AD, you use the LDAP:// moniker. If you want to run a query against the local security system, use the WinNT:// provider. I haven't done this in ages but, from memory, the capitalization is significant.

I don't know ruby but perhaps this will help you search.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜