Re: [xmpp] [Standards] XMPP stanza encryption + EXI compression

"Matt Miller (mamille2)" <mamille2@cisco.com> Tue, 19 March 2013 15:34 UTC

Return-Path: <mamille2@cisco.com>
X-Original-To: xmpp@ietfa.amsl.com
Delivered-To: xmpp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 5083921F84AD for <xmpp@ietfa.amsl.com>; Tue, 19 Mar 2013 08:34:04 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -10.599
X-Spam-Level:
X-Spam-Status: No, score=-10.599 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, RCVD_IN_DNSWL_HI=-8]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id esJKGjLs1nsU for <xmpp@ietfa.amsl.com>; Tue, 19 Mar 2013 08:34:03 -0700 (PDT)
Received: from rcdn-iport-1.cisco.com (rcdn-iport-1.cisco.com [173.37.86.72]) by ietfa.amsl.com (Postfix) with ESMTP id 35A5821F84A9 for <xmpp@ietf.org>; Tue, 19 Mar 2013 08:34:03 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=7339; q=dns/txt; s=iport; t=1363707243; x=1364916843; h=from:to:subject:date:message-id:references:in-reply-to: mime-version; bh=hRkux0Ahh+11IdCcxCsMqRwaR+W1wcQ+LiZjj+XbwIQ=; b=TiiCm6eZgr521tpueGuXcB9edJ3A6mTrmiMZLxFJjAE0hMW/KhQaZFjp 3k5V/hWPu5U4piHqRC1zziYR969eHC8gf7VEa8C4NzM1GdODSV5fTKsmP V47aK/RHbgoQr0A5afkaNRXYMkNH0Gq2DsSPBw3+siDWAk9Cow2cXPVQD c=;
X-Files: smime.p7s : 2283
X-IronPort-Anti-Spam-Filtered: true
X-IronPort-Anti-Spam-Result: AgEFANKDSFGtJV2Y/2dsb2JhbABDxRCBVxZ0giQBAQEDAWwHAwgHBAIBCBEBAwEBAQoLEgcCMBQDBggBAQQBEggGiAAGDLIikB2NWIEFBiASAgICBIJVYQOPPIEohxqPY4MKgWo+
X-IronPort-AV: E=Sophos; i="4.84,872,1355097600"; d="p7s'?scan'208"; a="188898637"
Received: from rcdn-core-1.cisco.com ([173.37.93.152]) by rcdn-iport-1.cisco.com with ESMTP; 19 Mar 2013 15:34:01 +0000
Received: from xhc-rcd-x07.cisco.com (xhc-rcd-x07.cisco.com [173.37.183.81]) by rcdn-core-1.cisco.com (8.14.5/8.14.5) with ESMTP id r2JFY1fb010366 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=FAIL); Tue, 19 Mar 2013 15:34:01 GMT
Received: from xmb-aln-x11.cisco.com ([169.254.6.203]) by xhc-rcd-x07.cisco.com ([173.37.183.81]) with mapi id 14.02.0318.004; Tue, 19 Mar 2013 10:34:01 -0500
From: "Matt Miller (mamille2)" <mamille2@cisco.com>
To: XMPP Standards <standards@xmpp.org>, Stephen Williams <sdw@lig.net>, "public-exi@w3.org" <public-exi@w3.org>, "mact-usa@att.net" <mact-usa@att.net>, FABLET Youenn <Youenn.Fablet@crf.canon.fr>, "<xmpp@ietf.org> Group" <xmpp@ietf.org>
Thread-Topic: [Standards] XMPP stanza encryption + EXI compression
Thread-Index: Ac4gyBcvMCCuPnNJTUmrNa7AuYQtYAEGP56A
Date: Tue, 19 Mar 2013 15:34:00 +0000
Message-ID: <BF7E36B9C495A6468E8EC573603ED9411517BED0@xmb-aln-x11.cisco.com>
References: <1693EFE1FD641C42A0D542FCBC732DE698E53473@EX3.YODA.UTOPIA.LOCAL>
In-Reply-To: <1693EFE1FD641C42A0D542FCBC732DE698E53473@EX3.YODA.UTOPIA.LOCAL>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach: yes
X-MS-TNEF-Correlator:
x-originating-ip: [10.129.24.61]
Content-Type: multipart/signed; boundary="Apple-Mail=_3A270713-E142-4B2C-8384-550CCB459D78"; protocol="application/pkcs7-signature"; micalg="sha1"
MIME-Version: 1.0
Subject: Re: [xmpp] [Standards] XMPP stanza encryption + EXI compression
X-BeenThere: xmpp@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: XMPP Working Group <xmpp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/xmpp>, <mailto:xmpp-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/xmpp>
List-Post: <mailto:xmpp@ietf.org>
List-Help: <mailto:xmpp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/xmpp>, <mailto:xmpp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 19 Mar 2013 15:34:04 -0000

