Solved

AfterReceiveRequest in WCF giving encrypted request data

Posted on 2009-03-31
4
886 Views
Last Modified: 2012-05-06
i am trying to something similer to
http://weblogs.asp.net/paolopia/archive/2007/08/23/writing-a-wcf-message-inspector.aspx
when I receive a request from wcf client i need to capture it before invoking the actual operation at the serverside.
i am successful in receiving it, but i am getting the data encripted.
how can i get the request details unencrypted at that stage?
Here is the method i am talking about...
1  public object AfterReceiveRequest(ref Message request, IClientChannel channel, InstanceContext instanceContext)
2   {
3        MessageBuffer buffer = request.CreateBufferedCopy(Int32.MaxValue);
4        request = buffer.CreateMessage();
5        Console.WriteLine("Received:\n{0}", buffer.CreateMessage().ToString());
6        return null;
7    }

Please help, Thanks in advance.
0
Comment
Question by:x1877
  • 2
4 Comments
 
LVL 9

Expert Comment

by:ripahoratiu
ID: 24058353
It is supposed that the Messages Inspectors methods are called before encryption/after decryption so that's pretty weird.
What kind of encryption do you use?
0
 

Author Comment

by:x1877
ID: 24058396
i am not using any encryption of my own. just using WSHttpBinding.
0
 
LVL 9

Accepted Solution

by:
ripahoratiu earned 500 total points
ID: 24059151
Set the security of WSHttpBinding to Transport or none. WSHttpBinding is secured at Message level, by default.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
System.net.Sockets Error 5 26
Please explain purpose of GZIP 4 34
SSRS Deployment problem 5 64
Install IIS7.5 on Windows Sever 2012 R2 4 23
This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question