Socket.io wss needed - javascript

I am coding Chat System for my website and I have code ready and everything is fine, BUT there is one issue: I need to have wss for socket.io not ws. Idk how to make this so I didnt tried nothing. Maybe some1 knows how to do that? I am using CloudFlare for https

Related

Why does my Websocket Server need manual refreshing?

In order to add a chatting function to my website, I set up a Websocket server using node.js on a Windows 2016 server. I was able to establish a successful connection between my client and server and the application is working pretty smoothly.
However, every once in a while, the connection will appear to freeze and the client will send a message to the socket but the socket seems to be frozen until I refresh it by clicking on the command prompt on my server computer.
At first, I thought it was a connection issue but all the appropriate ports appear to be open and I am convinced that it is a server issue.
I am a beginning coder so I'm sorry if I am not using the proper terminology but help would be much appreciated. If anything is unclear I will add more info.
Thanks!

Electron HTTPS for local file

Tried using electron to work with web speech API but it records no voice. It is probably due to the HTTPS connection requirement, but how would I show HTTPS if I am loading the app locally like
win.loadURL('app://./index.html')
?
I basically want to use webspeechapi on my local app but it does not seem to work. I think it is probably due to the requirement of having an https connection. How would i go about having it if i am using a simple main.js file?
You could use ngrok, and connect to your app via that, rather than at localhost.

What is the problem with Websocket and Self-Signed SSL certificate

I have a project runs on intranet, so I didn't buy any SSL certificate or domain name. Instead, I created self-signed certificate. I have two layer one of which is web service/websocket and the other is view. Everything is OK for all https connections, hence all pages, but browser could not make connection with ws or wss links(was tried ports 8443,443,8080). If I write link with localhost instead of my ip, it works perfectly, but then I cannot use it from another device. I created certificete as RSA/2048. My project runs on Ubuntu 18.04. Serverside was written in Java-Spring Boot.
If someone else need an answer, I got it from here. As summary, the problem is about Firefox, not about other browsers. Main reason is that Firefox do not accept certificate of wss link, in fact it is also the same certificate for the first connection link start with https. Solution is to go to the link started with wss by chancing wss to https and accept privilege of that link, and everthing works fine :)

Facebook messenger chatbot shows "Check your connection and try again."

Recently, I was trying to build a bot for myself. It works flawlessly when I'm using ngrok to test my bot locally, but when I deployed to AWS, I started seeing the error captured below occasionally, and causing no webhook request sent to my server from Facebook. I have no idea what could possibly go wrong. I have check the request going to my server with tcpflow as well, but there's no luck, it seems like Facebook just didn't send that particular request to my server. This is a really weird problem that happens in no particular point of my bot conversation flow. I always need to repeat my answer or my postback in order to get it to work.
Some basic server info (don't know if this matters) :
Availability zone: ap-southeast-1b
Type: t2.micro
CPU usage (at that moment): 4%
I would really appreciated if anyone could solve my mystery. Thanks.
FYI, I have reported this to Facebook: https://developers.facebook.com/bugs/1825253057751227
Your webhook server has to work over valid https (not self signed).
My advice - add https to webhook server, using cloudflare service (it`s free), or get a free valid certificate using letsencrypt
If your error is occasional, I would recommend moving your instance size up from Micro, to at least Medium or Large and make it a Dedicated instance. The resources required to run the letsencrypt client, combined with your bot traffic and noisy neighbors might overcome a shared micro instance.

Getting ERR_INSECURE_RESPONSE when trying to use IIS ssl

I am trying to implement my site with SSL. I used the IIS to create a self-signed certificate. But when calling the site using https I keep getting ERR_INSECURE_RESPONSE and never seem to reach the server.
I use Chrome extension 'Advanced Rest client' to call the server.
I have no clue to what to do, appreciate the help...
Recreate the self signed certificate using the following tutorial -
https://technet.microsoft.com/en-us/library/cc753127(v=ws.10).aspx
I've never seen this error specifically but suspect there is an issue with the certificate.

Categories

Resources