You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to configure a Pre Shared Key encrypted connection between a mosquitto mqtt broker and an application written in Node.js which uses the MQTT client library.
I can't seem to find any samples or documentation that talks about how you'd set this up. Is it possible to authenticate the client with PSK using this library?
Thanks for your help :-)
The text was updated successfully, but these errors were encountered:
I think so, given that the PSK stuff is just TLS. However I do not know the options for doing it in node.js, a good starting point is https://nodejs.org/api/tls.html#tls_tls_connect_options_callback. You can pass any of those options through the mqtt.connect() method.
If you would like to document that in the examples folder and send a PR, that would be great!
Unfortunately after googling I don't think TLS-PSK is implemented by Node.js, because it is recently introduced to Openssl and is not widely supported. There was a PR (https://github.com/joyent/node/pull/1162/files) serveral years ago but was not accepted.
I am trying to configure a Pre Shared Key encrypted connection between a mosquitto mqtt broker and an application written in Node.js which uses the MQTT client library.
I can't seem to find any samples or documentation that talks about how you'd set this up. Is it possible to authenticate the client with PSK using this library?
Thanks for your help :-)
The text was updated successfully, but these errors were encountered: