How do I restrict the WCF service called by an ASP.NET AJAX page to only allow calls for that page?

Posted by NovaJoe on Stack Overflow See other posts from Stack Overflow or by NovaJoe
Published on 2010-03-14T20:58:13Z Indexed on 2010/03/14 21:05 UTC
Read the original article Hit count: 223

Filed under:
|
|

I have an AjaxControlToolkit DynamicPopulate control that is updated by calls to a WCF service. I know I can check the HttpContext in the service request to see if a user of the page (and thus, the control) is authenticated. However, I don't want anyone clever to be able to call the service directly, even if they're logged in. I want access to the service to be allowed ONLY to requests that are made from the page. Mainly, I don't want anyone to be able to programatically make a large number of calls and then reverse-engineer the algorithm that sits behind the service.

Any clever ideas on how this can be done? Maybe I'm over-thinking this?

Thanks in advance.

© Stack Overflow or respective owner

Related posts about ASP.NET

Related posts about wcf