Are you setting the SecurityDomain parameter in loadStyleDeclarations?

On 1/19/12 8:06 PM, "flexwdw" <flex...@yahoo.com> wrote:






So, I have a situation where my app swf is separate from my stylesheet swf.  I 
use styleManager.loadStyleDeclartions to do this.

In some situations we have, my app swf actually lives on a different domain 
than my stylesheet swf.  We have a crossdomain file setup on both domains for 
this, and it has worked for a long time.

Suddenly today, this stopped working.  I currently do not believe there was a 
change that caused this to happen.  I have verified that the crossdomain.xml 
file is correct and accessible from the root of both domains.  Everything looks 
fine.

The behavior I see in my sniffer:
1) Application SWF comes across
2) Stylesheet SWF comes across

The Flex log gives me a:

*** Security Sandbox Violation ***
SecurityDomain '<app.swf>' tried to access incompatible context 
'<stylesheet.swf>'
Platform: Failed to load stylesheet: SWF is not a loadable module
Platform: Failed to load stylesheet: Unable to load style(SWF is not a loadable 
module): <stylesheet.swf>.
Warning: Failed to parse corrupt data.

I hacked my setup so that I could load the stylesheet swf from the same domain 
and it works - so I do not believe that the stylesheet is corrupt at all, in 
fact I'm sure of it.

The weird part:  I never see (cache cleared) a request for crossdomain.xml.  I 
can't think of a scenario where it wouldn't try to get the crossdomain.xml file 
-- it is especially confusing that we don't try to get the crossdomain.xml, we 
get a sandbox error, and the stylesheet SWF still comes across the wire!

Any clue on what I should look for here?  I'm officially stumped.  This is a 
flex 3.5 environment.

thanks.






--
Alex Harui
Flex SDK Team
Adobe Systems, Inc.
http://blogs.adobe.com/aharui

Reply via email to