scanno / nl.scanno.mqttbroker

2 stars 1 forks source link

Two port number text boxes? #9

Open DIYglenn opened 5 years ago

DIYglenn commented 5 years ago

Hi! Just reinstalled to setup MQTT from scratch on Homey. But I don't understand the port settings? There is one port for "uns", what is this?

mqtt broker

I've had issues with TLS and ESP8266, so I'm going unencrypted to start with. Can the connections be both encrypted and non-encrypted? Is that why there are two text boxes for port?

scanno commented 5 years ago

It's now possible to have a secure and a unsecure port available at the same time. For instance if you have owntracks installed or the mqtt client, you can let the mqtt client or owntracks connect to localhost. In such situation a insecure connection solves the problem of rejected connections due to certificate failures when using Let's encrypt certificates.

If you want both a insecure as secure connections, you need two port numbers

DIYglenn commented 5 years ago

OK, cool. Then I can have insecure port (1883?) for my ESP8266's for now.

But which is which? Is the top (uns) for secure/8883 and the bottom for insecure/1883?

scanno commented 5 years ago

First box is unsecure second secure

scanno commented 5 years ago

screenshot_20181220-132611

DIYglenn commented 5 years ago

Great, thanks! That's where I messed up. Do I also need to choose "Also enable unsecure connections" if I don't have secured connection enabled?

scanno commented 5 years ago

Only if you want both. But you need to disable the use tls checkbox if you only want unsecure

DIYglenn commented 5 years ago

I refreshed and got your reply with photo. I've followed your example, I generated keys and certificate with common name "homey". I've enabled both encrypted and non-encrypted. Perfect for testing my ESP8266 sensors, and try to get everything encrypted in the end. Thanks!!