gecko-dev/dom/xhr
Kris Maglione 27c96362b9 Bug 1412345: Downgrade expanded principals before inheriting. r=bz,krizsa
There are several ways that expanded principals can be used as triggering
principals for requests. While that works fine for security checks, it also
sometimes causes them to be inherited, and used as result principals in
contexts where expanded principals aren't allowed.

This patch changes our inheritance behavior so that expanded principals are
downgraded to the most appropriate constituent principal when they would
otherwise be inherited.

The logic for choosing the most appropriate principal is a bit suspect, and
may eventually need to be changed to always select the last whitelist
principal, but I chose it to preserve the current principal downgrade behavior
used by XMLHttpRequest for the time being.

MozReview-Commit-ID: 9fvAKr2e2fa

--HG--
extra : rebase_source : c30df1b3851c11fed5a1d6a7fb158cec14933182
2017-11-02 19:56:27 -07:00
..
tests Bug 1397151 - Remove the support for moz-chunk-text type in XHR, r=smaug 2017-09-22 07:18:49 +02:00
XMLHttpRequest.cpp
XMLHttpRequest.h Bug 1392358 - Introduce XHR.sendInputStream(nsIInputStream) chrome-only, r=smaug 2017-08-25 15:31:15 +02:00
XMLHttpRequestEventTarget.cpp Bug 1391005 - Eliminate NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED. r=peterv 2017-08-29 16:02:48 -07:00
XMLHttpRequestEventTarget.h
XMLHttpRequestMainThread.cpp Bug 1412345: Downgrade expanded principals before inheriting. r=bz,krizsa 2017-11-02 19:56:27 -07:00
XMLHttpRequestMainThread.h Bug 1409327 - NS_NewBufferedInputStream should take the ownership of the inputStream, r=smaug 2017-10-19 11:39:30 +02:00
XMLHttpRequestString.cpp Bug 1407117 - Simplify static atom representation. r=froydnj,bz. 2017-10-12 10:52:17 +11:00
XMLHttpRequestString.h Bug 1350398 Remove Workers.h include from BindingUtils.h now that ThrowDOMExceptionForNSResult no longer exists. rs=bz 2017-03-24 15:27:11 -04:00
XMLHttpRequestUpload.cpp
XMLHttpRequestUpload.h
XMLHttpRequestWorker.cpp Bug 1400748 - Correct our handling of XHR.abort edge-cases; r=baku 2017-09-25 12:58:23 -04:00
XMLHttpRequestWorker.h Bug 1392358 - Introduce XHR.sendInputStream(nsIInputStream) chrome-only, r=smaug 2017-08-25 15:31:15 +02:00
moz.build Bug 1337016 - XHR should create a Blob in the parent process when run from a file:// URL, r=smaug 2017-02-08 14:34:42 +01:00
nsIXMLHttpRequest.idl Bug 1401848. Remove NS_IMPL_EVENT_HANDLER and its consumers. r=smaug 2017-09-22 18:07:05 -04:00