File tree 3 files changed +13
-12
lines changed
3 files changed +13
-12
lines changed Original file line number Diff line number Diff line change @@ -193,11 +193,12 @@ BearSSL does verify the notValidBefore/After fields.
193
193
fetchURL (&client, host, port, path);
194
194
}
195
195
196
- void fetchAxTLS () {
196
+ void fetchFaster () {
197
197
Serial.printf (R"EOF(
198
198
The ciphers used to set up the SSL connection can be configured to
199
- be the same as axTLS. They are faster, but less secure, so if you care
200
- about security you won't want to do this.
199
+ only support faster but less secure ciphers. If you care about security
200
+ you won't want to do this. If you need to maximize battery life, these
201
+ may make sense
201
202
)EOF" );
202
203
BearSSL::WiFiClientSecure client;
203
204
client.setInsecure ();
@@ -206,10 +207,10 @@ about security you won't want to do this.
206
207
uint32_t delta = millis () - now;
207
208
now = millis ();
208
209
client.setInsecure ();
209
- client.setAxTLSCiphers ();
210
+ client.setCiphersLessSecure ();
210
211
fetchURL (&client, host, port, path);
211
212
uint32_t delta2 = millis () - now;
212
- Serial.printf (" Using more secure: %dms\n Usiing axTLS ciphers: %dms\n " , delta, delta2);
213
+ Serial.printf (" Using more secure: %dms\n Using less secure ciphers: %dms\n " , delta, delta2);
213
214
}
214
215
215
216
void setup () {
@@ -239,7 +240,7 @@ void setup() {
239
240
fetchSelfSigned ();
240
241
fetchKnownKey ();
241
242
fetchCertAuthority ();
242
- fetchAxTLS ();
243
+ fetchFaster ();
243
244
}
244
245
245
246
Original file line number Diff line number Diff line change @@ -687,8 +687,8 @@ extern "C" {
687
687
BR_TLS_RSA_WITH_3DES_EDE_CBC_SHA
688
688
};
689
689
690
- // For apps which want to use less secure but faster axTLS ciphers, only
691
- static const uint16_t axtls_suites_P [] PROGMEM = {
690
+ // For apps which want to use less secure but faster ciphers, only
691
+ static const uint16_t faster_suites_P [] PROGMEM = {
692
692
BR_TLS_RSA_WITH_AES_256_CBC_SHA256,
693
693
BR_TLS_RSA_WITH_AES_128_CBC_SHA256,
694
694
BR_TLS_RSA_WITH_AES_256_CBC_SHA,
@@ -735,10 +735,10 @@ extern "C" {
735
735
736
736
}
737
737
738
- // Set the AXTLS ciphers as the only ones allowed
739
- void WiFiClientSecure::setAxTLSCiphers ()
738
+ // Set the faster ciphers as the only ones allowed
739
+ void WiFiClientSecure::setCiphersLessSecure ()
740
740
{
741
- setCiphers (axtls_suites_P , sizeof (axtls_suites_P )/sizeof (axtls_suites_P [0 ]));
741
+ setCiphers (faster_suites_P , sizeof (faster_suites_P )/sizeof (faster_suites_P [0 ]));
742
742
}
743
743
744
744
// Installs the appropriate X509 cert validation method for a client connection
Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ class WiFiClientSecure : public WiFiClient {
107
107
// Select specific ciphers (i.e. optimize for speed over security)
108
108
// These may be in PROGMEM or RAM, either will run properly
109
109
void setCiphers (const uint16_t *cipherAry, int cipherCount) { _cipher_list = cipherAry; _cipher_cnt = cipherCount; }
110
- void setAxTLSCiphers (); // Only use the limited set of axTLS ciphers
110
+ void setCiphersLessSecure (); // Only use the limited set of RSA ciphers without EC
111
111
112
112
// Check for Maximum Fragment Length support for given len
113
113
static bool probeMaxFragmentLength (IPAddress ip, uint16_t port, uint16_t len);
You can’t perform that action at this time.
0 commit comments