Upravit

Sdílet prostřednictvím


__Win32Provider class

The __Win32Provider system class registers information about the physical implementation of a provider in WMI. Providers that do not set the HostingModel property are loaded, by default, to run in a Wmiprvse.exe process as NetworkServiceHostOrSelfHost.

The following syntax is simplified from Managed Object Format (MOF) code and includes all inherited properties. Properties are listed in alphabetic order, not MOF order.

Syntax

class __Win32Provider : __Provider
{
  string   ClientLoadableCLSID;
  string   CLSID;
  sint32   Concurrency;
  string   DefaultMachineName;
  boolean  Enabled;
  string   HostingModel;
  sint32   ImpersonationLevel = 0;
  sint32   InitializationReentrancy;
  datetime InitializationTimeoutInterval;
  boolean  InitializeAsAdminFirst;
  string   Name;
  datetime OperationTimeoutInterval;
  boolean  PerLocaleInitialization = FALSE;
  boolean  PerUserInitialization = FALSE;
  boolean  Pure = TRUE;
  string   SecurityDescriptor;
  boolean  SupportsExplicitShutdown;
  boolean  SupportsExtendedStatus;
  boolean  SupportsQuotas;
  boolean  SupportsSendStatus;
  boolean  SupportsShutdown;
  boolean  SupportsThrottling;
  datetime UnloadTimeout;
  uint32   Version;
};

Members

The __Win32Provider class has these types of members:

Properties

The __Win32Provider class has these properties.

ClientLoadableCLSID

Data type: string

Access type: Read/write

Class identifier that WMI uses to determine whether or not to load a high performance provider into the client process or the WMI process. If both the provider and client are located on the same computer, WMI loads the provider in-process to the client by using ClientLoadableCLSID as the class identifier. When the provider and client are located on different computers, WMI loads the provider in-process to WMI. WMI also uses ClientLoadableCLSID to support refresh operations.

For more information, see Registering a High-Performance Provider.

CLSID

Data type: string

Access type: Read/write

GUID that represents the class identifier (CLSID) of the provider COM object. This COM object must contain an implementation of the IWbemProviderInit interface.

Concurrency

Data type: sint32

Access type: Read/write

Not used.

DefaultMachineName

Data type: string

Access type: Read/write

Identifies the computer on which to start the provider. If the provider runs on the local computer it is NULL.

Enabled

Data type: boolean

Access type: Read/write

If TRUE, this instance is enabled and can be used to complete client requests.

HostingModel

Data type: string

Access type: Read/write

This property is composed of values from the MSFT_Providers HostingGroup and HostingSpecification properties. The value of this property specifies how WMI loads the provider and the security account it runs under. For more information about setting the HostingModel property, see Provider Hosting and Security and Registering a Provider.

ImpersonationLevel

Data type: sint32

Access type: Read/write

Reserved. The default value is zero (0).

InitializationReentrancy

Data type: sint32

Access type: Read/write

Set of flags that provide information about serialization. The default value is zero (0).

0

All initialization of this provider must be serialized.

1

All initializations of this provider in the same namespace must be serialized.

2

No initialization serialization is necessary.

InitializationTimeoutInterval

Data type: datetime

Access type: Read/write

Not used.

InitializeAsAdminFirst

Data type: boolean

Access type: Read/write

TBD

Name

Data type: string

Access type: Read/write

Qualifiers: Key

The provider name.

OperationTimeoutInterval

Data type: datetime

Access type: Read/write

Not used.

PerLocaleInitialization

Data type: boolean

Access type: Read/write

If TRUE, the provider is initialized for each locale when a user connects to the same namespace more than one time using different locales. The default value is FALSE.

PerUserInitialization

Data type: boolean

Access type: Read/write

If TRUE, the provider is initialized one time for each NT LAN Manager (NTLM) user that makes requests to the provider. If FALSE (default), the provider is initialized one time for all users.

Pure

Data type: boolean

Access type: Read/write

If TRUE, the provider agrees to prepare to unload by calling IUnknown::Release on all outstanding interface points when WMI calls the Release method of its primary interface. Providers that must remain clients of WMI after they do not function as providers should set Pure to FALSE. The default setting is TRUE. For more information, see the Remarks section of this topic.

SecurityDescriptor

Data type: string

Access type: Read/write

Security descriptor (SD) in the Security Descriptor Definition Language (SDDL) that determines the set of users that can successfully call IWbemDecoupledRegistrar:Register for the decoupled provider. For more information, see the Security Descriptor Definition Language topic in the Security section of the Windows SDK. This security descriptor is used only for decoupled providers, and does not affect other providers. For more information, see Incorporating a Provider in an Application.

WMI performs access checks for decoupled providers that use the IWbemProviderInit and IWbemObjectSink interfaces. If the security descriptor is NULL, then only applications or services that run under the LocalSystem, NetworkService, LocalService accounts can run a decoupled provider.

The following string shows a decoupled provider to be run only by built-in Administrators."O:BAG:BAD:(A;;0x1;;;BA)"

For more information about setting the SecurityDescriptor property, see Maintaining WMI Security.

SupportsExplicitShutdown

Data type: boolean

Access type: Read/write

Not used.

SupportsExtendedStatus

Data type: boolean

Access type: Read/write

Not used.

SupportsQuotas

Data type: boolean

Access type: Read/write

Not used.

SupportsSendStatus

Data type: boolean

Access type: Read/write

Not used.

SupportsShutdown

Data type: boolean

Access type: Read/write

Not used.

SupportsThrottling

Data type: boolean

Access type: Read/write

Not used.

UnloadTimeout

Data type: datetime

Access type: Read/write

Date and Time Format that specifies how long WMI allows the provider to remain idle before it is unloaded. Typically, providers request that WMI wait no longer than five minutes.

For the current version of WMI, the value of this property is ignored. WMI unloads the provider based on the time-out value in an internal class in the \root namespace. It is recommended that providers set UnloadTimeout. For more information, see Unloading a Provider.

Version

Data type: uint32

Access type: Read/write

Version of the provider. The supported versions are 1 and 2. Version 2 strengthens validity checks for all associated property registrations, specifically the ImpersonationLevel property.

Remarks

The __Win32Provider class is derived from __Provider.

Most providers can accept the default values for the InitializationReentrancy property. However, if a provider can support simultaneous initialization for separate users, this property can be set to 1 (one). If serialized initialization is necessary, InitializationReentrancy remains 0 (zero). In both instances, PerUserInitialization is set to TRUE.

A pure provider or a provider that sets the Pure property to TRUE, exists only to service requests from applications and WMI. Most providers are pure providers. A nonpure provider is the exception. Nonpure providers transition to the role of client after they complete servicing requests.

An example of a nonpure provider is a push provider that starts to issue queries, and makes requests of WMI after it completes initialization. A push provider does not have responsibilities except to update the CIM repository with data at initialization time. After updating the repository, a push provider can wait to be unloaded, or transition to the role of client. The push provider that waits to be unloaded is a pure provider. The push provider that participates in client activities is nonpure.

WMI must be able to distinguish pure providers from non-pure providers so that it can determine when it is safe to shut down. WMI must wait for all operations that involve non-pure providers to complete before it can shut down safely.

Requirements

Requirement Value
Minimum supported client
Windows Vista
Minimum supported server
Windows Server 2008
Namespace
All WMI namespaces

See also

__Provider

WMI System Classes

Registering a Provider