We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fedd5ca commit 1766a1cCopy full SHA for 1766a1c
request.js
@@ -725,7 +725,7 @@ Request.prototype.onResponse = function (response) {
725
726
var ha1 = md5(self._user + ':' + challenge.realm + ':' + self._pass)
727
var ha2 = md5(self.method + ':' + self.uri.path)
728
- var qop = /(^|,)auth($|,)/.test(challenge.qop) && 'auth'
+ var qop = /(^|,)\s*auth\s*($|,)/.test(challenge.qop) && 'auth'
729
var nc = qop && '00000001'
730
var cnonce = qop && uuid().replace(/-/g, '')
731
var digestResponse = qop ? md5(ha1 + ':' + challenge.nonce + ':' + nc + ':' + cnonce + ':' + qop + ':' + ha2) : md5(ha1 + ':' + challenge.nonce + ':' + ha2)
0 commit comments