0

I'm trying to use websockets in a web page with javascript, ('ws://localhost:9090') but get the following error from firefox:

"Caught exception while dispatching event:
The operation is insecure."

If I change the url of the websocket to 'wss://localhost:9090' I get another error:

Firefox can't establish a connection to the server at wss://localhost:9090/.

The javascript I'm working on is meant to communicate with the ros operating system on a robot that has it installed. How can I enable websockets in this special situation? I was using google chrome because of the limitations on firefox, but after a recent update of chrome, it seems impossible there too. On chrome I get another error.

3
  • i don't think localhost can be secure, try ws: instead Commented Jan 16, 2014 at 22:37
  • I would like to use firefox, but in the mean time I've found that websockets (with localhost as the ip address) do work on google-chrome. The error I was getting in chrome was related to something else. Commented Jan 17, 2014 at 14:24
  • I had the same problem and I posted it as well. I read some articles about this issue and they say that it is an self-created certificate issue, i am not sure about that. Waiting for response. You can follow the post in case of it may help Can not established WEbsocket secure connection on Firefox Commented May 21, 2014 at 6:12

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.