File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
Filter options
libraries/ESP8266WebServer/src Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
Original file line number Diff line number Diff line change 38
38
39
39
static const char AUTHORIZATION_HEADER[] PROGMEM = " Authorization" ;
40
40
static const char qop_auth[] PROGMEM = " qop=auth" ;
41
+ static const char qop_auth_quoted[] PROGMEM = " qop=\" auth\" " ;
41
42
static const char WWW_Authenticate[] PROGMEM = " WWW-Authenticate" ;
42
43
static const char Content_Length[] PROGMEM = " Content-Length" ;
43
44
@@ -165,7 +166,7 @@ bool ESP8266WebServer::authenticate(const char * username, const char * password
165
166
}
166
167
// parameters for the RFC 2617 newer Digest
167
168
String _nc,_cnonce;
168
- if (authReq.indexOf (FPSTR (qop_auth)) != -1 ) {
169
+ if (authReq.indexOf (FPSTR (qop_auth)) != -1 || authReq. indexOf ( FPSTR (qop_auth_quoted)) != - 1 ) {
169
170
_nc = _extractParam (authReq, F (" nc=" ), ' ,' );
170
171
_cnonce = _extractParam (authReq, F (" cnonce=\" " ));
171
172
}
@@ -195,7 +196,7 @@ bool ESP8266WebServer::authenticate(const char * username, const char * password
195
196
DEBUG_OUTPUT.println (" Hash of GET:uri=" + _H2);
196
197
#endif
197
198
md5.begin ();
198
- if (authReq.indexOf (FPSTR (qop_auth)) != -1 ) {
199
+ if (authReq.indexOf (FPSTR (qop_auth)) != -1 || authReq. indexOf ( FPSTR (qop_auth_quoted)) != - 1 ) {
199
200
md5.add (_H1 + ' :' + _nonce + ' :' + _nc + ' :' + _cnonce + F (" :auth:" ) + _H2);
200
201
} else {
201
202
md5.add (_H1 + ' :' + _nonce + ' :' + _H2);
You can’t perform that action at this time.
0 commit comments