0
votes

I am getting Error "2048" while accessing one of my deployed application of flex which is deployed on apache server.

I am using database which is hosted on other server and my application is on different server.

I have added crossdomain.xml in application's directory eg. apache.../webapps/MyApplication/crossdomain.xml

I can access crossdomain.xml successfully.

2

2 Answers

0
votes

Are you loading the crossdomain.xml file manually by loadPolicyFile() function ?

System.security.loadPolicyFile("http://yourdomain.com/webapps/MyApplication/crossdomain.xml");

or

try moving the crossdomain.xml file to the root of your web server as http://yourdomain.com/crossdomain.xml


Also you can use flashbug extension for firebug to see all the policy violations... its very handy.

Get Flashbug

0
votes

You are on the right way. When you required information from an application on a host, you have, for flash security purpose, to copy the crossdomain.xml file in the root web dir on the server hosting the application.

Now maybe the problem comes from your crossdomain.xml file, try this one :

<?xml version="1.0"?> 
<cross-domain-policy> 
    <allow-http-request-headers-from domain="*" headers="*" secure="false" /> 
    <allow-access-from domain="*" secure="false" /> 
</cross-domain-policy>