Re: [babel] HMAC: removed constraint on the key stored in interface table

"STARK, BARBARA H" <bs7652@att.com> Wed, 14 August 2019 14:37 UTC

Return-Path: <bs7652@att.com>
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 44F841208D5 for <babel@ietfa.amsl.com>; Wed, 14 Aug 2019 07:37:30 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.598
X-Spam-Level:
X-Spam-Status: No, score=-2.598 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=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 FsWroDbi0Bor for <babel@ietfa.amsl.com>; Wed, 14 Aug 2019 07:37:28 -0700 (PDT)
Received: from mx0a-00191d01.pphosted.com (mx0a-00191d01.pphosted.com [67.231.149.140]) (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 078A4120043 for <babel@ietf.org>; Wed, 14 Aug 2019 07:37:28 -0700 (PDT)
Received: from pps.filterd (m0053301.ppops.net [127.0.0.1]) by mx0a-00191d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x7EEVY2H036468; Wed, 14 Aug 2019 10:37:27 -0400
Received: from alpi154.enaf.aldc.att.com (sbcsmtp6.sbc.com [144.160.229.23]) by mx0a-00191d01.pphosted.com with ESMTP id 2uckwf0mr8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 14 Aug 2019 10:37:26 -0400
Received: from enaf.aldc.att.com (localhost [127.0.0.1]) by alpi154.enaf.aldc.att.com (8.14.5/8.14.5) with ESMTP id x7EEbO4u031640; Wed, 14 Aug 2019 10:37:25 -0400
Received: from zlp30487.vci.att.com (zlp30487.vci.att.com [135.47.91.176]) by alpi154.enaf.aldc.att.com (8.14.5/8.14.5) with ESMTP id x7EEbH5L031354 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 14 Aug 2019 10:37:17 -0400
Received: from zlp30487.vci.att.com (zlp30487.vci.att.com [127.0.0.1]) by zlp30487.vci.att.com (Service) with ESMTP id 2B4C64009E67; Wed, 14 Aug 2019 14:37:17 +0000 (GMT)
Received: from GAALPA1MSGHUBAD.ITServices.sbc.com (unknown [130.8.218.153]) by zlp30487.vci.att.com (Service) with ESMTPS id 14CE14009E66; Wed, 14 Aug 2019 14:37:17 +0000 (GMT)
Received: from GAALPA1MSGUSRBF.ITServices.sbc.com ([169.254.5.84]) by GAALPA1MSGHUBAD.ITServices.sbc.com ([130.8.218.153]) with mapi id 14.03.0439.000; Wed, 14 Aug 2019 10:37:16 -0400
From: "STARK, BARBARA H" <bs7652@att.com>
To: 'David Schinazi' <dschinazi.ietf@gmail.com>, 'Juliusz Chroboczek' <jch@irif.fr>
CC: "'babel@ietf.org'" <babel@ietf.org>
Thread-Topic: [babel] HMAC: removed constraint on the key stored in interface table
Thread-Index: AQHVUe2J94IZUlXvWUGht5ECY/kmSKb5V8HwgABYPID//8teAIAAaDuA//++YOCAAErlAP//wwPwAAkY/AAAAQL7AAAWFp0g
Date: Wed, 14 Aug 2019 14:37:15 +0000
Message-ID: <2D09D61DDFA73D4C884805CC7865E6114E269246@GAALPA1MSGUSRBF.ITServices.sbc.com>
References: <8736i5ul8p.wl-jch@irif.fr> <2D09D61DDFA73D4C884805CC7865E6114E26794B@GAALPA1MSGUSRBF.ITServices.sbc.com> <87v9v0ucba.wl-jch@irif.fr> <2D09D61DDFA73D4C884805CC7865E6114E267D1B@GAALPA1MSGUSRBF.ITServices.sbc.com> <87r25ou3ri.wl-jch@irif.fr> <2D09D61DDFA73D4C884805CC7865E6114E267FBE@GAALPA1MSGUSRBF.ITServices.sbc.com> <CAPDSy+4+mDuQJrB94CGdHiiGFeCwjbgQSu3==DrJzDZp0bug+Q@mail.gmail.com> <2D09D61DDFA73D4C884805CC7865E6114E2681C5@GAALPA1MSGUSRBF.ITServices.sbc.com> <87mugcu09v.wl-jch@irif.fr> <CAPDSy+63+ezWyJsQpNd=Wig07zppvzdEMbwnY6kOzuvh3Mq=og@mail.gmail.com>
In-Reply-To: <CAPDSy+63+ezWyJsQpNd=Wig07zppvzdEMbwnY6kOzuvh3Mq=og@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [135.174.18.88]
Content-Type: multipart/alternative; boundary="_000_2D09D61DDFA73D4C884805CC7865E6114E269246GAALPA1MSGUSRBF_"
MIME-Version: 1.0
X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-08-14_05:, , signatures=0
X-Proofpoint-Spam-Details: rule=outbound_policy_notspam policy=outbound_policy score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908140149
Archived-At: <https://mailarchive.ietf.org/arch/msg/babel/MFzi0dd3W7F5k8gd5-Wnzy7gp2M>
Subject: Re: [babel] HMAC: removed constraint on the key stored in interface table
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: Wed, 14 Aug 2019 14:37:30 -0000

I’m unclear – which “implementation” are we talking about? A babel-mac implementation or a data model?

I still think I would prefer something in info model like (the Courier font is existing text):

      The value of the HMAC key.  An implementation MUST
      NOT allow this parameter to be read.  This can be done by always
      providing an empty string when read, or through permissions, or other means.
      This value MUST be provided when this instance is created, and is
      not subsequently writable. The key length MUST be the maximum length that is
              defined for the associated babel-mac-key-algorithm, so there is no need for the MAC algorithm to zero-pad,
              truncate, or otherwise manipulate the key prior to use. For HMAC-SHA256, this is defined
              in RFC4868 as 64 bytes. For Blake2s, this is defined in RFC7693 as 32 bytes. If keys are
              generated from user input, the user interface or management system is expected to
              zero-pad strings that are less than the required length, and prohibit strings longer than
              the required length. This ensures the delivered string is exactly the required number of bytes.

I really dislike SHOULDs and wiggle room in things like this that can cause a complete breakdown of interoperability. Hashing is an area where it’s very easy to achieve non-interoperability.
Barbara

From: David Schinazi <dschinazi.ietf@gmail.com>

@Juliusz: Revised statement, now with 30% more thinking of the children:

(only added second normative statement)

- Keys used for Babel-MAC MUST be of a length suitable for that MAC function.
- Implementations MUST accept all key lengths that are suitable for the selected MAC function, as defined by the specification of that MAC function.
- Implementations MUST reject keys that are not suitable for the MAC function; in other words, implementations MUST NOT preprocess keys of unsuitable lengths to produce a key of suitable length.
- Babel management interfaces MUST NOT allow configuring keys of non suitable lengths.
- Keys for HMAC-SHA256 SHOULD be 64 bytes long, keys for Blake2s SHOULD be 32 bytes long.

@Barbara: I'm not discussing the user interface, only what the information model can deliver to the Babel implementation

On Tue, Aug 13, 2019 at 4:13 PM Juliusz Chroboczek <jch@irif.fr<mailto:jch@irif.fr>> wrote:
> See response to Juliusz. The info model is *not* designing a user interface. It
> is stating what it will (or is allowed to) deliver to the babel implementation.
> What happens to generate the bytes that get delivered to babel by the info
> model are outside the control of the info model (so normative language is no
> good). Those proposed SHOULD statements mean the info model really can deliver
> pretty much any string to a babel implementation and expect interoperable
> results.

If I read Barbara right:

  - administrator writes a script that configures his 10000 routers the way
    he likes it;
  - administrator buys a new router that interprets the data model differently;
  - script breaks because the new router requires exactly 64 bytes in a key;
  - administrator spends the weekend fixing his network rather than going
    hiking with his children as he promised.

Think of the children, David.

-- Juliusz