Re: [ietf-dkim] [dmarc-ietf] a slightly less kludge alternative to draft-kucherawy-dmarc-rcpts

"Murray S. Kucherawy" <superuser@gmail.com> Fri, 18 November 2016 21:55 UTC

Return-Path: <ietf-dkim-bounces@mipassoc.org>
X-Original-To: ietfarch-ietf-dkim-archive@ietfa.amsl.com
Delivered-To: ietfarch-ietf-dkim-archive@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 47BC91294D0 for <ietfarch-ietf-dkim-archive@ietfa.amsl.com>; Fri, 18 Nov 2016 13:55:02 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.089
X-Spam-Level:
X-Spam-Status: No, score=-1.089 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_ADSP_CUSTOM_MED=0.001, DKIM_SIGNED=0.1, FREEMAIL_FORGED_FROMDOMAIN=0.199, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.001, HTML_MESSAGE=0.001, RCVD_IN_SORBS_SPAM=0.5, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_DKIM_INVALID=0.01] autolearn=no autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=fail (2048-bit key) reason="fail (body has been altered)" header.d=gmail.com
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 Zsx38sc-qrHW for <ietfarch-ietf-dkim-archive@ietfa.amsl.com>; Fri, 18 Nov 2016 13:55:00 -0800 (PST)
Received: from simon.songbird.com (simon.songbird.com [72.52.113.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 9A375129490 for <ietf-dkim-archive@ietf.org>; Fri, 18 Nov 2016 13:55:00 -0800 (PST)
Received: from simon.songbird.com (simon.songbird.com [127.0.0.1]) by simon.songbird.com (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id uAILsgTa029412; Fri, 18 Nov 2016 13:54:48 -0800
Authentication-Results: simon.songbird.com; dkim=fail reason="verification failed; unprotected key" header.d=gmail.com header.i=@gmail.com header.b=C4GQrMBQ; dkim-adsp=none (unprotected policy); dkim-atps=neutral
Received: from mail-yw0-f181.google.com (mail-yw0-f181.google.com [209.85.161.181]) by simon.songbird.com (8.14.4/8.14.4/Debian-4.1ubuntu1) with ESMTP id uAILscGQ029408 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT) for <ietf-dkim@mipassoc.org>; Fri, 18 Nov 2016 13:54:39 -0800
Received: by mail-yw0-f181.google.com with SMTP id r204so172845394ywb.0 for <ietf-dkim@mipassoc.org>; Fri, 18 Nov 2016 13:53:42 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=4NtRg95rCfPpqcP+WhgRiadB6oWOSH5+3uhaVrP94h8=; b=C4GQrMBQ0A/Zg2TdIsBrIUuz06rchUkMJp186rk0j1VPmiJrDSMQFAzz2SnfyL0NSH GHVsZ4OM1McGoD0KW+eMLDanVxqnJxC8P7gBLwcN7VfAv7pPy/eQbilqEzQYJloKfInU LlCHAGSZIB4JCMnniGEQRT08gvLh8BA0PjpXSq1mj4Sy1K7wzgALGSnu7wzpE8wzTUJe rsgzH6AJLvolJ8Es4iNhuals1Arl91zuWwjCBo2GCc3cmiZeeDePdwXrOwMSRgJsCZEy LLAyX7ubzLiCUIYGjnMhC6YORgYqVbLk6DxeD6JD99JySDWTCkSh7pAA2tTZKAbr+Krm QHyQ==
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:from:date :message-id:subject:to:cc; bh=4NtRg95rCfPpqcP+WhgRiadB6oWOSH5+3uhaVrP94h8=; b=MiA1h6VEssRY7nsWFx//KQUR7Xa1vWqQHb3tI5mGiRfX40u68gdWsvxT2nj25JUO59 LMtF7jroXt0c5RJUZBTGQp2CrErBHy+mOgOO5CvGlEPF9LJ1Khm6qo5z5QaegdSDvYrr 07GzAab+o4eM+S+bs34I+ksh5s7tXo4itqcHxZYOlXUXEKB4SvjsmB9QNB6JlOJ6cMB2 LkTXBzriUkqrmyttNbjGcqgQVDLYI3dw/ICfBA1DpYd7mLy0SHXz1cAfu7s2L+jnAPbG DaIHdpvQeEDjycabt+XXXbCnanO1QGsHR7M4Npgt9p0u5ozCC/NqTyWd0y1t+F4N+xQE zViA==
X-Gm-Message-State: AKaTC03LgDrqTQcD9KdvWJcalm9V8PSChEvv7yix/9Ou6I9XtVYVeLntfOwlsOS8i8447cOn0ZYT7PVGpVo9vQ==
X-Received: by 10.129.51.82 with SMTP id z79mr1870237ywz.74.1479506015524; Fri, 18 Nov 2016 13:53:35 -0800 (PST)
MIME-Version: 1.0
Received: by 10.37.111.130 with HTTP; Fri, 18 Nov 2016 13:53:34 -0800 (PST)
In-Reply-To: <b92d042d6be905ffd4bc43ea510571c2@xmail.mwn.de>
References: <alpine.OSX.2.11.1611142158000.21738@ary.local> <01Q7ASDZFS6C011WUX@mauve.mrochek.com> <CAL0qLwazAg2UJvGAr+nx8R_xEbc4xV0ttPEWFKUD69u6xXaMhA@mail.gmail.com> <CAL0qLwaMzy=qeW5XYZ_txPaiYE27Oof+C5V1uRANvv-_cayOcQ@mail.gmail.com> <CY1PR00MB0107389F8FE73F140849A19996BE0@CY1PR00MB0107.namprd00.prod.outlook.com> <2736ea21-69e6-83b1-3b59-377c032290b5@dcrocker.net> <CY1PR00MB01072F4EB32969888104C45196BE0@CY1PR00MB0107.namprd00.prod.outlook.com> <CAL0qLwbdNVwT-xiCmxyhSqKcp4-hCA1COHKh0wdYrYEekzZ=XA@mail.gmail.com> <3009defcc6dc9043823618dbc338460d@xmail.mwn.de> <CAL0qLwbvqABZGsm2Hp20y8wgvQTKvPn+EBKiS37eMrp+9NemjA@mail.gmail.com> <da2e49df90980fe460d1effd7734ef42@xmail.mwn.de> <CAL0qLwbA6Vjqpi5hGOtbpLV9FwgDO3VVA=Q5GgAU9F0qOsQCNQ@mail.gmail.com> <63a2bfc52a81eb569a0af5e1699390d9@xmail.mwn.de> <CAL0qLwZ42=GFDRm7H0qQ_7bczY8CPQaEuSUfgFEbO_Y5+5YvqA@mail.gmail.com> <b92d042d6be905ffd4bc43ea510571c2@xmail.mwn.de>
From: "Murray S. Kucherawy" <superuser@gmail.com>
Date: Fri, 18 Nov 2016 13:53:34 -0800
Message-ID: <CAL0qLwb4SDWk0K+iLppnA5L66dac1s4JjEUwF5-Te2ba+JkHCg@mail.gmail.com>
To: Michael Storz <Michael.Storz@lrz.de>
Cc: Ietf Dkim <ietf-dkim@mipassoc.org>
Subject: Re: [ietf-dkim] [dmarc-ietf] a slightly less kludge alternative to draft-kucherawy-dmarc-rcpts
X-BeenThere: ietf-dkim@mipassoc.org
X-Mailman-Version: 2.1.16
Precedence: list
List-Id: IETF DKIM Discussion List <ietf-dkim.mipassoc.org>
List-Unsubscribe: <http://mipassoc.org/mailman/options/ietf-dkim>, <mailto:ietf-dkim-request@mipassoc.org?subject=unsubscribe>
List-Archive: <http://mipassoc.org/pipermail/ietf-dkim/>
List-Post: <mailto:ietf-dkim@mipassoc.org>
List-Help: <mailto:ietf-dkim-request@mipassoc.org?subject=help>
List-Subscribe: <http://mipassoc.org/mailman/listinfo/ietf-dkim>, <mailto:ietf-dkim-request@mipassoc.org?subject=subscribe>
Content-Type: multipart/mixed; boundary="===============5501569578272584130=="
Errors-To: ietf-dkim-bounces@mipassoc.org
Sender: ietf-dkim <ietf-dkim-bounces@mipassoc.org>

On Fri, Nov 18, 2016 at 3:47 AM, Michael Storz <Michael.Storz@lrz.de> wrote:

> Normal DKIM-Signatures give us a way to check if the body and/or header of
> an email has been changed on the way from the signer to the verifier. The
> new extension extends this to the recipients of the email. A change means
> the email was either relayed (now indirect mail) or replayed. I think this
> is a new valuable information for an anti-spam-system. However, we have not
> discussed how this gets propagated from the verifier to the consumer of the
> information.
>

That's certainly possible to do if it's useful.  The pseudo-API described
by RFC6376 is vague; it just says the signature has to fail.  Whatever
reporting mechanism you want to provide in an actual implementation is fine
as long as it complies just to that.  A specific error code, or sub-code (a
la enhanced status codes) is certainly a valid choice.  OpenDKIM has a
large number of them.


> The negative side of the proposal is the requirement to split all
> multi-recipient-emails to single-recipient-emails, which is a show stopper
> for me.


That's curious; why?


> But I don't think this requirement is needed. I would allow a list of
> recipients and have a paragraph which states:


> ===
> Every compliant implementation of this extension MUST check if the signing
> of the message as is would result in the leakage of hidden BCC recipients.
> The check has to be done in the following way:
>
> - Collect the set of visible recipients from the header fields
>
>   * From
>   * Sender
>   * Reply-To
>   * To
>   * CC
>   * Resent-From
>   * Resent-Sender
>   * Resent-To
>   * Resent-CC
>
> - For each address from the set of envelope recipients check if the
> address is included in the set of visible recipients.
>
>   If not, then either
>
>   * refuse to sign with this extension or
>   * split the message and sign and send a single-recipient-copy of the
> message with this recipient
>

We discussed the idea of tying it directly to To and Cc.  The downside of
doing so is that participating DKIM implementations would have to know the
syntax and semantics of RFC5322 header fields; right now it needs only very
basic syntax information about them, just enough to run canonicalization.
It adds a whole lot of code complexity we'd rather avoid.  On top of that,
if someone were to later register some other sender or recipient header
field that should be included in this list, we'd have to update everything
on the DKIM side by updating this list.

Simplicity is very desirable here, as is reaching across the layer boundary
as little as possible.

===
>
> If the submission MTA already enforces the handling of bcc recipients as
> described in https://tools.ietf.org/search/rfc5322#section-3.6.3 the
> signing can always be done.
>

This sort of thing might work if you also specify the way both ends will
process this symmetrically.  Any ambiguity will result in interoperability
problems.


> Depending on an underlying policy from the administrator the "refuse to
> sign with this extension" could mean
>
> - to sign without the extension
> - wave the message through without signing
> - to reject the message with an error like "Configuration error: DKIM
> signing this message would leak BCC recipients"
>

These are purely implementation policy choices.  At best a specification
like this one would lay them out as options in a non-normative way.


> This check and the resulting split action is RFC 5322 compliant. However
> it would need to use the second variant of the bcc handling with the
> single-bcc-recipient-email.
>
> In this multi-recipient scenario the hashing of the recipient makes sense.
> It protects against passive attacks (just looking at the header) but not
> against active attacks.
>
> How about this?


It's worth considering further if we were to become convinced that this is
a problem that needs to be solved in the form of changes to DKIM.  Right
now I think we should wait for operators to explain why going down any of
these paths is the best option.  My main worry is that it seems to invite a
lot of complexity in code and either solution would introduce a lot of
complexity into the problem space, possibly more than they really would
solve.

-MSK
_______________________________________________
NOTE WELL: This list operates according to
http://mipassoc.org/dkim/ietf-list-rules.html