Re: [babel] Minor clarification to HMAC

Markus Stenberg <markus.stenberg@iki.fi> Sat, 29 June 2019 10:40 UTC

Return-Path: <fingon@kapsi.fi>
X-Original-To: babel@ietfa.amsl.com
Delivered-To: babel@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id AA0401200EF for <babel@ietfa.amsl.com>; Sat, 29 Jun 2019 03:40:41 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.35
X-Spam-Level:
X-Spam-Status: No, score=-2.35 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.25, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=kapsi.fi
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 kAACdVT73--h for <babel@ietfa.amsl.com>; Sat, 29 Jun 2019 03:40:40 -0700 (PDT)
Received: from mail.kapsi.fi (mail.kapsi.fi [IPv6:2001:67c:1be8::25]) (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 2F2EB1200DB for <babel@ietf.org>; Sat, 29 Jun 2019 03:40:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kapsi.fi; s=20161220; h=To:References:Message-Id:Content-Transfer-Encoding:Cc:Date: In-Reply-To:From:Subject:Mime-Version:Content-Type:Sender:Reply-To:Content-ID :Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To: Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe :List-Post:List-Owner:List-Archive; bh=auOgDsQNgaEDvmMuVJIqb7vSEjGdlXe0f+tL0xEMj2c=; b=DTbDqzB3JtX/IVHibzAJI08yc3 gqx25GXGPRLSsvCqKkAP/emxMyNab9IkK/n1j2jhRGBZGFgOWSIpX73eF9tJKv9YXIj49H8vpHnuZ gUY3NyQAEheECe+3F8TVsdhmzqqtqV6bcYIz5oe2N5LzIx0VO+A1XDjNfihXSMawZsAgNsuiEVQnp DIpZen0iQb33K5ewgxHc0HZzsIlacMNGRs4RPi1naVg8Nw5BQkKQ1DS+KwAJsKuZxIrHVNNMjK1J+ I+OgV2kt/ygAyw/yC+n0KfIPtFruBvRrg62uRCOLQDCvqHwHAvidz+cylZe3r7PJt+pLKXO4wU8L+ 5eYi2FYg==;
Received: from 91-155-69-60.elisa-laajakaista.fi ([91.155.69.60] helo=[192.168.42.210]) by mail.kapsi.fi with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from <markus.stenberg@iki.fi>) id 1hhAmc-0007Wt-E7; Sat, 29 Jun 2019 13:40:38 +0300
Content-Type: text/plain; charset="utf-8"
Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\))
From: Markus Stenberg <markus.stenberg@iki.fi>
In-Reply-To: <877e941xu9.wl-jch@irif.fr>
Date: Sat, 29 Jun 2019 13:40:37 +0300
Cc: babel@ietf.org
Content-Transfer-Encoding: quoted-printable
Message-Id: <2EACCFA6-6214-4C95-9951-873B9C0F4B98@iki.fi>
References: <874l49j158.wl-jch@irif.fr> <6C3AA518-8EF8-493A-835D-DE096E75D07B@iki.fi> <87ef3c20fh.wl-jch@irif.fr> <3CFB1069-5307-40F2-89DD-CA82CE2976A1@iki.fi> <87a7e01yxe.wl-jch@irif.fr> <5154BFF0-4BE3-4F72-AAA4-AC65DEDF2A97@iki.fi> <877e941xu9.wl-jch@irif.fr>
To: Juliusz Chroboczek <jch@irif.fr>
X-Mailer: Apple Mail (2.3445.104.11)
X-SA-Exim-Connect-IP: 91.155.69.60
X-SA-Exim-Mail-From: markus.stenberg@iki.fi
X-SA-Exim-Scanned: No (on mail.kapsi.fi); SAEximRunCond expanded to false
Archived-At: <https://mailarchive.ietf.org/arch/msg/babel/1g2HBX_fSb-6bFclG6TEgMv5p7s>
Subject: Re: [babel] Minor clarification to HMAC
X-BeenThere: babel@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "A list for discussion of the Babel Routing Protocol." <babel.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/babel>, <mailto:babel-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/babel/>
List-Post: <mailto:babel@ietf.org>
List-Help: <mailto:babel-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/babel>, <mailto:babel-request@ietf.org?subject=subscribe>
X-List-Received-Date: Sat, 29 Jun 2019 10:40:42 -0000

> On 29 Jun 2019, at 13.37, Juliusz Chroboczek <jch@irif.fr> wrote:
>> I think I am being dense (I haven’t looked at the protocol in awhile),
> 
> Perhaps we're not undestanding each other.  Let's work it out.
> 
>> a) babel-hmac does not have even reference to link-local address, and
> 
> Section 4.1:
> 
>   First, the node builds a pseudo-header that will participate in HMAC
>   computation but will not be sent.
>   [...]
>   Src address   The source IP address of the packet.
> 
> RFC 6126bis Section 4:
> 
>   A Babel packet MUST be silently ignored unless its source address is
>   either a link-local IPv6 address or an IPv4 address belonging to the
>   local network, and its source port is the well-known Babel port.

Ah ok, I didn’t read it through again (just did some searching), so that’s correct. Non-issue for most part.

> I don't think that's the case.  (And if you're right, then it's a serious
> flaw indeed.)

So at most you can have # of network size spurious replayed neighbour table entries. No idea how limited implementations might behave with that (e.g. fixed neighbour table size in a largish network with same HMAC key), but I think that given security consideration text it is fine then as long as the behavior is mentioned somewhere.

-Markus