summaryrefslogtreecommitdiffstats
path: root/dom/security/nsCSPUtils.h
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@gmail.com>2017-08-15 21:10:10 +0200
committerwolfbeast <mcwerewolf@gmail.com>2018-02-06 09:03:16 +0100
commit13e9a0c06d35bb02d211df873c105a350aeab8eb (patch)
tree7a02bdb0992080b231c190c383bc12fac1607cd4 /dom/security/nsCSPUtils.h
parenta9b44dbcb33cd98b163f8a21223643f2cf3829cd (diff)
downloadUXP-13e9a0c06d35bb02d211df873c105a350aeab8eb.tar
UXP-13e9a0c06d35bb02d211df873c105a350aeab8eb.tar.gz
UXP-13e9a0c06d35bb02d211df873c105a350aeab8eb.tar.lz
UXP-13e9a0c06d35bb02d211df873c105a350aeab8eb.tar.xz
UXP-13e9a0c06d35bb02d211df873c105a350aeab8eb.zip
CSP should only check host (not including path) when performing frame ancestors checks.
This has been explicitly stated in the CSP-3 spec.
Diffstat (limited to 'dom/security/nsCSPUtils.h')
-rw-r--r--dom/security/nsCSPUtils.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/dom/security/nsCSPUtils.h b/dom/security/nsCSPUtils.h
index b33c8932a..468c734a2 100644
--- a/dom/security/nsCSPUtils.h
+++ b/dom/security/nsCSPUtils.h
@@ -256,6 +256,9 @@ class nsCSPHostSrc : public nsCSPBaseSrc {
void setPort(const nsAString& aPort);
void appendPath(const nsAString &aPath);
+ inline void setWithinFrameAncestorsDir(bool aValue) const
+ { mWithinFrameAncstorsDir = aValue; }
+
inline void getScheme(nsAString& outStr) const
{ outStr.Assign(mScheme); };
@@ -273,6 +276,7 @@ class nsCSPHostSrc : public nsCSPBaseSrc {
nsString mHost;
nsString mPort;
nsString mPath;
+ mutable bool mWithinFrameAncstorsDir;
};
/* =============== nsCSPKeywordSrc ============ */