BasicHttpSecurityMode 枚举


指定可与系统提供的 BasicHttpBinding 一起使用的安全类型。Specifies the types of security that can be used with the system-provided BasicHttpBinding.

public enum class BasicHttpSecurityMode
public enum BasicHttpSecurityMode
type BasicHttpSecurityMode = 
Public Enum BasicHttpSecurityMode


Message 2

安全性是通过使用 SOAP 消息安全性来提供的。Security is provided using SOAP message security. 对于 BasicHttpBinding,系统要求向客户端单独提供服务器证书。For the BasicHttpBinding, the system requires that the server certificate be provided to the client separately. 此绑定的有效客户端凭据类型为 UserNameCertificateThe valid client credential types for this binding are UserName and Certificate.

None 0

SOAP 消息在传输过程中并不安全。The SOAP message is not secured during transfer. 这是默认行为。This is the default behavior.

Transport 1

使用 HTTPS 提供安全性。Security is provided using HTTPS. 此服务必须使用 SSL 证书进行配置。The service must be configured with SSL certificates. SOAP 消息是用 HTTPS 作为一个整体进行保护的。The SOAP message is protected as a whole using HTTPS. 客户端使用服务的 SSL 证书对服务进行身份验证。The service is authenticated by the client using the service's SSL certificate. 通过 ClientCredentialType 可对客户端身份验证进行控制。The client authentication is controlled through the ClientCredentialType.

TransportCredentialOnly 4

此方法不提供消息完整性和机密性。This mode does not provide message integrity and confidentiality. 而是仅提供基于 HTTP 的客户端身份验证。It provides only HTTP-based client authentication. 使用此模式时一定要小心。Use this mode with caution. 在通过其他方式(如 IPSec)提供传输安全并且 Windows Communication Foundation (WCF) 基础结构只提供客户端身份验证的环境中,应该使用此模式。It should be used in environments where the transfer security is being provided by other means (such as IPSec) and only client authentication is provided by the Windows Communication Foundation (WCF) infrastructure.

TransportWithMessageCredential 3

完整性、保密性和服务器身份验证均由 HTTPS 提供。Integrity, confidentiality and server authentication are provided by HTTPS. 此服务必须使用证书进行配置。The service must be configured with a certificate. 客户端身份验证采用 SOAP 消息安全方式提供。Client authentication is provided by means of SOAP message security. 如果要使用用户名或证书凭据对用户进行身份验证,并且存在用于保护消息传输的现有 HTTPS 部署,则适用此模式。This mode is applicable when the user is authenticating with a UserName or Certificate credential and there is an existing HTTPS deployment for securing message transfer.


此上下文的安全性即为消息保护(完整性和保密性),以及客户端和服务身份验证。Security in this context means message protection (integrity and confidentiality) as well as client and service authentication.

可通过服务协定的特性或协定说明的属性控制实际的保护要求(SOAP 消息的特定部分必须经过签名或签名与加密)。Actual protection requirements (the specific parts of SOAP messages that must be signed or signed and encrypted) are controlled through attributes on the service contract or through properties in the contract description. 绑定的属性不控制签名或加密的内容:绑定仅提供前面和加密的一般功能。Properties on the binding do not control what is being signed or encrypted: a binding only delivers the general capability of signing and encrypting.

BasicHttpBinding 的默认行为是 None。The default behavior for the BasicHttpBinding is None.