Sometime we face issues while accessing .SWF/Flash files from remote domains. Sometime you will see few blogs asking us to change the browser settings. But there is a workaround provided in Flex, There is ae Security class object which lets you specify how content in different domains can communicate with each other.
There are two main methods which we can use for this purpose.
NOTE: Use allowInsecureDomain() only to enable scripting from non-HTTPS files to HTTPS files.
Second alternative is to use Cross-domain.xml
Crossdomain basically allows you to connect between servers (i.e. load in external files from external URLs/domains) pretty handy when you need information sitting on external servers.
<allow-access-from domain=”*” to-ports=”507″ />
<allow-access-from domain=”*.foo.com” to-ports=”507,516″ />
<allow-access-from domain=”*.bar.com” to-ports=”516-523″ />
<allow-access-from domain=”www.foo.com” to-ports=”507,516-523″ />
<allow-access-from domain=”www.bar.com” to-ports=”*” />
If you are hosting you application on Tomcat, put the crossdomain.xml in root application folder.