Commit 9f25c399 authored by segfault's avatar segfault

Add Thunderbird patch to sanitize Content-Language header (refs: #17221)

parent 51dbd185
......@@ -19,6 +19,7 @@ tmpdir="$(mktemp -d)"
for patch in $(cat "$PATCHES_DIRECTORY"/series) ; do
cat "$PATCHES_DIRECTORY/$patch" \
| perl -p -E 's{^(--- [ab])/comm/mail/components/accountcreation/content/}{$1/chrome/messenger/content/messenger/accountcreation/}' \
| perl -p -E 's{^(--- [ab])/comm/mail/components/compose/content/}{$1/chrome/messenger/content/messenger/messengercompose/}' \
| perl -p -E 's{^(--- [ab])/comm/mailnews/mime/}{$1/modules/}' \
| perl -p -E 's{^(--- [ab])/comm/mailnews/}{$1/defaults/pref/}' \
| patch -p1
......
From 2a943f8a23977e5d0ac87fac7536fedd001c1efc Mon Sep 17 00:00:00 2001
From: segfault <segfault@riseup.net>
Date: Wed, 27 Nov 2019 23:37:55 +0100
Subject: [PATCH] Bug 1370217 - Avoid spellchecking language disclosure in
Content-Language header
---
comm/mail/components/compose/content/MsgComposeCommands.js | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/comm/mail/components/compose/content/MsgComposeCommands.js b/comm/mail/components/compose/content/MsgComposeCommands.js
index be339ba0173..6fa60636b6c 100644
--- a/comm/mail/components/compose/content/MsgComposeCommands.js
+++ b/comm/mail/components/compose/content/MsgComposeCommands.js
@@ -2875,9 +2875,10 @@ function ComposeStartup(aParams) {
// Update the language in the composition fields, so we can save it
// to the draft next time.
if (gMsgCompose && gMsgCompose.compFields) {
- gMsgCompose.compFields.contentLanguage = document.documentElement.getAttribute(
- "lang"
- );
+ let lang = Services.prefs.getBoolPref("mail.mime.avoid_fingerprinting")
+ ? "en-US"
+ : document.documentElement.getAttribute("lang");
+ gMsgCompose.compFields.contentLanguage = lang;
}
}
});
--
2.24.0
......@@ -2,4 +2,5 @@ Prefer-fetched-configurations-using-SSL-over-plainte.patch
Make-use-of-non-SSL-Exchange-AutoDiscover-methods-op.patch
Add-pref-for-whether-we-accept-OAuth2-during-autocon.patch
Add-pref-for-whether-to-accept-plaintext-protocols-d.patch
Avoid-local-timestamp-disclosure-in-Date-header.patch
\ No newline at end of file
Avoid-local-timestamp-disclosure-in-Date-header.patch
Avoid-spellchecking-language-disclosure-in-Content-Language-header.patch
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment