Name Resolution Configuration and Installation

In order for a name space provider to be accessible via Windows Sockets it must be properly installed on the system and registered with Windows Sockets. When a name space provider is installed by invoking a vendor's installation program, configuration information must be added to a configuration database to give the WS2_32.DLL required information regarding the service provider. The WS2_32.DLL exports an installation function, WSCInstallNameSpace, for the vendor's installation program to use in supplying the relevant information about the to-be-installed service provider. This includes the following:

Symmetrically, the WS2_32.DLL also provides a function, WSCUnInstallNameSpace, for a vendor's deinstallation program to remove all the relevant information from the configuration database. The exact location and format of this configuration information is private to the WS2_32.DLL, and can only be manipulated by the above-mentioned functions.

At any point in time a name space provider is considered to be either active or inactive, with this setting controlled via the WSCEnableNSProvider function. Name space providers that are inactive continue to show up when enumerated via WSAEnumNameSpaceProviders, but the WS2_32.DLL will not route any query or service registration operations to these providers. This capability can be useful in situations where more than one of the installed name space providers can support a given name space.

When multiple name space providers are referenced in a single API function, the order in which the order in which the queries and registration operations are routed to name space providers is unspecified. The order is unrelated to the order in which name space providers are installed. There are two ways to control which name space providers are used to resolve a name query. First, the name space configuration function, WSCEnableNSProvider can be used to enable and disable name spaces in a machine-wide, persistent way. Second, applications can direct an individual query to a particular provider by specifying that provider's identifying GUID as part of the query.