Clientaccesspolicy.xml File Garbled When Accessed from Silverlight App
I'm stumped. I have created a WCF service for serving up Telerik reports
to a Silverlight 4 application (actually a VS LightSwitch 2010 app). The
service is on a different subdomain (let's call it reports.mydomain.com)
from the Silverlight application (say app.mydomain.com) so I have placed a
clientaccesspolicy.xml file in the root of the IIS7.5-hosted service site
that looks like this:
<?xml version="1.0" encoding="utf-8" ?>
<access-policy>
<cross-domain-access>
<policy>
<allow-from http-request-headers="*" http-methods="*">
<domain uri="http://app.mydomain.com">
</domain>
</allow-from>
<grant-to>
<resource path="/">
</resource>
</grant-to>
</policy>
</cross-domain-access>
</access-policy>
When I browse to the clientaccesspolicy.xml file in Firefox, I see the XML
just fine. However, when my Telerik Silverlight report viewer control
attempts to access it (I'm verifying this with FireBug), the response it
gets is garbled.
Here's the Firebug output:
And here:
I tried turning off compression in IIS for the WCF site but this had no
effect. Still garbled.
Finally, here's the XML file when accessed in the browser:
Any ideas?
No comments:
Post a Comment