PDA

View Full Version : Cross Domain Policies for SL2 Client hitting WCF service


TroyWing
05-27-2008, 03:19 AM
Hi All,

Has anyone been successful in using a local host Silverlight 2 component accessing WCF service hosted here in discountasp.?
Works fine from the same domain, but I am getting crossdomain exception errors when trying to call the service from a local (on my dev machine) SL2 client.
I have uploaded a crossdomainpolicy.xml as per below to web app root with no success.

[quote]




<access-policy>
<cross-domain-access>
<policy>
<allow-from>
<domain uri="*"/>
</allow-from>
<grant-to>
<resource path="/" include-subpaths="true"/>
</grant-to>
</policy>
</cross-domain-access>
</access-policy></CODE>

VentureTechie
06-09-2008, 10:45 AM
I think you've got your naming mixed up, what you've got there is a clientaccesspolicy.xml file not a crossdomainpolicy.xml file which would look like:



<!DOCTYPE cross-domain-policy (View Source for full doctype...)>

- (file://toicapp/c$/Inetpub/wwwroot/crossdomain.xml#) <cross-domain-policy>


<allow-http-request-headers-from domain="*" headers="*" secure="true" />
</<cross-domain-policy>

If you rename it to clientaccesspolicy.xml I **think** you should be okay.

HTH

Pete

TroyWing
06-24-2008, 05:13 AM
Thanks Pete,
Its been so long I forgot to check this post.
Anyhow, the filename in my original post was a typo. It is already clientaccesspolicy.xml. I will keep on looking and if I find a solution I will post here.

Troy.

braulio
12-22-2008, 02:02 AM
Any update on this area?


I have been checking with fiddler, the clientaccesspolicy gets downloaded but then I get an error :-(.