|
|
|
date: Fri, 22 Feb 2008 07:10:52 +0800,
group: microsoft.public.platformsdk.active.directory
back
Re: accessing IIS virtual directories and other directories programmatically
IIS is not part of Active Directory. I think you are confusing the ADSI
provider model with the fact that ADSI is called Active Directory Services
Interface. The name isn't really totally appropriate it. ADSI uses a
provider model to attempt to impose a similar domain model (IADs and its
supporting cast) over the top of different types of stores. The main stores
that are still supported are LDAP (AD, ADAM, etc.), WinNT (the local SAM
account database on any Windows machine) and IIS (over the IIS metabase,
which has had different persistence mechanisms in different versions of
IIS). In all cases, the ADSI provider is attempting to translate the ADSI
domain model to underlying APIs such as LDAP, SAM and ABO (for IIS) and
provide a scriptable way to access those functions that otherwise used to
require C++ code. .NET added an interop layer over ADSI, S.DS, which allows
the same type of access to .NET clients.
So, your IIS settings are stored in the metabase (unless you use IIS 7, in
which case there is a new serialization format based on configuration
files), not in AD. The IIS provider is translating your requests into lower
level calls into ABO that manipulate the metabase.
That said, I think the IISWebDirectory interface is the IIS extension to
ADSI that provides you with what you are looking for. There is a pretty
decent discussion on using ADSI for programmatic administration of IIS in
the IIS SDK docs.
Best of luck!
Joe K.
--
Joe Kaplan-MS MVP Directory Services Programming
Co-author of "The .NET Developer's Guide to Directory Services Programming"
http://www.directoryprogramming.net
--
"Steven" wrote in message
news:ba56c564d2024b2cb0a637344f7f308a@newspe.com...
> Hi all,
>
> I have a need to access the virtual directories and other directories that
> fall under an IIS website and change certain properties using c#. I use
> the
> System.DirectoryServices and can get the root virtual directory using the
> following string "IIS://testServer/W3SVC/1/Root/". I can then loop through
> all virtual directories and application under this web server. What I
> can't
> do is access a subdirectory that has not been designated as either virtual
> directory or an application in IIS.
>
> Now to my question, since I know that IIS is actualy part of active
> directory is there any other way to get to and change the properties of a
> normal directory that is under a virtual directory. I hope I made myself
> clear.
>
> Thanks in advance to all the gurus out there
>
> Steven
>
> url:http://www.ureader.com/gp/1633-1.aspx
date: Fri, 29 Feb 2008 13:57:00 -0600
author: Joe Kaplan
|
|