MessageSecurityOverHttp.ClientCredentialType 属性

定义

指定在 wsHttpBinding 或 wsDualHttpBinding 绑定中用于客户端身份验证的客户端凭据的类型。

public:
 property System::ServiceModel::MessageCredentialType ClientCredentialType { System::ServiceModel::MessageCredentialType get(); void set(System::ServiceModel::MessageCredentialType value); };
public System.ServiceModel.MessageCredentialType ClientCredentialType { get; set; }
member this.ClientCredentialType : System.ServiceModel.MessageCredentialType with get, set
Public Property ClientCredentialType As MessageCredentialType

属性值

MessageCredentialType

MessageCredentialType。 默认值为 Windows

例外

示例

下面的代码设置此属性。

WSHttpBinding myBinding = new WSHttpBinding();
myBinding.Security.Mode = SecurityMode.Message;
myBinding.Security.Message.ClientCredentialType =
    MessageCredentialType.Windows;

注解

此属性可用来设置用于验证服务调用方的 MessageCredentialType。 有效类型包括:

适用于