eclipse-thingweb / eclipse-thingweb/node-wot
MqttBrokerServer ignores username
- Dominant language
- TypeScript
- Stars
- 192
- Forks
- 100
- Avg merge
- 3d 2h
- Merged PRs (30d)
- 6
Description
Trying to use `MqttBrokerServer` with a username/password combination fails with "bad username or password", while the credentials are ok.
Enabling the log shows why:
```
node-wot:binding-mqtt:mqtt-broker-server:debug MqttBrokerServer trying to connect to secured broker at ssl://mqtt.sandbox.drogue.cloud with client ID wot11668767174292 +0ms
mqttjs connecting to an MQTT broker... +0ms
mqttjs:client MqttClient :: options.protocol ssl +0ms
mqttjs:client MqttClient :: options.protocolVersion 5 +0ms
mqttjs:client MqttClient :: options.username undefined +0ms
mqttjs:client MqttClient :: options.keepalive 60 +0ms
mqttjs:client MqttClient :: options.reconnectPeriod 1000 +1ms
mqttjs:client MqttClient :: options.rejectUnauthorized undefined +0ms
mqttjs:client MqttClient :: options.topicAliasMaximum undefined +0ms
mqttjs:client MqttClient :: clientId wot11668767174292 +0ms
mqttjs:client MqttClient :: setting up stream +0ms
```
I says `connect to secured broker` (which indicates a password is present in the configuration, but then has `options.username undefined`.
Contributor guide
Assessment
This issue has not been assessed yet.