本文介绍了发送SOAP消息的WCF客户端,包括用户名令牌和数字签名,但没有加密的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

WCF做我的头,我想要做的就是创建一个WCF客户端会发送包含用户名令牌和证书签署,但不加密的SOAP消息。我发现许多文章和博客与code,几乎做什么,我想,但并不完全,现在我很为难。谁能给我一个的简单的例子,如何做到这一点?

WCF does my head in. What I'm trying to do is create a WCF client that will send SOAP messages that contain a username token and are signed with a certificate, but are not encrypted. I've found many articles and blogs with code which almost does what I want, but not quite, and now I'm stumped. Can anyone give me a simple example of how to do this?

我所做的迄今:

  • 使用SvcUtil工具来生成从WSDL和XSD
  • 系统配置文件和WCF code
  • 从证书存储安装的证书和负载
  • Use svcutil to generate a config file and WCF code from a wsdl and xsd
  • Install certificates and load from the certificate store

我已经尝试了很多不同的东西,有很多不同的错误,想了一个例子是尽可能简单,这样我就可以一)有了解它的一些机会和b)找出我需要改变,使在code的工作。

I've tried many different things and had many different errors and would like a an example which is as simple as possible so I can a) have some chance of understanding it and b) figure out what I need to change to make the code work.

推荐答案

只是一个猜测,但你可以尝试的。我有麻烦,去年试图调用一个SOAP服务使用WCF客户端使用基本身份验证通过HTTP,不能让它的工作。我发现在网上一些文章,但无法得到任何工作。

Just a guess, but you could try TransportCredentialOnly. I had trouble last year trying to call a SOAP service with using a WCF client with basic authentication over http and couldn't get it to work. I found a few articles on line but couldn't get any to work.

这篇关于发送SOAP消息的WCF客户端,包括用户名令牌和数字签名,但没有加密的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-04 09:01