- Posted by christhi on October 24, 2008
Follow me on Twitter and get UX Tips O the day e.g. Blend Debugging Tips, Blend Tricks, SilverLight Dos/Dont's. http://www.twitter.com/uxarchitect
UX Tip O the Day: SilverLight Cross Domain Policy File Format
If your services site (WCF, ASMX) is not in the same domain as your SL application or you are calling an external site from SL such as an RSS Reader would do you will need a cross domain policy file. Here is an example (SL 2.0 final). This can be narrowed down of course. The reason this is "a tip" is because you may be trying to call an RSS feed and getting a security exception for some sites but not others. Rememeber SL supports the Flash domain file format as well so sites like reuters RSS may already have a Flash domain file. If you don't control the site and can't access the RSS feed stayed tuned and I'll show you how to get around this limitation.
<?xml version="1.0" encoding="utf-8"?>
<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>