Solved

SWF accessing blazeds from another domain

Posted on 2012-03-15
3
497 Views
Last Modified: 2012-04-11
We have a pure as3 - no flex - swf that we wish to connect to our BlazeDS back end.  We know that the swf works, and that it does connect to the back end.  However, we have recently moved only the swf to a different server, and it is no longer accessing BlazeDS correctly.  This is the error we are getting when we try:

[ChannelFaultEvent faultCode="Channel.Security.Error" faultString="error" faultDetail="Error #2048 url: 'http://ourdomain:port/blazeds/messagebroker/amf'" channelId="my-amf" type="channelFault" bubbles=false cancelable=false eventPhase=2]

where ourdomain and port are obviously replaced with the correct values.  

The endpoint url in services-config.xml is not hard coded, it is set to http://{server.name}:{server.port}/ etc.  We have tried setting the crossdomain xml to allow all, and are still getting this error.  How can we make the swf conncet to our BlazeDS again from any server we house it on?
0
Comment
Question by:anotherfn
3 Comments
 
LVL 29

Expert Comment

by:dgofman
ID: 37749961
Use crossdomain.xml and set System.allowDomain("*");


http://www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html
0
 

Author Comment

by:anotherfn
ID: 37765206
We've got a crossdomain policy xml file already set to allow all domains, and yet this still isn't working.
0
 
LVL 8

Accepted Solution

by:
section25 earned 500 total points
ID: 37767865
My cross domain policy didn't start working until I added the third line. Copy and paste this one and see if it works for you too.


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

Also, make sure this is at the root of the site.
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
why cannot we forward request once the response is committed 2 46
MySQL  on Tomcat 8 68
SHA2 certs for IIS AND Java? 2 113
runtime exception 2 41
While working over numerous projects I often had the requirement for doing a screen capture in AS3.0. Unfortunately I found no "ready made" solutions in google search that suited my requirements. But I did come across some great resources which help…
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
The goal of the tutorial is to teach the user how to live broadcast using Flash Media Live Encoder and connecting it to YouTube to broadcast. Log into your Youtube account, choose live stream settings, start live stream from Flash Media Live Enc…
The goal of the tutorial is to teach the user what frame rate is, how to control it and what effect it has on the video.

792 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question