summaryrefslogtreecommitdiffstats
path: root/dom/security
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@wolfbeast.com>2019-07-14 22:41:01 +0200
committerwolfbeast <mcwerewolf@wolfbeast.com>2019-07-14 22:41:01 +0200
commitd9aff90f06254a0b724a0ea9c21db39f74ff8fc6 (patch)
treed4c4153819b192d23ed2bcbf6e99191a64d203a4 /dom/security
parent609ded8d47b19e91997baeadcacc5e7bf735a113 (diff)
downloadUXP-d9aff90f06254a0b724a0ea9c21db39f74ff8fc6.tar
UXP-d9aff90f06254a0b724a0ea9c21db39f74ff8fc6.tar.gz
UXP-d9aff90f06254a0b724a0ea9c21db39f74ff8fc6.tar.lz
UXP-d9aff90f06254a0b724a0ea9c21db39f74ff8fc6.tar.xz
UXP-d9aff90f06254a0b724a0ea9c21db39f74ff8fc6.zip
Add preference to allow the loading of FTP subresources for corner cases
Diffstat (limited to 'dom/security')
-rw-r--r--dom/security/nsContentSecurityManager.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/dom/security/nsContentSecurityManager.cpp b/dom/security/nsContentSecurityManager.cpp
index f2cbc8fcf..12c55e8f6 100644
--- a/dom/security/nsContentSecurityManager.cpp
+++ b/dom/security/nsContentSecurityManager.cpp
@@ -98,6 +98,9 @@ nsContentSecurityManager::CheckFTPSubresourceLoad(nsIChannel* aChannel)
// We dissallow using FTP resources as a subresource everywhere.
// The only valid way to use FTP resources is loading it as
// a top level document.
+ if (!mozilla::net::nsIOService::BlockFTPSubresources()) {
+ return NS_OK;
+ }
nsCOMPtr<nsILoadInfo> loadInfo = aChannel->GetLoadInfo();
if (!loadInfo) {