httpm with nondefault port: no policy connection to the port
stpaft opened this issue · 3 comments
I try HTTPM method with a nondefault port (i.e. "httpm://host:12345/mjpeg.."). Policy server is on the same port (not 843). According to the instructions, flash should try first 843 port and then port 12345. But the second try doesn't happen.
You can try to use the loadPolicyFile method. It is not documented but I used it to load the policy on a different port. Do it before opening the url. Flash will still try to use 843, but will normally fallback to the url that you gave.
Thank you.
When I use ' locomote.loadPolicyFile('http://localhost:12345/crossdomain.xml') ' code it really fails back to the specified file. But then nothing happens - no more calls to the port 12345 and no error messages to the console.
crossdomain.xml looks like this:
<?xml version="1.0"?>
<cross-domain-policy>
<allow-access-from domain="*" to-ports="*" />
<allow-http-request-headers-from domain="*" headers="*"/>
</cross-domain-policy>
I'm not sure if http works. The socket policy file should be served with a simple socket server. See Setting up a socket policy file server from the adobe website.
In my company we use the port 80 to serve the policy file. We had to use haproxy to detect whenever it's a real http request or if it's a flash policy request.