Did you see this thread? there are multiple examples for the esp8266
My example for verifying the root ca definitely worked for me, also with the PubSubClient library which you are using.
Did you see this thread? there are multiple examples for the esp8266
My example for verifying the root ca definitely worked for me, also with the PubSubClient library which you are using.