CocoaMQTT icon indicating copy to clipboard operation
CocoaMQTT copied to clipboard

client certificates

Open travisgriggs opened this issue 6 years ago • 2 comments

I apologize for using the issues to ask a question. I'm looking for Swift MQTT library that can do client side certs. Does CocoaMQTT do so? I've been testing my setup using the linux command line tools, e.g.:

mosquitto_pub -h ubuntu -p 8765 -t 1234/2/Q/8 -m CountryRoadTakeMeHome --cafile ~/CA2/Chain.crt -d --cert ./1234.1_cert.crt --key ./1234.1_key.pem

Will CocoaMQTT allow me to do something similar (before I invest in the effort to integrate it)?

travisgriggs avatar Jan 29 '19 00:01 travisgriggs

Hi, @travisgriggs Sorry for the late reply.

Yes, the CocoaMQTT support two-way SSL connection. In the first, you should generate the .p12 file by the client certificates. Then follow the Example code to setup CocoaMQTT client instance.

HJianBo avatar May 20 '19 09:05 HJianBo