I'm not well versed enough in EXI to know if there are special considerations for purely binary data, and I'm not sure what changes I can make to a specification that is focused on what RFCs 6120 and 6121 define.

However, encrypted data is a very big blob of binary that, by its very nature of appearing to be random, is extremely unlike to compress at all.  To gain any benefit, you'd want to compress *before* encrypting.


- m&m

Matt Miller < mamille2@cisco.com >
Cisco Systems, Inc.

On Mar 14, 2013, at 9:25 AM, Peter Waher <Peter.Waher@clayster.com> wrote:

> Dear Matt
> 
> I just became aware of your  IETF draft for XMPP end-to-end encryption. It looks very promising.
> http://tools.ietf.org/html/draft-miller-xmpp-e2e-05
> 
> We work with sensor network architecture over XMPP, and some (but not all) applications require end-to-end encryption, so we want to look at this extension.
> 
> At the same time, compression is a vital issue, since many sensors have limited memory. Therefore, we are working with an effort to include the use of EXI in XMPP. (See attached documents.) One important aspect to know, when including EXI into XMPP, is that packets cannot be binary copied when the server relays the information. The packets have to be decompressed, and re-compressed if both peers have EXI-compressed channels. This requires EXI to be applied after any message encryption transformation: Exi1(Encrypt(Xml)). Server then relays Exi2(DeExi1(Exi1(Encrypt(Xml)))) = Exi2(Encrypt(Xml)) to the second peer.
> 
> The problem with this is that EXI does not do very well with base64-encoded binary data. Size(Exi(Base64(Bin))) would approximately be equal to Size(Bin). EXI would be able to cut the added length imposed by the base64 encoding, due to its limited character set.
> 
> It would be nice with an end-to-end encryption method over XMPP that would also be able to take into account EXI compression of XML stanzas.
> 
> If you have time, any comments would be appreciated,
> 
> Sincerely,
> Peter Waher
> 
> 
> -----Original Message-----
> From: Peter Saint-Andre [mailto:stpeter@stpeter.im] 
> Sent: den 14 mars 2013 11:57
> To: Peter Waher
> Cc: Joachim Lindborg (joachim.lindborg@sust.se); Matt Miller
> Subject: Re: XMPP stanza encryption
> 
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 3/14/13 10:53 AM, Peter Waher wrote:
>> Hello Peter
>> 
>> Do you participate in this work? 
>> http://tools.ietf.org/html/draft-miller-xmpp-e2e-05
> 
> Only indirectly, by chatting once in a while with Matt Miller (cc'd).
> 
> Peter
> 
> - -- 
> Peter Saint-Andre
> https://stpeter.im/
> 
> 
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG/MacGPG2 v2.0.18 (Darwin)
> Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
> 
> iQIcBAEBAgAGBQJRQeU7AAoJEOoGpJErxa2p6y8P/jHGYyu4DxkpgjIlxIyP/ROF
> KfHkaOQ9kzVqEP+fWzajYK9MW8NzaGkF8w8L43o6sXbbFxtmIIZgiUpG2G9uMg8w
> 6yBrR+JbDHTSpq9bEjrA55jKjVHAQjXUpEvT71zvpqpMa8GU4mM8oLad/ETkg0QI
> YJsfGal66rSA9ZXdr78U8C7pOIFNhgV6SdLHUq1TF9jpXghXAN7bvRtGgPJk1jea
> QN45YW//Zq9NMK0KK+MmgmK+JPsb3/MM7uFSp90FTUQY7/iF1ngjoA/3tqOiaQMW
> E8Q40DIRXjzXHiiKMTwle7Q1zLP1Jm86aJp8iScsRy0OxNSH9s5NQ7AaD5ZTl/BL
> 64oiA9dLpcc/RZf/7kWDp7D7zEHli2yJG+tO0gagJHqfOt8R/WCeJR10hrBQ76rj
> JbwBqWwJRMrY1SnqlntBfhMklC7ZzkuXMn75QtqkQlflJ//6v53AcCglZBLpIurT
> xaHHO6IUvsjOvoRov1m65HTtOb9qwepPOJ4mo78bRure2HgBKBCNZRyRZPy6s8lU
> OuXqciZjDmKxMlO/A4nGMu2OP7ZcrWo58t1p7sckbC4q4YDoVBTPvA3KlcQB1kPm
> YlIGtme+MEVHVm6LvJq+Gm5C8cvXM1nB2lmHvcEWJfcSVkT03EGRKLNZm4aWchMN
> 4s30FwvW1t9EukM+RGy6
> =EN9u
> -----END PGP SIGNATURE-----
> <xep-0000-Exi.html><xep-0000-Exi.xml><xep-0000-Exi.xsd>