I finally got what I wanted to add some time to my Library M2Mqtt : support for the SSL / TLS protocol !
With this new feature , you can now connect to a MQTT broker also using SSL / TLS (for .NET Micro Framework only up to TLS1.0 ) to take advantage of its key features: data encryption and server authentication through an X509 certificate (client authentication is not supported) .
To leave free choice to the developer wanted to or not to include this feature in his project ,I tied everything to the compilation symbol "SSL" which must be defined to add such support. In this way, for some platforms with less memory (see Netduino or FEZ Cerberus in the case of .NET Micro Framework ), you can exclude it , remembering to remove all references to assemblies that run the SSL / TLS.
Of course , as well as on CodePlex, the update is also available on Nuget !
As soon as possible, I will write a new post in which I describe an example of using secure connection with an MQTT broker like Mosquitto !
View this page in another language: