How to: Set the ProtectionLevel Property
来源:互联网 发布:js工厂方法 编辑:程序博客网 时间:2024/05/01 07:12
http://msdn.microsoft.com/en-us/library/aa347791.aspx
To sign all messages for a service
[ServiceContract(ProtectionLevel = ProtectionLevel.Sign)]public interface ICalculator
To sign all message parts for an operation
// Set the ProtectionLevel on the whole service to Sign.[ServiceContract(ProtectionLevel = ProtectionLevel.Sign)]public interface ICalculator{ // Set the ProtectionLevel on this operation to None. [OperationContract(ProtectionLevel = ProtectionLevel.Sign)] double Add(double a, double b);}
Protecting Fault Messages
public interface ICalculator{ // Set the ProtectionLevel on a FaultContractAttribute. [OperationContract(ProtectionLevel = ProtectionLevel.EncryptAndSign)] [FaultContract( typeof(MathFault), Action = @"http://localhost/Add", Name = "AddFault", Namespace = "http://contoso.com", ProtectionLevel = ProtectionLevel.EncryptAndSign)] double Add(double a, double b);}Protecting Message Parts
[MessageContract(ProtectionLevel = ProtectionLevel.EncryptAndSign)]public class Company{ [MessageHeader(ProtectionLevel = ProtectionLevel.Sign)] public string CompanyName; [MessageBodyMember(ProtectionLevel = ProtectionLevel.EncryptAndSign)] public string CompanyID;}
- How to: Set the ProtectionLevel Property
- How to set preferIPv4Stack property for JNLP app?
- How to set the style in valuelist
- How to set the ListView Rows Height
- PercentRelativeLayout, how to set the height programatically
- Uncaught SyntaxError: Failed to set the 'innerHTML' property on 'Element'
- How to set the Collation properties of the database
- How to set the QT Application icon in the windows.
- The HttpsGetEnabled property of ServiceMetdataBehavior is set to true and the HttpsGetUrl property
- Master Pages / Content Pages. How to set the Form ID?
- How to set bmp for your UserControl in the toolbox
- svn : how to set the executable bit on a file?
- 关于JAVA界面风格(How to Set the Look and Feel)
- How to set the title of UIButton as left alignment?
- The path to the driver executable must be set by the webdriver.gecko.driver system property
- The path to the driver executable must be set by the webdriver.gecko.driver system property
- How to set vim
- How to set a breakpoint on a property within a third-party managed component?
- 跨站请求伪造及防范 Cross-Site Request Forgeries[CSRF]
- CentOS 6 rescue模式 初体验
- java 第3天笔记
- 增加datanode新节点
- 学习Android界面设计的超级利器HierarchyView.bat
- How to: Set the ProtectionLevel Property
- POJ-1040
- Windows Storage Server 2008 R2 下载安装
- Linux下分区详解之--Fdisk
- android UI进阶之弹窗的使用(2)--实现通讯录的弹窗效果
- G-Sockets(IOCP) 2.5 Demo 源码 (VC2008 & Delphi7/2010)下载
- php的set_include_path与get_include_path()的用法
- 线性表基础知识(一)
- 改变WP7程序启动的页面Page.xaml