At the moment loadPolicyFile defaults to the server the HTML document is hosted on, which, like in my case, isn't the server that the actual server is running on( HTML is on Dropbox, the server is running on my local computer).
Therefore I can't connect to my server at bonsaiden.dyndns.org:28785 since flash requests the policy from dl.dropbox.com:843, which is clearly wrong.
Simple fix is to change the parameter of the initial loadPolicyFile(null) (WebSocketMain.as:54) call when creating a socket to loadPolicyFile(URLUtil.getServerName(url)), now flash correctly requests the policy from bonsaiden.dyndns.org:843 and everything works like a charm.
At the moment
loadPolicyFile
defaults to the server the HTML document is hosted on, which, like in my case, isn't the server that the actual server is running on( HTML is on Dropbox, the server is running on my local computer).Therefore I can't connect to my server at
bonsaiden.dyndns.org:28785
since flash requests the policy fromdl.dropbox.com:843
, which is clearly wrong.Simple fix is to change the parameter of the initial
loadPolicyFile(null)
(WebSocketMain.as:54) call when creating a socket toloadPolicyFile(URLUtil.getServerName(url))
, now flash correctly requests the policy frombonsaiden.dyndns.org:843
and everything works like a charm.