TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Renjith Kumaran
NA
18
3.3k
Soap Message Signing
Aug 2 2017 3:14 AM
Hi All
Good Day!
I am working on sending one soap request to a server. I have added the service reference of the WSDL provided. I have to make client authentication and message signing before the message send to the server. I have done the client authentication, kindly help me to provide how the message signing can be done while passing an object to the wsdl generated class.
ServiceReference1.Purchaseclass proxy = new ServiceReference1.Purchaseclass();
ServiceReference1.getSuppliersRequest obj = new ServiceReference1.getSuppliersRequest();
obj.companyId = "345";
ServiceReference1.getSuppliersResponse response = new ServiceReference1.getSuppliersResponse();
ServicePointManager.Expect100Continue = true;
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls; proxy.ClientCredentials.ClientCertificate.SetCertificate(StoreLocation.LocalMachine, StoreName.My, X509FindType.FindBySubjectDistinguishedName, "test.mshq-client");
((BasicHttpBinding)proxy.Endpoint.Binding).Security.Mode = BasicHttpSecurityMode.Transport;
((BasicHttpBinding)proxy.Endpoint.Binding).Security.Transport.ClientCredentialType = HttpClientCredentialType.Certificate;
// Then i have to make the message sign before calling the request to the API
response = proxy.GetSuppliers(obj);
Reply
Answers (
2
)
Working with a byte array in WCF service
how to use Facebook authentication in wcf service?