Click here to Skip to main content
11,633,969 members (75,934 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: Windows WCF ASP.NET4.0
Hi Friends,

I need to access a WCF Service from windows application and web appication.
In application i need access WCF Service from JQuery. But it will leads security leak(All user can see javascript files form that they can view Service url and parameter type passed etc) How to over come this?
Posted 5-Nov-12 19:15pm

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

You'll have to call a different service that then calls the service you are trying to hide. You're right, they can see the JS. You can minify it or even obfuscate the JS which makes it much harder to find the information you are trying to hide.
Marcus Kramer at 8-Nov-12 15:37pm
+5. Good answer.
HarisJayadev at 8-Nov-12 23:03pm
Even after minifing or obfuscating i found service url and etc.. Can u give me any other solutions?
ryanb31 at 9-Nov-12 8:04am
I don't know of any. If you want the code to execute from the client side, as in JavaScript, it has to be on the client. There is no way around that unless you use something that is compiled, like an ActiveX control but then you'll have major issues getting it to work in browsers. Can you use a button and do a full postback and do it from server side code?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 8,658
1 Sergey Alexandrovich Kryukov 8,204
2 Mika Wendelius 6,645
3 F-ES Sitecore 2,321
4 Suvendu Shekhar Giri 2,095

Advertise | Privacy | Mobile
Web04 | 2.8.150728.1 | Last Updated 8 Nov 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100