Security error accessing Service outside of FlexBuilder
Posted
by MikeHoss
on Stack Overflow
See other posts from Stack Overflow
or by MikeHoss
Published on 2010-03-16T18:17:56Z
Indexed on
2010/03/16
18:21 UTC
Read the original article
Hit count: 682
I'm very new to Flex and I have what I think it a head-scratcher.
I am building a little Flash app that will consume some web services over HTTP. When I am in Flexbuilder and run my app there, it works fine. When I goto to my FlexBuilder project on my OS and double-click on it, it works fine. When I zip up my bin-debug file, I get this error:
Security error accessing url faultCode:Channel.Security.Error faultString:
'Security error accessing url' faultDetail:'Destination: DefaultHTTP'
So I googled that and got information on about the crossdomain.xml file. Well, I can't put a crossdomain file in the service I am calling, but I can put one somewhere else. So I put the following lines in Flex app:
Security.allowDomain("vx1391");
Security.loadPolicyFile("http://vx1391:8080/job/Remote%20FIT%20Runner/ws/trunk/flash-cross-domain.xml");
My cross-domain.xml file is wide-open:
<cross-domain-policy>
<allow-access-from domain="*"/>
</cross-domain-policy>
Which I know is bad in a prod enivironment, but right now I just need to get this working locally but outside of FlexBuilder.
Anyone want to help out this Flex-noob?
© Stack Overflow or respective owner