SecurityError: Error #2048: Security sandbox violation:

4549
8
10-06-2010 06:59 AM
RobertoFigueroa
New Contributor III
Hi all,

I am trying to publish a FlexViewer 2.1 in from my local machine. I am using IIS 5.0. I have placed the crossdomain.xml under my web root (C:\Inetpub\wwwroot). The crossdomain.xml file includes the following:

<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
    <site-control permitted-cross-domain-policies="all"/>
    <allow-access-from domain="*"/>
</cross-domain-policy>

However, I am still getting the following error when trying to launch the viewer in IE:

SecurityError: Error #2048: Security sandbox violation: http://163.155.89.150/flexviewer/index.swf cannot load data from http://devn19/ArcGIS/rest/services/emili_ho_dev/MapServer?f=json.
at MethodInfo-4395()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncToken/http://www.adobe.com/2006/flex/mx/internal::applyFault()
at mx.rpc.events::FaultEvent/http://www.adobe.com/2006/flex/mx/internal::callTokenResponders()
at HTTPOperation/http://www.adobe.com/2006/flex/mx/internal::dispatchRpcEvent()
at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()
at mx.rpc::Responder/fault()
at mx.rpc::AsyncRequest/fault()
at DirectHTTPMessageResponder/securityErrorHandler()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/redirectEvent()

I have Adobe Flash Player 10 installed.....

Any idea on what is the problem? Any help would be greatly appreciated.

Thanks

Roberto
Tags (2)
0 Kudos
8 Replies
RobertScheitlin__GISP
MVP Emeritus
Roberto,

   You need to use either the computer name or the IP and not both. It sees http://163.155.89.150 and http://devn19 as different machines.
0 Kudos
RobertoFigueroa
New Contributor III
Roberto,

   You need to use either the computer name or the IP and not both. It sees http://163.155.89.150 and http://devn19 as different machines.



They are indeed different machines: "163.155.89.150" is my local PC which is hosting the ArcGIS Flex Viewer and "devn19" is a corporate server where we have some published ArcGIS Server map services.
0 Kudos
RobertScheitlin__GISP
MVP Emeritus
Roberto,

  OK in that case than the crossdomain.xml needs to be on the ArcGIS Server machine than in it's wwwroot directory.
0 Kudos
RobertoFigueroa
New Contributor III
Roberto,

  OK in that case than the crossdomain.xml needs to be on the ArcGIS Server machine than in it's wwwroot directory.


Robert,
I copied the crossdomain.xml file to the webroot directory in devn19 and now everything works!!!!
Thank you very much for your help.
Regards
Roberto
0 Kudos
NadeemShaukat
New Contributor II
Robert,
I copied the crossdomain.xml file to the webroot directory in devn19 and now everything works!!!!
Thank you very much for your help.
Regards
Roberto


Roberto,

I am having the same error #2048 even after I have placed the crossdomain.xml file on the server's C:\inetpub\wwwroot folder. Can you help me?

Following are the contents of the Crossdomain.xml

<?xml version="1.0" ?>   <cross-domain-policy>
  <allow-access-from domain="*" />
  <site-control permitted-cross-domain-policies="all" />
  <allow-http-request-headers-from domain="*" headers="*" />
  </cross-domain-policy>
0 Kudos
DasaPaddock
Esri Regular Contributor
Can you try a tool like HttpFox to make sure that it's successfully accessing your crossdomain.xml file?
0 Kudos
JamesOBrien
New Contributor
You probably haven't enabled directory browsing to make the file accessible.

Here is a blog post which describes error 2048 in detail:

http://geophyter.blogspot.com/2010/11/flex-sandbox-security-error-2048.html
0 Kudos
RaufAhmad
New Contributor
I am having the same kind of issue with my Flex application. I tried the crossdomain.xml with the same settings as you had mentioned. But no luck. It still results in Error#2048 Sandbox security errors. also when I access the file from browser it return the cross domain file eg. http://www.yourwebsite.com/crossdomain.xml
please reply with any suggestion because my whole project getting late due to this issue.

thanks
0 Kudos