An ADSI domain explorer. <%@ Language=VBScript %> <HTML> <HEAD> <META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0"> <title>ADSI Domain browser</title> </HEAD> <BODY> <!-- Author: Adrian Forbes -->
<% sDomain = Request("Domain") sComputer = Request("Computer") sGroup = Request("Group") sUser = Request("User")
if len(trim(sUser)) > 0 then Set objGroup = GetObject("WinNT://" & sDomain & "/" & sComputer & "/" & sUser) For Each objUser In objGroup.Groups Response.Write objUser.Name & "<br>" & vbCrLf Next Response.Write "</table><p><a href=adsi.asp?Domain=" & sDomain & "&Computer=" & sComputer & ">Back to " & sComputer & "</a></p>" elseif len(trim(sGroup)) > 0 then Set objGroup = GetObject("WinNT://" & sDomain & "/" & sComputer & "/" & sGroup) For Each objUser In objGroup.Members Response.Write objUser.Name & "<br>" & vbCrLf Next Response.Write "</table><p><a href=adsi.asp?Domain=" & sDomain & "&Computer=" & sComputer & ">Back to " & sComputer & "</a></p>" elseif len(trim(sComputer)) > 0 then Set objComputer = GetObject("WinNT://" & sDomain & "/" & sComputer) Response.Write "<table border=0>" For Each objObject In objComputer if strcomp(objObject.Class, "group", 1) = 0 then Response.Write "<tr><td>" & objObject.Class & "</td><td> <a href=adsi.asp?Domain=" & sDomain & "&Computer=" & sComputer & "&Group=" & objObject.Name & ">" & objObject.Name & "</a></td></tr>" & vbCrLf elseif strcomp(objObject.Class, "user", 1) = 0 then Response.Write "<tr><td>" & objObject.Class & "</td><td> <a href=adsi.asp?Domain=" & sDomain & "&Computer=" & sComputer & "&User=" & objObject.Name & ">" & objObject.Name & "</a></td></tr>" & vbCrLf else Response.Write "<tr><td>" & objObject.Class & "</td><td> " & objObject.Name & "</td></tr>" & vbCrLf end if Next Response.Write "</table><p><a href=adsi.asp?Domain=" & sDomain & ">Back to " & sDomain & "</a></p>" elseif len(trim(sDomain)) > 0 then Set objDomain = GetObject("WinNT://" & sDomain) For Each objComputer In objDomain if strcomp(objComputer.Class, "computer", 1) = 0 then Response.Write "<a href=adsi.asp?domain=" & sDomain & "&computer=" & objComputer.Name & ">" & objComputer.Name & "<br>" end if Next
Response.Write "<p><a href=adsi.asp>Back to domain list</a></p>" else Set objWinNT = GetObject("WinNT:") For Each objDomain In objWinNT if strcomp(objDomain.Class, "domain", 1) = 0 then Response.Write "<a href=adsi.asp?domain=" & objDomain.Name & ">" & objDomain.Name & "<br>" end if Next end if %>
</BODY> </HTML> |
| DISCLAIMER: The content provided in this article is not warranted or guaranteed by Developer Shed, Inc. The content provided is intended for entertainment and/or educational purposes in order to introduce to the reader key ideas, concepts, and/or product reviews. As such it is incumbent upon the reader to employ real-world tactics for security and implementation of best practices. We are not liable for any negative consequences that may result from implementing any information covered in our articles or tutorials. If this is a hardware review, it is not recommended to open and/or modify your hardware. |
More ASP.NET Code Articles More By Adrian Forbes developerWorks - FREE Tools! | Hold your calendar on January 30, 2008 for this free webcast on the new i5/OS. Rational's Enterprise Modernization products will be discussed at this webcast as they help to drive the application development environment for this new System i OS. <br />And learn how i5/OS will take you to the next step of efficient, resilient business processing. You will hear about the new i5/OS capabilities as it will be the most significant i5/OS release in years. If you cannot join the webcast on 1/30/08 you can still use this link to listen to the replay.<br /> FREE! Go There Now!
| | | | Poor Requirements Management capabilities in an Enterprise have been linked to excessive project failures, escalating IT costs, and failure to deliver competitive advantage into the marketplace. Join Brianna M Smith from IBM Rational and learn about how successful organizations align IT and Business stakeholders through collaborative processes and tools for effective requirements management, and how an integrated approach across the IT lifecycle can provide unparalleled visibility and traceability to ensure that project teams are delivering on the business vision by "doing the right things" and "doing things right." FREE! Go There Now!
| | | | Build secure Web services with transport-level security using IBM Rational Application Developer V7 and IBM WebSphere Application Server V6.1. Follow this three-part series for step-by-step instructions about how to develop Web services and clients, configure HTTP basic authentication, and configure HTTP over SSL (HTTPS). This first part of the series walks you through building a Web service for a simple calculator application. You generate and test two different types of Web services clients: a Java Platform, Enterprise Edition (Java EE) client and a stand-alone Java client. You also handle user-defined exceptions in Web services. FREE! Go There Now!
| | | | Learn how you can extend modern application lifecycle management to IBM System z through the IBM Rational Software Delivery Platform (SDP). The Did you say mainframe? e-kit includes podcasts, webcasts, tutorials, white and red papers, demos, and articles designed to help ease the challenges of modernizing your enterprise. This complimentary kit for mainframe developers is a practical, how-to guide for making the most of an existing development environment, including the skills and infrastructure already in place at an established enterprise. FREE! Go There Now!
| | | | Download a free trial version of IBM Rational Software Analyzer Developer Edition V7.0 to identify bug defects earlier in the software development cycle. Rational Software Analyzer is an extensible software development solution that reduces the expense of bug-fixes by enabling static analysis code reviews and bug identification very early in the development cycle. FREE! Go There Now!
| | | | Asset Reuse is a key strategy for companies looking to create innovative solutions to solve complex software development problems. Searching for, identifying, updating, using and deploying software assets can be a difficult challenge. Listen to this webcast, to learn about strategies and tools that you can leverage for a successful project, including Rational Asset Manager, Rational Software Architect and WebSphere Service Registry and Repository. FREE! Go There Now!
| | | | Portfolio Management is about effectively managing portfolio value by aligning portfolio investments with business goals. This complimentary e-kit provides a collection of materials that can help you understand how IBM Rational enables and automates best practices for improved governance and clear visibility into portfolio and project performance across the entire IT project lifecycle. FREE! Go There Now!
| | | | Discover how Rational tools and best practices for testing can make your job easier. The new Rational Testing eKits provide you with valuable resources – including demos, webcasts, tutorials, and articles – that help you address your specific testing needs across the software lifecycle. Five new eKits are available covering the topics of Requirements and Test Management, Functional Testing, Performance Testing, Code Quality and Embedded Systems, and SOA and Web Services Testing. FREE! Go There Now!
| | | | This whitepaper provides areas to consider when evaluating any software configuration management solution. It addresses how the IBM solutions (Rational ClearCase and Rational ClearQuest) meet the needs and requirements of both project leaders and developers to provide successful Software Change and Configuration Management. FREE! Go There Now!
| | | | WebSphere Process Server delivers a unique integration framework that simplifies existing IT resources. Often, as IT assets grow to support business demand, so too does their complexity and manageability. In this webcast, we’ll discuss how WebSphere Process Server helps deliver an SOA infrastructure that provides a common model to orchestrate, mediate, connect, map, and execute the underlying IT functions. Discover how WebSphere Process Server simplifies integration of business processes by leveraging existing IT assets as reusable services without the complexities of traditional integration methodologies. FREE! Go There Now!
| | | | All FREE IBM® developerWorks Tools! | |