fix off-by-one error in NTLM proxy authentication
Change-Id: Icee3fc939d81c726f8e4ed484a0c8685cf1f271c Task-number: QTBUG-27555 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
f191fe7cab
commit
c97e369e70
@ -1392,7 +1392,7 @@ static bool qNtlmDecodePhase2(const QByteArray& data, QNtlmPhase2Block& ch)
|
||||
ds >> ch.targetInfo;
|
||||
|
||||
if (ch.targetName.len > 0) {
|
||||
if (ch.targetName.len + ch.targetName.offset >= (unsigned)data.size())
|
||||
if (ch.targetName.len + ch.targetName.offset > (unsigned)data.size())
|
||||
return false;
|
||||
|
||||
ch.targetNameStr = qStringFromUcs2Le(data.mid(ch.targetName.offset, ch.targetName.len));
|
||||
|
Loading…
Reference in New Issue
Block a user