Re: [openpgp] Mitigation of Attacks on Email End-to-End Encryption
Stephen Farrell <stephen.farrell@cs.tcd.ie> Tue, 03 November 2020 16:35 UTC
Return-Path: <stephen.farrell@cs.tcd.ie>
X-Original-To: openpgp@ietfa.amsl.com
Delivered-To: openpgp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id EC7153A0D9D for <openpgp@ietfa.amsl.com>; Tue, 3 Nov 2020 08:35:46 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.246
X-Spam-Level:
X-Spam-Status: No, score=-2.246 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, NICE_REPLY_A=-0.247, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=cs.tcd.ie
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FwRBIjf4DxJg for <openpgp@ietfa.amsl.com>; Tue, 3 Nov 2020 08:35:44 -0800 (PST)
Received: from mercury.scss.tcd.ie (mercury.scss.tcd.ie [134.226.56.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 7247B3A0A85 for <openpgp@ietf.org>; Tue, 3 Nov 2020 08:35:44 -0800 (PST)
Received: from localhost (localhost [127.0.0.1]) by mercury.scss.tcd.ie (Postfix) with ESMTP id B33E8BE7B; Tue, 3 Nov 2020 16:35:42 +0000 (GMT)
X-Virus-Scanned: Debian amavisd-new at scss.tcd.ie
Received: from mercury.scss.tcd.ie ([127.0.0.1]) by localhost (mercury.scss.tcd.ie [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JpEgvFP8kUSf; Tue, 3 Nov 2020 16:35:40 +0000 (GMT)
Received: from [10.244.2.119] (95-45-153-252-dynamic.agg2.phb.bdt-fng.eircom.net [95.45.153.252]) by mercury.scss.tcd.ie (Postfix) with ESMTPSA id 007B8BE79; Tue, 3 Nov 2020 16:35:39 +0000 (GMT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cs.tcd.ie; s=mail; t=1604421340; bh=9uGt3x30XDAlbSEKXE1ViUhb9hAZepGISLdAtARzUAw=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=loWDOJ/BJKT8F/uq9BbqMJ/GA3Qz8ZIw09n24/jiLFdf7IXm8XJchzWW8veauiUlV E+mD3/fjYdj1/O7U4m3SgEG9ukIH26ClQyx2FND7CPkioHHqyon6e5GcuZiNlAinZv JoUDykwiYd9WaK2Mji0cMeaUMzFVF+CzDP8dwdZM=
To: Marcus Brinkmann <marcus.brinkmann=40rub.de@dmarc.ietf.org>, openpgp@ietf.org
Cc: Jörg Schwenk <joerg.schwenk@rub.de>, Jens Müller <jens.a.mueller@rub.de>, Sebastian Schinzel <schinzel@fh-muenster.de>, Damian Poddebniak <poddebniak@fh-muenster.de>, Juraj Somorovsky <juraj.somorovsky@rub.de>
References: <80af2d9c-f646-4167-209d-5fb35c880682@rub.de>
From: Stephen Farrell <stephen.farrell@cs.tcd.ie>
Message-ID: <81da533b-094f-b16c-a71b-927441e8c18b@cs.tcd.ie>
Date: Tue, 03 Nov 2020 16:35:39 +0000
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.3.2
MIME-Version: 1.0
In-Reply-To: <80af2d9c-f646-4167-209d-5fb35c880682@rub.de>
Content-Type: multipart/signed; micalg="pgp-sha256"; protocol="application/pgp-signature"; boundary="46ajJi1DwUd4zv5SfgXXkHh30xzR7y43j"
Archived-At: <https://mailarchive.ietf.org/arch/msg/openpgp/ZmXkgnr9yVNnzHafrzPhp6dDLFU>
Subject: Re: [openpgp] Mitigation of Attacks on Email End-to-End Encryption
X-BeenThere: openpgp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Ongoing discussion of OpenPGP issues." <openpgp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/openpgp>, <mailto:openpgp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/openpgp/>
List-Post: <mailto:openpgp@ietf.org>
List-Help: <mailto:openpgp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/openpgp>, <mailto:openpgp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 03 Nov 2020 16:35:47 -0000
Hiya, Interesting work and I look forward to seeing your suggestions as we go. One thing: the DOI URL below gets me a "not found" error but indicates that may change in future. Is that correct? If so, be great if you could send a ping when the paper is available (or another URL to a preprint or whatever). Thanks, S. On 03/11/2020 16:24, Marcus Brinkmann wrote: > Hello, > > we have just published a paper on our research how to mitigate attacks > on email end-to-end encryption. The full paper is available here with > open access: > > Jörg Schwenk, Marcus Brinkmann, Damian Poddebniak, Jens Müller, Juraj > Somorovsky, and Sebastian Schinzel. 2020. Mitigation of Attacks on Email > End-to-End Encryption. In Proceedings of the 2020 ACM SIGSAC Conference > on Computer and Communications Security (CCS '20). Association for > Computing Machinery, New York, NY, USA, 1647–1664. > DOI:https://doi.org/10.1145/3372297.3417878 > > We have analyzed three attack vectors: EFAIL malleability gadgets (MG), > EFAIL direct exfiltration (DE), and REPLY attacks. > > MG attacks exploit unauthenticated block cipher modes such as CBC and > CFB, and are mitigated by using an authenticated encryption mode such as > AEAD, or by a strict implementation of OpenPGP's modification detection > code. S/MIME 4.0 and OpenPGP RFC4880bis have added AEAD encryption > modes, and assuming a strict implementation, can also protect against MG > attacks that way. (Currently, RFC4880bis does allow unsafe > implementations of AEAD, and even encourages them due to unrestricted > chunk sizes. This has been previously discussed, and I will re-raise > this issue when the WG has been reinstantiated). > > EFAIL DE attacks rely on modifications of the MIME structure to embed > authentic ciphertexts in a context that allows exfiltration of the > plaintext after decryption, for example through image source URLs in a > HTML MIME element before the ciphertext. These attacks have also been > published in the EFAIL paper, and so far were only mitigated at the > recipient side by ad-hoc measures in email clients. Our experience was > that developers were struggling to mitigate these attacks. For example, > we found several bypasses after attempts at mitigation. > > REPLY attacks are known for 20+ years: They rely on modifications of the > email header (SMTP) context, that allow the attacker to receive replies > to authentic ciphertexts, were the victim quotes the plaintext back to > the attacker. To our knowledge, these attacks have not been mitigated so > far. We have looked at reply attacks in our paper on covert content > attacks [COVERT]. > > We have looked systematically at these issues, and propose to protect > the MIME and SMTP context of an email by adding a summary of this > decryption contexts (DC) as associated data (AD) in the AEAD encryption. > This way, any significant modification to these contexts that indicate > an attack would lead to a decryption error, rather than emitting the > plaintext to the application, where it would be subject to a large > attack surface to launch DE or REPLY attacks. > > To support this mechanism, OpenPGP RFC4880bis would need to be amended > to allow applications to add arbitrary data to the AD, either directly > (length+value) or by adding a hash representation (constant length). I > plan to introduce a proposal for these changes when the WG is > reinstantiated. > > We have evaluated which SMTP headers are relevant for REPLY actions in > email clients, and which MIME contexts can be considered safe. Based on > this (and inspired by DKIM), we make a specific proposal for calculating > the decryption context which is sender-enforced and extensible. > > We have implemented this solution with GnuPG and Thunderbird/Enigmail. > It was easy to implement, offered excellent compatibility (low false > positive rate when detecting attacks) and mitigated all REPLY and DE > attacks conclusively without introducing new cryptographic primitives. > > I hope these findings are interesting to the OpenPGP community. For > example, some of the problems described in > > https://www.ietf.org/archive/id/draft-dkg-lamps-e2e-mail-guidance-00.txt > > can be mitigated using our techniques. Also, the REPLY action behavior > of email clients in our evaluation should be useful for the memory hole > project, for example. > > Thanks, > Marcus > > > Bibliography: > > [COVERT] Jens Müller, Marcus Brinkmann, Damian Poddebniak, Sebastian > Schinzel, and Jörg Schwenk. 2019. Re: What’s Up Johnny? – Covert Content > Attacks on Email End-to-End Encryption. > https://arxiv.org/ftp/arxiv/papers/1904/1904.07550.pdf. > > [EFAIL] Damian Poddebniak, Christian Dresen, Jens Müller, Fabian Ising, > Sebastian Schinzel, Simon Friedberger, Juraj Somorovsky, and Jörg > Schwenk. 2018. Efail: Breaking S/MIME and OpenPGP Email Encryption using > Exfiltration Channels. In 27th USENIX Security Symposium, USENIX > Security 2018, Baltimore, MD, USA, August 15-17, 2018., William Enck and > Adrienne Porter Felt (Eds.). USENIX Association, 549–566. > https://www.usenix.org/conference/usenixsecurity18/presentation/poddebniak >
- [openpgp] Mitigation of Attacks on Email End-to-E… Marcus Brinkmann
- Re: [openpgp] Mitigation of Attacks on Email End-… Stephen Farrell
- Re: [openpgp] Mitigation of Attacks on Email End-… Marcus Brinkmann
- Re: [openpgp] Mitigation of Attacks on Email End-… Benjamin Kaduk
- Re: [openpgp] Mitigation of Attacks on Email End-… Marcus Brinkmann
- Re: [openpgp] Mitigation of Attacks on Email End-… Benjamin Kaduk
- Re: [openpgp] Mitigation of Attacks on Email End-… Daniel Kahn Gillmor