Re: [apps-discuss] Kathleen Moriarty's Discuss on draft-ietf-appsawg-sieve-duplicate-07: (with DISCUSS and COMMENT)

Dave Cridland <dave@cridland.net> Tue, 24 June 2014 19:07 UTC

Return-Path: <dave@cridland.net>
X-Original-To: apps-discuss@ietfa.amsl.com
Delivered-To: apps-discuss@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 4CF601B2E88 for <apps-discuss@ietfa.amsl.com>; Tue, 24 Jun 2014 12:07:17 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 1.322
X-Spam-Level: *
X-Spam-Status: No, score=1.322 tagged_above=-999 required=5 tests=[BAYES_50=0.8, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FM_FORGED_GMAIL=0.622, HTML_MESSAGE=0.001, SPF_PASS=-0.001] autolearn=no
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 yBvNNgKZfxPa for <apps-discuss@ietfa.amsl.com>; Tue, 24 Jun 2014 12:07:14 -0700 (PDT)
Received: from mail-ob0-x232.google.com (mail-ob0-x232.google.com [IPv6:2607:f8b0:4003:c01::232]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 0998F1B285B for <apps-discuss@ietf.org>; Tue, 24 Jun 2014 12:07:13 -0700 (PDT)
Received: by mail-ob0-f178.google.com with SMTP id wn1so862681obc.37 for <apps-discuss@ietf.org>; Tue, 24 Jun 2014 12:07:13 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cridland.net; s=google; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=PByhaRqiKSKnb7p9reRuI2KE+v9HcqcQbZ0ztSasWUI=; b=GM/3HtZV88pn77TL5Qmev1CFyYp6468QTCu3kdc3WLxGD4NEvOM1uv9pkea+3rQ9dX WvP/J0htLBiu4vsRIeTGapTll+knyRYhU+jubWErM6BfJJAEJFGzl2Krx2QzZFOnRbwa WrnyGIUXCyunT8D2Jv7o518N6DGdjvDZra5nw=
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=PByhaRqiKSKnb7p9reRuI2KE+v9HcqcQbZ0ztSasWUI=; b=g1doxxNw3zJS1K04dd7WWREL0uc5Ns6qKsgzBxiegNgss/6RK3yST8YyzDyLPQH3bf BTIiTBivJUrO2D84mBu1Ai+91BawlWQBxU7t8zJP76B0tPJbIgcWmPpANawyHC84xnYo kl23DdCptTb5pJ774lCoeQ3oiTfk8n8x30sncAIFVLVK2dfuyZg91ykzFKpYT5FVOaHQ 9rHUVkTVLBLh71WFx4w6CdkNqG1pYO6/V+qO3ihOHALmvwNf5R4K6XI3ejSe6KlFR3KY OH3ky6fhamZvrLXvHPtXhz93nSrRc6+Fu5lDO1NafEnOWupQoKmaApUKKNzIikgKjpIm Cv8Q==
X-Gm-Message-State: ALoCoQlj0HhiGAVe+BpPT6l3s41euBvvg/aEvLIcnbXxI7ynIFI73zUlj6VUaxStovAMCGHTTg9Q
MIME-Version: 1.0
X-Received: by 10.60.132.171 with SMTP id ov11mr3013814oeb.46.1403636833494; Tue, 24 Jun 2014 12:07:13 -0700 (PDT)
Received: by 10.60.60.100 with HTTP; Tue, 24 Jun 2014 12:07:13 -0700 (PDT)
In-Reply-To: <01P9E1DOSSZO0049PU@mauve.mrochek.com>
References: <20140623184900.17262.22283.idtracker@ietfa.amsl.com> <53A88421.60701@rename-it.nl> <CAHbuEH458e6eLZvF6OZUirVsrSaAbPGPj7GvsgX9tXdaU2X5_w@mail.gmail.com> <CALaySJLUePy5aRnm-fcrpuxdq6j61sNpc-zKtT73C7ZTyeF3WQ@mail.gmail.com> <53A8A7C5.80102@qti.qualcomm.com> <CALaySJ+Pa76JzPWZpstrDodVt1JzUZnNrwbBuZJqkMc8rknqcw@mail.gmail.com> <300281C7-B2DE-4419-984E-02F08EE32191@gmail.com> <CALaySJJcfDurV5DSRB+D2ag-UFMWQECWoYm6_FYVarSVDZm9FQ@mail.gmail.com> <8D7155B0-BC65-43A3-BE35-CB0CA702A358@gmail.com> <53A98428.106@qti.qualcomm.com> <e99cace0-c407-4cc7-be9b-79876bd387ef@gulbrandsen.priv.no> <01P9E1DOSSZO0049PU@mauve.mrochek.com>
Date: Tue, 24 Jun 2014 20:07:13 +0100
Message-ID: <CAKHUCzwX4ugqvO-1RoRnUy_iR+4s_CXyopfwanpEwAUnFDJtmg@mail.gmail.com>
From: Dave Cridland <dave@cridland.net>
To: Ned Freed <ned.freed@mrochek.com>
Content-Type: multipart/alternative; boundary="047d7b4724f8dabeca04fc99aa32"
Archived-At: http://mailarchive.ietf.org/arch/msg/apps-discuss/k7qeMKQNeMCBnmTZPJvSx6qVOO0
Cc: "apps-discuss@ietf.org" <apps-discuss@ietf.org>
Subject: Re: [apps-discuss] Kathleen Moriarty's Discuss on draft-ietf-appsawg-sieve-duplicate-07: (with DISCUSS and COMMENT)
X-BeenThere: apps-discuss@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: General discussion of application-layer protocols <apps-discuss.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/apps-discuss/>
List-Post: <mailto:apps-discuss@ietf.org>
List-Help: <mailto:apps-discuss-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/apps-discuss>, <mailto:apps-discuss-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 24 Jun 2014 19:07:17 -0000

I've got to agree with this. I was going to craft a sufficiently sarcastic
further suggestion of some ridiculously contrived security flaw we had to
document to underline this point, but I couldn't actually think of anything
more contrived than the potential flaw of someone phishing by
pre-overwriting an email that ... I mean, really. Even if it occurred, the
end users writing these scripts are not the audience of this RFC, and
wouldn't notice the advice.

I'm sorry to say that the discussion smacks of security bikeshedding.

Yes, it's possible to write Sieve scripts which can expose you to security
flaws - much worse cases than this. It's also possible to publish your
password on Twitter, yet the HTTPbis RFCs do not, to the best of my
knowledge, warn about this in their Security Considerations. This isn't a
matter of whether or not that might form good advice - I happen to hold the
opinion that publishing your password on Twitter is almost certainly a bad
idea - but whether the people likely to do so read RFCs.


On 24 June 2014 16:04, Ned Freed <ned.freed@mrochek.com> wrote:

> On Tuesday, June 24, 2014 3:59:04 PM CEST, Pete Resnick wrote:
>> > So, your call. Maybe worth adding something. But there needn't
>> > be any grand warnings of impending horror.
>>
>
>  +1
>>
>
>  If you want to DoS someone into not receiving a particular message, then
>> surely there are easier ways than predicting the message-id exactly. You
>> could spam five hundred nearby users with a hundred messages each
>> containing similar text and watch the spam filter learn.
>>
>
> Exactly. And you failed to mention having to know that the recipient is
> using
> this particular extension in a particular way. Plus this attack is going to
> leave traces in the server's logs if it is successful, and if those traces
> are
> discovered it will be a giant red flag that something naughty was done. (In
> contrast, the spam training attack you describe is highly unlikely to leave
> such traces.) So to do this effectively means it would be really nice to be
> able to modify the server's logs after the fact.
>
> Taken together this means the attacker has to have intimate knowledge of -
> and
> likely access to - both the sending and receiving environment. It beggers
> belief that someone who has this won't also have access to some other, far
> more
> practial, attack.
>
> And this brings us to the more general point: It's vital that security
> considerations in this sort of document have at least some sense of
> proportion
> and context. The IESG really needs to start taking this into account in
> their
> comments and discusses.
>
> It's often the case that an assortment of fanciful and/or farfetched
> attacks
> can be constructed against systems, services, protocols, cryptographic
> primitives, and so on. (Bruce Schneier calls these things "movie plot
> attacks",
> but I don't think this is a useful characterization because it misses all
> sorts
> of things that would never fly in a script.)
>
> Now, elucidation and promulgation of attacks against cryptographic
> primitives
> makes all sorts of sense even when those attacks are wildly impractical.
> For
> one thing, these primitives are used in a wide variety of environments and
> what's impractical in one place may be practical in another. And for
> another, making it clear that the best attacks known are completely
> ineffective
> tends to build, rather than reduce, confidence in this space.
>
> But I don't think this is true when it comes to specific services and
> protocols
> that slot into specific services in specific ways. I think a lot  more
> selectivity is called for in such cases.
>
> First and foremost, these discussions cost us all a lot of time, time
> which I
> seriously question is not better spent elsewhere.
>
> Second, there's a tendency for WGs to just quietly agree to add text to
> address
> the concern that was raised in order to make it go away, which risks
> falling
> into "Boy who cried wolf!" territory.
>
> Third, when this leads to bulking up, qualifying, or convoluting what used
> to
> be clear, consise prose in the service of fanciful security concerns the
> result
> is almost always poorer than the original. (And as a person whose email
> address
> is on a lot of RFCs, and who often gets contacted when people have
> questions, I
> can assure everyone this is NOT an idle concern.)
>
> My favorite example of all this - and one in the same space as the present
> document - is something that happened between RFC 3028 and RFC 5228. This
> is a
> long, sad, story, but I want to focus on the sentence in the former RFC
> that
> says, "The language is not Turing-complete: it provides no way to write a
> loop
> or a function and variables are not provided."
>
> Given how often Sieve is extended, this criteria is actually pretty darned
> important: We do not want someone to modify the language or define an
> extension
> that on subsequent inspection provides a means to perform a DOS attack on
> an
> MDA that implements it. So designers and implementors really need to think
> about this issue.
>
> Yet this very sentence came under fire during the RFC 5228 revision.
> Someone on
> the IESG pointed out that it might be possible to use Sieve
> redirect/notify/vacation/whatever to loop a message around indefinitely,
> at
> which point you could use header tests and modification actions to
> implement a
> Turing machine. Ergo, the language is in fact Turing complete! Gotcha! That
> sentence needs to go!
>
> Except of course this would make the email *system* Turing complete, not
> the
> Sieve language. And if infinite loops are possible who cares if Sieve is
> then
> used to compute a factorial or whatever on top of the looping message?
> It's the
> loop that's the problem, not the Turing completeness you can build on top
> of
> that. (We also go to a lot of trouble in our specifications to insure that
> loops can't be created if things are implemented correctly.)
>
> But the ensuing discussion of this and several other IMNSHO equally
> ridiculous
> points cost us a lot of time, and if memory serves, conference calls were
> actually required to resolve the matter. Which had the side effect of
> sapping
> most of the remaining energy of the working group and driving off a couple
> of
> active contributers.
>
> But it sure did lead to that sentence being modified. It now says, "The
> base
> language was not designed to be Turing-complete: it does not have a loop
> control structure or functions."
>
> Was the change worth it? I think the answer is an emphatic "no", and to be
> blunt I still find the entire episode to be galling 6 years later.
>
> Returning to the matter at hand, I remain to be convinced that this is an
> issue
> that's worth addressing. What will convince me is suggested text that
> describes
> the issue in accurate and practical fashion. If such text can be
> constructed I
> have no problem seeing it added to the document.
>
> But more generally, this seems to be yet another case where we're
> attempting to
> address the newly perceived shortcoming of the core email service in a
> document
> tangential to the specification of that service. (I refrained from
> commenting
> on the privacy concern thread, but given the operational reality that all
> but
> the most security conscious servers routinely keep detailed logs of the
> metadata for every message that's sent or received for a considerable
> period,
> and we provide exactly zero guidance as to the best practices for handling
> such
> logs, I find the need to describe best practcies for handling a bunch of
> hash
> values to be a bit overblown.)
>
> And even if it were practical to craft such text - I suspect there's far
> less
> agreement on what these newly perceived shortcomings are than you might
> think - putting such material in a place where it's unlikely in the extreme
> to have
> mainstream impact is at best a waste of time.
>
>                                 Ned
>
>
> _______________________________________________
> apps-discuss mailing list
> apps-discuss@ietf.org
> https://www.ietf.org/mailman/listinfo/apps-discuss
>