File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 3333 }
3434#endif
3535
36- void TLSClientMqtt::begin (ConnectionHandler & connection) {
36+
37+ void TLSClientMqtt::begin (ConnectionHandler & connection, ArduinoIoTAuthenticationMode authMode) {
3738
3839#if defined(BOARD_HAS_OFFLOADED_ECCX08)
3940 /* Arduino Root CA is configured in nina-fw
4041 * https://github.com/arduino/nina-fw/blob/master/arduino/libraries/ArduinoBearSSL/src/BearSSLTrustAnchors.h
4142 */
43+ (void )authMode;
4244#elif defined(BOARD_HAS_ECCX08)
45+ (void )authMode;
4346 setClient (connection.getClient ());
4447 setProfile (aiotc_client_profile_init);
4548 setTrustAnchors (ArduinoIoTCloudTrustAnchor, ArduinoIoTCloudTrustAnchor_NUM);
4649 onGetTime (getTime);
4750#elif defined(ARDUINO_PORTENTA_C33)
51+ (void )authMode;
4852 setClient (connection.getClient ());
4953 setCACert (AIoTSSCert);
5054#elif defined(ARDUINO_NICLA_VISION)
55+ (void )authMode;
5156 appendCustomCACert (AIoTSSCert);
5257#elif defined(ARDUINO_EDGE_CONTROL)
58+ (void )authMode;
5359 appendCustomCACert (AIoTUPCert);
5460#elif defined(ARDUINO_UNOR4_WIFI)
5561 /* Arduino Root CA is configured in uno-r4-wifi-usb-bridge fw >= 0.4.1
@@ -62,8 +68,10 @@ void TLSClientMqtt::begin(ConnectionHandler & connection) {
6268 /* Temporary force CACert to add new CA without rebuilding firmware */
6369 setCACert (AIoTSSCert);
6470#elif defined(ARDUINO_ARCH_ESP32)
71+ (void )authMode;
6572 setCACert (AIoTUPCert);
6673#elif defined(ARDUINO_ARCH_ESP8266)
74+ (void )authMode;
6775 setInsecure ();
6876#endif
6977}
Original file line number Diff line number Diff line change @@ -71,6 +71,6 @@ enum class ArduinoIoTAuthenticationMode
7171#endif
7272
7373public:
74- void begin (ConnectionHandler & connection);
74+ void begin (ConnectionHandler & connection, ArduinoIoTAuthenticationMode authMode = ArduinoIoTAuthenticationMode::CERTIFICATE );
7575
7676};
You can’t perform that action at this time.
0 commit comments