File tree 2 files changed +9
-9
lines changed
libraries/SocketWrapper/src
2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change 1
1
#include " MbedSSLClient.h"
2
2
3
3
arduino::MbedSSLClient::MbedSSLClient ()
4
- : _ca_cert_custom (nullptr ),
4
+ : _rootCA (nullptr ),
5
5
_hostname(nullptr ),
6
6
_clientCert(nullptr ),
7
7
_privateKey(nullptr ),
Original file line number Diff line number Diff line change @@ -48,12 +48,12 @@ class MbedSSLClient : public arduino::MbedClient {
48
48
_disableSNI = statusSNI;
49
49
}
50
50
51
- void appendCustomCACert (const char * ca_cert ) {
52
- _ca_cert_custom = ca_cert ;
51
+ void appendCustomCACert (const char * rootCA ) {
52
+ _rootCA = rootCA ;
53
53
_appendCA = true ;
54
54
}
55
55
void setCACert (const char * rootCA) {
56
- _ca_cert_custom = rootCA;
56
+ _rootCA = rootCA;
57
57
_appendCA = false ;
58
58
}
59
59
void setCertificate (const char * clientCert) {
@@ -64,7 +64,7 @@ class MbedSSLClient : public arduino::MbedClient {
64
64
}
65
65
66
66
protected:
67
- const char * _ca_cert_custom ;
67
+ const char * _rootCA ;
68
68
const char * _hostname;
69
69
const char * _clientCert;
70
70
const char * _privateKey;
@@ -86,8 +86,8 @@ class MbedSSLClient : public arduino::MbedClient {
86
86
}
87
87
}
88
88
89
- if (!_appendCA && _ca_cert_custom ) {
90
- return ((TLSSocket*)sock)->set_root_ca_cert (_ca_cert_custom );
89
+ if (!_appendCA && _rootCA ) {
90
+ return ((TLSSocket*)sock)->set_root_ca_cert (_rootCA );
91
91
}
92
92
93
93
#if defined(MBEDTLS_FS_IO)
@@ -111,8 +111,8 @@ class MbedSSLClient : public arduino::MbedClient {
111
111
}
112
112
#endif
113
113
114
- if (_ca_cert_custom != NULL ) {
115
- err = ((TLSSocket*)sock)->append_root_ca_cert (_ca_cert_custom );
114
+ if (_rootCA != NULL ) {
115
+ err = ((TLSSocket*)sock)->append_root_ca_cert (_rootCA );
116
116
}
117
117
return err;
118
118
}
You can’t perform that action at this time.
0 commit comments