Client network socket disconnected before secure TLS connection was established

Hi,

I am experiencing the error message Client network socket disconnected before secure TLS connection was established, when I open the Editor UI (okay) and I click on "Sign In" button (error).

I run nodered as follow:

  1. protected by Keycloack (Auth, both Editor UI and HTTP endpoints)
  2. docker container
  3. hosted on aws ec2 instance, with a load balancer on top owning the ssl certificate.

So the ssl certificate is on top of the ec2/docker/nodered and transparent for them...

In nodered, the settings.js section related to ssl is commented out like this:

    //https: {
    //    key: fs.readFileSync('privatekey.pem'),
    //    cert: fs.readFileSync('certificate.pem')
    //},

I don't get where the error message comes form... no output in logs.

More over, I had a look to this repo (node-red on aws) linked from the nodered ufficial docs: GitHub - guysqr/node-red-ha-on-aws: Node-RED on AWS with EFS to enable horizontal scaling. Uses Elastic Beanstalk to create additional instances into a load-balanced auto-scaling group as required. and I see the settings.js there pretty similar to mine... ssl commented out.

Any suggestion is very appreciated.

Thanks, F.

Can I just check, are your clients connecting via http or https?

By https...

OK, so AWS is terminating the TLS and I wonder if it is configured to handle websocket comms?

Whatever proxy your AWS config is using needs to be configured to handle websockets which requires http 1.1

Yes, websocket is allowed.

I think you will find that it is misconfigured.

You will need something that captures and shows the handshake. You might be able to use the network tab on your browser or you might be better trying something like CURL with -v.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.