NetMsmqSecurityMode 枚举   
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
NetMsmqSecurityMode 枚举指定可供 MSMQ 传输使用的安全模式。
public enum class NetMsmqSecurityMode
	public enum NetMsmqSecurityMode
	type NetMsmqSecurityMode = 
	Public Enum NetMsmqSecurityMode
		- 继承
 
字段
| 名称 | 值 | 说明 | 
|---|---|---|
| Both | 3 | 同时启用 MSMQ 传输安全和 SOAP 安全。  | 
			
| Message | 2 | 启用 SOAP 安全。  | 
			
| None | 0 | 同时禁用 MSMQ 传输安全和 SOAP 安全。  | 
			
| Transport | 1 | 启用 MSMQ 传输安全。  | 
			
示例
下面的代码演示如何指定 NetMsmqBinding 绑定的安全模式。
NetMsmqBinding binding = new NetMsmqBinding();
    NetMsmqSecurity security = binding.Security;
	注解
MSMQ 传输安全使用 MSMQ 保护消息。 SOAP 安全使用 WS-* 安全协议保护消息。 此属性确定获得传输安全功能(如完整性、机密性和身份验证)的机制。