IIS WMI Provider
Any script or code that attempts to manage IIS using Windows Management Instrumentation (WMI) needs to access the IIS WMI provider objects. For example, if you want to change a Web site property in the metabase, you must instantiate the class called IIsWebServerSetting which is a child of the CIM_Setting class. For code examples that configure IIS using the IIS WMI provider, see Using WMI to Configure IIS.
The required files, Iiswmi.mof, Iiswmi.mfl, and Iiswmi.dll, come installed with IIS. Because WMI uses late binding, these files don't have to be on a remote computer that attempts to configure an IIS server. From a C++ application, you only need to include the Wbemcli.h file.
There has been a change in the IIS WMI provider for Windows Server 2003 Service Pack 1 and Windows XP with Service Pack 2 that requires customers to update WMI-based scripts that operate over a remote connection. WMI-based scripts that do not encrypt the connection when administering IIS remotely fail with an Access Denied error (WBEM_E_ACCESS_DENIED, 0x80041003). You must use the AuthenticationLevel property.
For information about how to configure encryption in WMI-based scripts, see Encrypting Data When Running WMI-Based Remote Administration Scripts in the IIS Administration Guide.
This section contains information about the classes that are implemented by the IIS WMI provider in the MicrosoftIISv2 namespace. For a list of commonly used Windows WMI properties and methods, see Inherited WMI Properties and Methods.
The following Windows WMI classes are implemented in the MicrosoftIISv2 namespace but are already documented in the Windows Management Instrumentation Platform SDK.
Windows WMI Class
This class takes advantage of the way classes in WMI automatically inherit characteristics from WMI regular classes to pass characteristics on to child classes. Use the child IIsComputer (WMI) class for its useful methods.
This is an association class that maps each element in the CIM_ManagedSystemElement class to another element in the CIM_ManagedSystemElement class so the elements can mimic Active Directory® Service Interfaces (ADSI) containment.
This class carries inherited properties from the parent class through to the child classes.
An abstract class that contains the CIM_LogicalElement (WMI) class.
In the IIS WMI provider, the CIM_LogicalElement (WMI) class contains elements that correspond to nodes of the IIS Metabase Schema. Each element contains read-only properties that relate to IIS metabase properties, and methods that work on the writable properties in the corresponding CIM_Setting class.
This class and the child classes Win32_BaseService (WMI) and Win32_Service (WMI) take advantage of the way classes in WMI automatically inherit characteristics from WMI regular classes to pass on to child classes. Use the child classes IIsNntpService (WMI), IIsPop3Service (WMI), IIsImapService (WMI), IIsSmtpService (WMI), IIsFtpService (WMI), and IIsWebService (WMI), to configure IIS services.
An abstract class that contains the IIsSetting class.
The IisSetting class contains elements that correspond to nodes of the IIS Metabase Schema. Each element contains writable properties that relate to IIS metabase properties.
This class and the child CIM_ApplicationSystem (WMI) class take advantage of the way classes in WMI automatically inherit characteristics from WMI regular classes to pass on to child classes. Use the child IIsComputer (WMI) class to manage the backup files of the IIS metabase.
This class and the child Win32_Service (WMI) class take advantage of the way classes in WMI automatically inherit characteristics from WMI regular classes to pass on characteristics to child classes.
The Win32_Service (WMI) WMI class represents services on a Windows operating system.