diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-02-09 08:53:46 +0100 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-02-09 08:53:46 +0100 |
commit | 8cecf8d5208f3945b35f879bba3015bb1a11bec6 (patch) | |
tree | 0926f5c21f9d10cf929e4c35e7d7e8e8c084dbf5 /dom/base/nsContentSink.cpp | |
parent | 8cd777888a40e987ad536ab68421068f5c06d83b (diff) | |
parent | 92104eb6828ba026550e1f4a3c6890c5b8254d36 (diff) | |
download | UXP-8cecf8d5208f3945b35f879bba3015bb1a11bec6.tar UXP-8cecf8d5208f3945b35f879bba3015bb1a11bec6.tar.gz UXP-8cecf8d5208f3945b35f879bba3015bb1a11bec6.tar.lz UXP-8cecf8d5208f3945b35f879bba3015bb1a11bec6.tar.xz UXP-8cecf8d5208f3945b35f879bba3015bb1a11bec6.zip |
Merge branch 'ported-upstream'
Diffstat (limited to 'dom/base/nsContentSink.cpp')
-rw-r--r-- | dom/base/nsContentSink.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/dom/base/nsContentSink.cpp b/dom/base/nsContentSink.cpp index 3d6f069d2..85b3d07bf 100644 --- a/dom/base/nsContentSink.cpp +++ b/dom/base/nsContentSink.cpp @@ -305,6 +305,11 @@ nsContentSink::ProcessHeaderData(nsIAtom* aHeader, const nsAString& aValue, mDocument->SetHeaderData(aHeader, aValue); if (aHeader == nsGkAtoms::setcookie) { + // Don't allow setting cookies in cookie-averse documents. + if (mDocument->IsCookieAverse()) { + return NS_OK; + } + // Note: Necko already handles cookies set via the channel. We can't just // call SetCookie on the channel because we want to do some security checks // here. |