ADSI, using ASP for NT management

Source: Internet
Author: User
Tags domain server
Last time I spoke about how to use ADSI to manage web servers. This time I discussed how ADSI manages NT.
To use ADSI to manage IIS, OP4 is required.
NTLM is required for nt adsi management.
NTLM provides the following objects: Domain, Group, and User.
You can add groups and users through the domain object.
In the following example, the NT access permission database is changed; the permissions of the NT user are randomly added and changed.
Please read carefully before use. Please run these programs only on the tested machine, only to your understanding of NTLM
So far. Do not endanger the security of the real host.
Only persons with Administrator or Operator permissions can run IIS on the machine.
Change the user database of NT. Therefore, you are not authorized to log on with the Anonymous permission.
Of course, SSL can also ensure security.
Create a user:
You can add users on an independent server or a primary domain server.
On Error Resume Next
StrUser = "jdoe"
Set oDomain = GetObject ("WinNT: //" & strDomain)
Set oUser = oDomain. Create ("user", strUser)
If (err. number = 0) Then
OUser. SetInfo
OUser. SetPassword "mypassword"
OUser. SetInfo
Set oUser = Nothing
End If
Set oDomain = Nothing
Add a new group:
StrGroup = "Unidentified"
Set oDomain = GetObject ("WinNT: //" & strDomain)
Set oGroup = oDomain. Create ("group", strGroup)
OGroup. SetInfo
Set oDomain = Nothing
Set oGroup = Nothing
Add a user to a group.
Related Article

E-Commerce Solutions

Leverage the same tools powering the Alibaba Ecosystem

Learn more >

Apsara Conference 2019

The Rise of Data Intelligence, September 25th - 27th, Hangzhou, China

Learn more >

Alibaba Cloud Free Trial

Learn and experience the power of Alibaba Cloud with a free trial worth $300-1200 USD

Learn more >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.