Re: [Cfrg] [T2TRG] Wi-Fi Alliance Device Provisioning Protocol (DPP) - Draft Released for Public Review and Comments

Andy Lutomirski <luto@amacapital.net> Thu, 01 September 2016 01:33 UTC

Return-Path: <luto@amacapital.net>
X-Original-To: cfrg@ietfa.amsl.com
Delivered-To: cfrg@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 5362F12D513 for <cfrg@ietfa.amsl.com>; Wed, 31 Aug 2016 18:33:10 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.9
X-Spam-Level:
X-Spam-Status: No, score=-1.9 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=amacapital-net.20150623.gappssmtp.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 Rcm4JpcrDFqT for <cfrg@ietfa.amsl.com>; Wed, 31 Aug 2016 18:33:08 -0700 (PDT)
Received: from mail-ua0-x236.google.com (mail-ua0-x236.google.com [IPv6:2607:f8b0:400c:c08::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 21F8B12B03A for <cfrg@irtf.org>; Wed, 31 Aug 2016 18:33:08 -0700 (PDT)
Received: by mail-ua0-x236.google.com with SMTP id m60so120020093uam.3 for <cfrg@irtf.org>; Wed, 31 Aug 2016 18:33:08 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amacapital-net.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=ii2E7r3mP+yjsI0z3Qf3gPG/qCXlKux9ODwXf1F9ZyU=; b=Q1gLIvyDZ/0/JBzwhLpx17YeKHEmgkJreq79YEkwEkJyEmu6ehmBVR/GWZD84gBS+q GXO88U+P4heLhdlAR/I/T8EQ91/b36a49SmW9zTDnYIXSiYj36UF1vE6f17OX1mLkfgF bU2v9cr1P9VEFV4HwuW0KH7sfvSch087qScqNkchEBdB/gF53WerWMtpeiWgpJtPN0+x VK2wORflQaMQP1PiqBcoBApJ6dcw52A1HnpJ0L0WjlkSkyzTyUdloucauR8lVetBWYXr 6d2ypKQ+vtz7lC1rkQHU6Z8z5OFWATQV8Cu7v4DAI3huv+D8CsWo275d9RKOyp2Rq+H7 cOQQ==
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=ii2E7r3mP+yjsI0z3Qf3gPG/qCXlKux9ODwXf1F9ZyU=; b=NOxRSOF04Hl6RRboBzS0n9L6D0WgdzERWVYdDJOEE+MY8yt8js/wzRzNn5zY2YWDkp rRHnDn/REc5PIz1TH6u+Gbn201iidvi4FDYTQcKh1Df4cx5g2jIa650QVdw63DrPVMFB PU6C/WZbdzaenP6EMnAEYYMdkPybKds5zHnvJ6GZ6PpdMIAE4yDt1GZPmCf1znpFz2VT OGMoz8COINnVVM4TcA9eQbUfdHO34X4MOxX+BffKjVDx8TwiU7WY5zUBF43DgzVy5fOj UYMInxIzWunDceBW3zulEIllD9h7ze6sYXGXdEVuXFVP5ugv8/aW5mR8eynksQeCZEpV g5Dw==
X-Gm-Message-State: AE9vXwNqgxvVlJLIJKXGJfNsUAQKZBkLI8FAwnMEUQxl0Tk3FRRm+cpBQYrQ7a6+0Kkq++GUYTcR0ZCHDBC6X1z4
X-Received: by 10.176.3.203 with SMTP id 69mr6003754uau.9.1472693587094; Wed, 31 Aug 2016 18:33:07 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.103.76.146 with HTTP; Wed, 31 Aug 2016 18:33:05 -0700 (PDT)
Received: by 10.103.76.146 with HTTP; Wed, 31 Aug 2016 18:33:05 -0700 (PDT)
In-Reply-To: <2738f67f-b37b-c538-8a72-e0b452f32cb1@lounge.org>
References: <D3ECA739.9C587%paul@marvell.com> <CALCETrWV5ASUvFCnQDVwL8ULCBeWPoCq45zNFdYhg-n7YeHFYw@mail.gmail.com> <2738f67f-b37b-c538-8a72-e0b452f32cb1@lounge.org>
From: Andy Lutomirski <luto@amacapital.net>
Date: Wed, 31 Aug 2016 18:33:05 -0700
Message-ID: <CALCETrV1Cxy=eRNRyZzTPYUAysQ094wGKwTcSmGzOU1=0Ur3AA@mail.gmail.com>
To: Dan Harkins <dharkins@lounge.org>
Content-Type: multipart/alternative; boundary="001a114d7d941f460e053b6832b5"
Archived-At: <https://mailarchive.ietf.org/arch/msg/cfrg/4LGgaTRIoUwM5Dx_k8R6opzkKC4>
Cc: cfrg@irtf.org, t2trg@irtf.org, "adrian.p.stephens@ieee.org" <adrian.p.stephens@ieee.org>, "lear@cisco.com" <lear@cisco.com>
Subject: Re: [Cfrg] [T2TRG] Wi-Fi Alliance Device Provisioning Protocol (DPP) - Draft Released for Public Review and Comments
X-BeenThere: cfrg@irtf.org
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: Crypto Forum Research Group <cfrg.irtf.org>
List-Unsubscribe: <https://www.irtf.org/mailman/options/cfrg>, <mailto:cfrg-request@irtf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/cfrg/>
List-Post: <mailto:cfrg@irtf.org>
List-Help: <mailto:cfrg-request@irtf.org?subject=help>
List-Subscribe: <https://www.irtf.org/mailman/listinfo/cfrg>, <mailto:cfrg-request@irtf.org?subject=subscribe>
X-List-Received-Date: Thu, 01 Sep 2016 01:33:11 -0000

On Aug 31, 2016 5:53 PM, "Dan Harkins" <dharkins@lounge.org> wrote:
>
>
> On 8/31/16 5:14 PM, Andy Lutomirski wrote:
>>
>> On Aug 31, 2016 4:55 PM, "Paul Lambert" <paul@marvell.com> wrote:
>> >
>> >
>> > I¹ve made a short summary of the PKEX protocol below. Comments and
>> > corrections would be appreciated.
>> >
>> > Assuming my summary is correct ...
>> >
>> > If a third party Carol with P_c knows the MAC address and public key of
>> > Alice (MAC_a and P_a) a MiTM attack is possible.
>> >
>> > 1) Alice and Bob share a one-time passphrase to bootstrap connectivity
and
>> > learn each others associated public keys.
>> > 2) Alice
>> >    - calculates Pwe_ab = huntandpeck(passphrase_ab)   # passphrase
between
>> > Alice and Bob
>> >    - calculates Q_a = H( MAC_a ) * Pwe_a
>> >    - sends Commit with nonce_a and C_a = P_a + Q_a
>> > 3) Carol intercepts Alice¹s Commit and having met Alice, know¹s P_a and
>> > MAC_a
>> >    - calculates  Q_a = (C_a - P_a)
>> >    - creates spoofed commit as
>> >       C¹_a = P_c + Q_a
>> >    - send spoofed commit with nonce_c and C¹_a
>> > 4) Carol continues PKEX exchange with Bob using MAC_a
>> > 5) At end Bob thinks P_c belongs to MAC_a
>> >
>>
>> Nifty!  IMO that's a rather serious problem -- no brute forcing is
needed.
>>
>> I can improve my quadratic attack, too.  Suppose Carol can convince
Alice to run the protocol twice with different passwords pw1 and pw2.  (The
two runs don't even need to be with the same peer.)  Carol learns Q1_a -
Q2_a.  With high probability, Carol can now jointly bruteforce pw1 and pw2
without needing to know P_a.  Now Carol can calculate P_a.
>>
>> Of course, having done so, Carol can now run your attack to MITM any
further exchanges involving Alice.
>>
>> So I guess that passive observation of two protocol runs almost
completely breaks PKEX.
>
>
>   What you both seem to have noticed is what is already mentioned in the
DPP spec
> that you both have quite obviously read. Namely,
>
>   "This bootstrapping technique [PKEX] should never be run multiple times
with
> the  same code. Using this bootstrapping technique more than once with a
different
> code but the same bootstrapping key can enable a dictionary attack."
>
>   There are usage constraints. Go beyond them and your assumptions are not
> valid anymore.

Then perhaps the design should change to something that doesn't have these
constraints.  This wouldn't be particularly difficult.

I, for one, find it implausible that any real implementation will above by
the constraints.  And I still think it's broken even if you do abide by the
constraints due to the existence of oracles that can test a bootstrapping
public key