MeshCentral2 - Added MQTT Support
In the last week MQTT support was added to MeshCentral. The Message Queuing Telemetry Transport
(MQTT) is a simple protocol often used for Internet Of Thing (IoT) devices. By
making MeshCentral fully capable of handling MQTT connections, this opens many
more opportunities for developers to attach their own devices and usages to
MeshCentral. MeshCentral does require a few added lines in the server’s
configuration file you can enable built-in MQTT support. Here are a few
details:
- MQTT Login Credentials. When enabled, a new “MQTT Login” link will show up at the bottom of a device “General” tab. Clicking on this will give the user a JSON document will all of the information needed to authenticate and login to the server. The document includes a username, password, URL’s and certificate hashes making it easy to cut and paste this into a device for a successful and secure connection.
- MQTT Console. The agent console tab was modified to support both agent commands and MQTT commands. In MQTT mode, any command that is typed will be send to that device under the “console” topic. Any messages sent from the device to the server with the “console” topic will be displayed back into the console. This makes it easy to create a small MQTT device that connects and handles user commands.
- MQTT Power Actions. MeshCentral can be used to perform power actions like wake, reset and sleep. If a MQTT connection is active while such a command is issued by the administrator, MeshCentral will send the command under the “poweraction” topic. This makes it easy for devices to respond to these commands accordingly.
- MQTT Custom Messages. When one or more devices are selected and a group action is taken, the option to send a custom MQTT message will be displayed. This allows the administrator to type in a custom topic and message to be sent to a remote device. You can also do this by pressing the “Action” button in a device’s “General” tab.
MeshCentral can receive MQTT
connections on ports 443 (HTTPS/WebSocket) or 4433 (Intel AMT CIRA/Binary). We
have a small NodeJS
MQTT device sample here. The code to connect to
MeshCentral is quite simple making this an idea way to integrate additional
usages. In addition to this big feature, we have plenty more that was added in
the last 3 week, but more on this later
Enjoy,
Ylian
Twitter: https://twitter.com/meshcentral