Theater SDK Banner 

Art
[Previous][Next]

INSSAuthenticator::GetAuthenticationType

Called to retrieve the type of authentication.

Syntax

HRESULT GetAuthenticationType(
LPBSTR bstrAuthenType
);

Parameters

[out] bstrAuthenType

Specifies the authentication type. Following is a list of authentication types currently supported by the server and Microsoft® Windows® Media Player.

Type Description
Basic HTTP-BASIC authentication
NTLM NT LAN Manager authentication

Return Values

This method must return S_OK upon successful completion, or an HRESULT error code.

Remarks

The dwFlags parameter in INSSAuthenticator::Initialize must be NS_TEXT_WIRE_PROTOCOL when the authentication type is set to “Basic”. The dwFlags parameter cannot be NS_TEXT_WIRE_PROTOCOL if the authentication type is “NTLM”.

Use the automation allocation function SysAllocString to allocate memory for the string.

The following sample code demonstrates a skeletal implementation of this method:

HRESULT CSampleAuthenticator::GetAuthenticationType(
                 BSTR * pbstrAuthenType )
{
  *pbstrAuthenType = SysAllocString( A2W ( "Basic" ) ); 
  if( NULL == *pbstrAuthenType )
  {
    return( E_OUTOFMEMORY );
  }
  return( S_OK );
}

See Also

INSSAuthenticator::GetAuthenticatorClass

[Previous][Next]



© 1996-1998 Microsoft Corporation. All rights reserved