Re: [Hipsec] A review of draft-ietf-hip-dex-02.txt

René Hummen <> Mon, 16 May 2016 15:50 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id C0516128B44 for <>; Mon, 16 May 2016 08:50:42 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.699
X-Spam-Status: No, score=-2.699 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id tlSZM1XOcnlE for <>; Mon, 16 May 2016 08:50:32 -0700 (PDT)
Received: from ( [IPv6:2607:f8b0:4002:c05::235]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 1F0BC12B074 for <>; Mon, 16 May 2016 08:50:32 -0700 (PDT)
Received: by with SMTP id g133so165645579ywb.2 for <>; Mon, 16 May 2016 08:50:32 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc; bh=DOlJngVcgk5ABszd0KzFbJnTF+xw3B9kSp6g2cPbWuc=; b=qLGPPAZBYRBg/X1DzEoRXyNBVGYe/g3o82gJV+7VikmN6QGuXa3GDmhrtNUuOBV824 J7PDtG3+qf7qfRC/j1dXXh+pxIospHs18Vf7A3LnRHVDNteubSDHBm5xTuwHWkZMRZxh IXYkAp2bF0jNNP6i4U1JOFIbw2sZdBOxRHZ4g8aHyxUhyHnyKqwfFiCJcmEfsxYsiHFl SxZlsPBweW5Fu9L3V1rzf1R/zkghqwzFvyym4g744U8eVLC+PiwLBQZV7vRegFFbkEqw UJ/w2PLDrWdzDOAl8sWfBfHIxb+LIL7A+Zy2K8ImEYvITx56y9NY82EL57Ej5JpZ4k6Z Ah1w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc; bh=DOlJngVcgk5ABszd0KzFbJnTF+xw3B9kSp6g2cPbWuc=; b=eBCtCQ46KnHPs3vtVT5/GZqfWHVLVb1PR7N77FuT6Gmh6rLVuMgveHDAtoCaMNbHmQ X0sBdIOCJ0N4V9WqxhbmnFiCKE/mwGZKH0uFr3eRmHFhbwKNEZcFiGbZgrLU074ym+fs Yt4rCQmCS94qN5JbQf9gi9H7Ta+dTtKcuvTV4RvtxlGBuzJ9bJNirxDbRWc95eJQcx0E TAPlNk61Xt/3CWmB8zPpLqBST28xO61eOYcrDb8drBo+G1++nmqr20lwWjH+MWYmBuJK sRvxy7gNErEmueB7MmENE/J0KEHunzFan40OYbi2NKJQDtMUjeO+QvsuQI0z4dzc4xmP +APg==
X-Gm-Message-State: AOPr4FX/R1UozffXtm4W8/P4gazhxOh8WMlcmvYErY4y7zEtB+kwi69L5WiL4z4sKgs9K3S5fPeYVVwnFdhHgA==
MIME-Version: 1.0
X-Received: by with SMTP id i188mr13959236ywd.207.1463413831423; Mon, 16 May 2016 08:50:31 -0700 (PDT)
Received: by with HTTP; Mon, 16 May 2016 08:50:31 -0700 (PDT)
In-Reply-To: <>
References: <> <>
Date: Mon, 16 May 2016 17:50:31 +0200
X-Google-Sender-Auth: CtktuQ5_XQMugaGX33iVgppNPnA
Message-ID: <>
From: René Hummen <>
To: Miika Komu <>
Content-Type: multipart/alternative; boundary="001a114d6f7494ea1d0532f7954d"
Archived-At: <>
Subject: Re: [Hipsec] A review of draft-ietf-hip-dex-02.txt
X-Mailman-Version: 2.1.17
Precedence: list
List-Id: "This is the official IETF Mailing List for the HIP Working Group." <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Mon, 16 May 2016 15:57:46 -0000

Hi Miika, all,

thanks for reviewing the draft!

In this email I address the first part of your comments. I will send
another email concerning the remaining comments by the end of the month

On Mon, Mar 28, 2016 at 10:05 PM, Miika Komu <>

> Hi,
> > 1.1.  The HIP Diet EXchange (DEX)
> > Data packets start to flow after the 4th packet.  The 3rd and 4th HIP
> > packets may carry data payload in the future.  However, the details
> > of this may be defined later.
> Similarly as in RFC7401, data packets start to flow...
> (I guess you could also mention RFC6078 as another further work item)

Changed. I didn't include RFC6078 as it appears to rely on signatures.

> > An existing HIP association can be updated with the update mechanism
> > defined in [RFC7401].  Likewise, the association can be torn down
> > with the defined closing mechanism for HIPv2 if it is no longer
> > needed.  HIP DEX thereby omits the HIP_SIGNATURE parameters of the
> > original HIPv2 specification.
> Why "thereby"? I don't see the connection.

Changed to "in doing so"

> > HIP DEX does not have the option to encrypt the Host Identity of the
> > Initiator in the 3rd packet.  The Responder's Host Identity also is
> > not protected.  Thus, contrary to HIPv2, there is no attempt at
> > anonymity.
> The anonymous bit still exists, so I suggest changing the wording:
> there is no attempt at anonymity -> such Responder anonymity is not
> preserved in HIP DEX.
The statement refers to both Initiator and Responder. I changed the
sentence as follows:
"Thus, contrary to HIPv2, HIP DEX does not provide for end-point anonymity
and any signaling that indicates such anonymity should be ignored."

> > 2.1.  Requirements Terminology
> In section 6.3, you are introduce also -> notation, which was
> not explained.

I didn't think an explanation of this formal notation was necessary as it
is also not further described, e.g., in RFC5869. What would you like me to
write here?

> > 2.3.  Definitions
> I suggest to add also the definitions of both MAC and CMAC because they
> are used throughout the document. They are also used in this section.
Thanks! We never really said what we meant by CMAC. I now added the
following definition:
"   CMAC:  The Cipher-based Message Authentication Code with the 128-bit
      Advanced Encryption Standard (AES) defined in RFC 4493 [RFC4493]."

I addressed the comment about the MAC by noting the abbreviation on first
use: "Still, note that CMAC is a message authentication code (MAC) ..."

> > 3.1.  Host Identity Tag (HIT)
> Just thinking aloud... should a DEX HIT have a different context ID?
> Probably not.

We decided against this as HIP DEX is a variant of HIPv2 and as such should
live in the same context.

> > 4.1.  Creating a HIP Association
> > The HIP Diet EXchange serves to manage the establishment of state
> > between an Initiator and a Responder.  The first packet, I1,
> > initiates the exchange, and the last three packets, R1, I2, and R2,
> > constitute an authenticated Diffie-Hellman [DH76] key exchange for
> > the Master Key SA generation.  This Master Key SA is used by the
> > Initiator and the Responder to wrap secret keying material in the I2
> > and R2 packets.  Based on the exchanged keying material, the peers
> > then derive a Pair-wise Key SA if cryptographic keys are needed,
> > e.g., for ESP-based protection of user data.
> (Suggest replacing "user data" with e.g. "data plane" in the entire
> document since you're talking about machines (sensors) that may not
> have a user)

If you don't object, I would prefer to keep it the way it is right now in
order stay in line with HIPv2.

> > In the I2 packet, the Initiator MUST display the solution to the
> > received puzzle.  Without a correct solution, the I2 packet is
> > discarded.  The I2 also contains a key wrap parameter that carries a
> > secret keying material of the Initiator.  This keying material is
> > only half the final session key.  The packet is authenticated by the
> > sender (Initiator) via a MAC.
> ...half *of* the...


> > The R2 packet acknowledges the receipt of the I2 packet and completes
> > the handshake.  The R2 contains a key wrap parameter that carries the
> > rest of the keying material of the Responder.  The packet is
> > authenticated by the sender (Responder) via a MAC.
> key wrap parameter -> parameter with encrypted contents

"Parameter with encrypted contents" is more generic than what key wrap
parameter (encrypted parameter with secret keying material) indicates. I
kept it as is.

> > 4.1.1.  HIP Puzzle Mechanism
> >
> > The puzzle mechanism enables a Responder to immediately reject an I2
> > packet if it does not contain a valid puzzle solution.  To verify the
> > puzzle solution, the Responder only has to compute a single CMAC
> > operation.  After a successful puzzle verification, the Responder can
> > securely create session-specific state and perform CPU-intensive
> > operations such as a Diffie-Hellman key generation.  By varying the
> > difficulty of the puzzle, the Responder can frustrate CPU or memory
> > targeted DoS attacks.
> ...can frustrate *an Initiator*...

I did not change the text as it is a straight copy/paste from RFC7401.
Moreover, "Initiator" would indicate to me that the adversary must be a
protocol-compliant entity. So, I would prefer keep this more general
statement here.

> > Conceptually, the puzzle mechanism in HIP DEX is the same as in
> > HIPv2.  Hence, this document refers to Sections 4.1.1 and 4.1.2 in
> > [RFC7401] for more detailed information about the employed mechanism.
> > Notably, the only difference between the puzzle mechanism in HIP DEX
> > and HIPv2 is that HIP DEX uses CMAC instead of a hash function for
> > solving and verifying a puzzle.  The implications of this change on
> > the puzzle implementation are discussed in Section 6.1.
> The other difference is mentioned in section 6.1:
> "The only exceptions are that HIP DEX does not use pre-computation of
> R1 packets and that RHASH is set to CMAC.  As a result, the pre-
> computation step in in Section 6.3 of [RFC7401] is skipped in HIP DEX."

True. I added the pre-computation bit here as well.

> >  HIP DEX Retransmission Mechanism
> > The potentially high processing time of an I2 packet at a (resource-
> > constrained) Responder may cause premature retransmissions if the
> > time required for I2 transmission and processing exceeds the RTT-
> > based retransmission timeout.  Thus, the Initiator should also take
> > the processing time of the I2 packet at the Responder into account
> > for retransmission purposes.  To this end, the Responder MAY notify
> > the Initiator about the anticipated delay once the puzzle solution
> > was successfully verified and if the remaining I2 packet processing
> > incurs a high processing delay.  The Responder MAY therefore send a
> > NOTIFY packet (see Section 5.3.6. in [RFC7401]) to the Initiator
> > before the Responder commences the ECDH operation.  The NOTIFY packet
> > serves as an acknowledgement for the I2 packet and consists of a
> > NOTIFICATION parameter with Notify Message Type I2_ACKNOWLEDGEMENT
> > (see Section 5.2.19. in [RFC7401]).  The NOTIFICATION parameter
> > contains the anticipated remaining processing time for the I2 packet
> > in milliseconds as two-octet Notification Data.  This processing time
> > can, e.g., be estimated by measuring the computation time of the ECDH
> > key derivation operation at Responder boot-up.  After the I2
> > processing has finished, the Responder sends the regular R2 packet.
> ( boot-up -> start-up procedures (it doesn't have to be a boot) )


> >  Simplified HIP State Diagram
> > The following diagram shows the major state transitions.  Transitions
> > based on received packets implicitly assume that the packets are
> > successfully authenticated or processed.
> Is the new NOTIFY illustrated also in the figure?