1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-21 10:26:06 +03:00

Skip ':' inside SHA1 signatures in WiFiClientSecure.cpp .

Improves the convenience of the verification of fingerprints.
As ':' are commonly inserted by web browser inside the SHA1 of https web sites, this created false problems with signatures "not matching".
Now, copied and pasted signature from Firefox simply because the verify function will skipped them...
This commit is contained in:
asez73 2015-12-15 11:41:29 +01:00
parent 4014f91724
commit 4be40bc5fa

View File

@ -327,7 +327,7 @@ bool WiFiClientSecure::verify(const char* fp, const char* url) {
int len = strlen(fp);
int pos = 0;
for (size_t i = 0; i < sizeof(sha1); ++i) {
while (pos < len && fp[pos] == ' ') {
while (pos < len && ((fp[pos] == ' ') || (fp[pos] == ':'))) {
++pos;
}
if (pos > len - 2) {