Back in 2005 I wrote my first ADSI for plugin WinPE (WinPE 2005 or v1.6), and per request I have since then updated it for every WinPE release… This is the release for WinPE 5.0 (part of ADK 8.1).
Note: I don't recommend using ADSI in WinPE. It's not supported by Microsoft, and this release is only intended to support existing solutions using it. Instead you really should use web services to interact with Active Directory from WinPE. Check out http://prettygoodfrontend.codeplex.com for ready-made web services for Active Directory, including source code.
Update 2014-04-08: You can also import this plugin as a driver to MDT (using Out-Of-Box Drivers), thanks bseifert55 for the tip. So it's automatically being added when updating the boot image.
Detailed installation instructions can be found in the archive Readme.txt file.
Previous ADSI Plugin releases are found on the following links:
WinPE 2.0 ADSI Plugin
WinPE 1.6 ADSI Plugin
Note: If your domain controllers are running Windows Server 2012 or Windows Server 2012 R2, the ADSI connection (which is using NTLM) may be restricted (default configuration). If NTLM is restricted, you get the following error when trying to run the built-in sample script (Connect_to_DC_Sample.vbs): Active Directory: The server is not operational
Workaround: You can relax (and audit) the settings for NTLM, by configuring a group policy that sets the following:
Network security: Restrict NTLM: Outgoing NTLM traffic to remote servers = Audit All
Network security: Restrict NTLM: Audit NTLM authentication in this domain = Enable all
Network security: Restrict NTLM: Audit Incoming NTLM Traffic = Enable auditing for all accounts
In addition to allowing the traffic, you can then see the audit logs in the Event Viewer (Event Viewer (Local)/Applications And Services Logs/Microsoft/Windows/NTLM/Operational)