Add WiFiClientSecure::setInsecure() to equalize API with ESP8266 (#4648)

This commit is contained in:
Me No Dev
2020-12-21 01:09:37 +02:00
committed by GitHub
parent b05bdf6904
commit ef99cd7fe7
6 changed files with 106 additions and 22 deletions

View File

@ -33,6 +33,7 @@ protected:
int _lastError = 0;
int _peek = -1;
int _timeout = 0;
bool _use_insecure;
const char *_CA_cert;
const char *_cert;
const char *_private_key;
@ -62,6 +63,7 @@ public:
void stop();
uint8_t connected();
int lastError(char *buf, const size_t size);
void setInsecure(); // Don't validate the chain, just accept whatever is given. VERY INSECURE!
void setPreSharedKey(const char *pskIdent, const char *psKey); // psKey in Hex
void setCACert(const char *rootCA);
void setCertificate(const char *client_ca);