author | Cykesiopka <cykesiopka.bmo@gmail.com> |
Mon, 17 Apr 2017 17:34:18 +0800 | |
changeset 353997 | c1d7ee18b7d0bd59990d666473d47b8b31f4710b |
parent 353996 | b4bdc406fc1d750c0b19dd8a6ba7731f7072f5ce |
child 353998 | 7492d1c0aad42af792d55fed897be329489f7219 |
push id | 31684 |
push user | cbook@mozilla.com |
push date | Thu, 20 Apr 2017 09:13:26 +0000 |
treeherder | mozilla-central@27311156637f [default view] [failures only] |
perfherder | [talos] [build metrics] [platform microbench] (compared to previous push) |
reviewers | ckerschb |
bugs | 1356522, 1338897 |
milestone | 55.0a1 |
first release with | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
last release without | nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
|
--- a/dom/security/nsCSPUtils.cpp +++ b/dom/security/nsCSPUtils.cpp @@ -914,20 +914,16 @@ nsCSPHashSrc::allows(enum CSPKeyword aKe rv = hasher->Update((uint8_t *)utf8_hash.get(), utf8_hash.Length()); NS_ENSURE_SUCCESS(rv, false); nsAutoCString hash; rv = hasher->Finish(true, hash); NS_ENSURE_SUCCESS(rv, false); - // The NSS Base64 encoder automatically adds linebreaks "\r\n" every 64 - // characters. We need to remove these so we can properly validate longer - // (SHA-512) base64-encoded hashes - hash.StripChars("\r\n"); return NS_ConvertUTF16toUTF8(mHash).Equals(hash); } bool nsCSPHashSrc::visit(nsCSPSrcVisitor* aVisitor) const { return aVisitor->visitHashSrc(*this); }