Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flash port 843 doesn't response #61

Closed
erickhsiao opened this issue Oct 17, 2011 · 1 comment
Closed

Flash port 843 doesn't response #61

erickhsiao opened this issue Oct 17, 2011 · 1 comment

Comments

@erickhsiao
Copy link

Perhaps this issue already solved?

I use web-socket-js for IE which connect via flash.
but get no response, I asked web-socket-js and they said it should be support by default.

just wondering any body also face this problem?

@mloughran
Copy link
Collaborator

em-websocket doesn't listen on port 843 (nor should it)

Flash will try connecting on port 843. If it doesn't get a response it will try requesting the flash policy file on the WebSocket port (which em-websocket will respond to)

If you want to serve the flash policy file on port 843 you can use something super simple like this, possibly in the same process as em-websocket:

require 'eventmachine'

module FlashPolicy
  def post_init
    cross_domain_xml =<<-EOF
    <cross-domain-policy>
       <allow-access-from domain="*" to-ports="*" />
    </cross-domain-policy>  
    EOF

    send_data cross_domain_xml
    close_connection_after_writing
  end
end

EM.run {
  EventMachine::start_server '0.0.0.0', 843, FlashPolicy
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants