RE: Security aspects with S-BFD

Santosh P K <santoshpk@juniper.net> Fri, 08 November 2013 17:40 UTC

Return-Path: <santoshpk@juniper.net>
X-Original-To: rtg-bfd@ietfa.amsl.com
Delivered-To: rtg-bfd@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 84A9221F9FB9 for <rtg-bfd@ietfa.amsl.com>; Fri, 8 Nov 2013 09:40:39 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -3.598
X-Spam-Level:
X-Spam-Status: No, score=-3.598 tagged_above=-999 required=5 tests=[BAYES_00=-2.599, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-1]
Received: from mail.ietf.org ([12.22.58.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id j9Ue0+umig0C for <rtg-bfd@ietfa.amsl.com>; Fri, 8 Nov 2013 09:40:27 -0800 (PST)
Received: from co1outboundpool.messaging.microsoft.com (co1ehsobe002.messaging.microsoft.com [216.32.180.185]) by ietfa.amsl.com (Postfix) with ESMTP id F1C6B11E81AD for <rtg-bfd@ietf.org>; Fri, 8 Nov 2013 09:39:37 -0800 (PST)
Received: from mail110-co1-R.bigfish.com (10.243.78.252) by CO1EHSOBE026.bigfish.com (10.243.66.89) with Microsoft SMTP Server id 14.1.225.22; Fri, 8 Nov 2013 17:38:38 +0000
Received: from mail110-co1 (localhost [127.0.0.1]) by mail110-co1-R.bigfish.com (Postfix) with ESMTP id 2D0DC64053D; Fri, 8 Nov 2013 17:38:38 +0000 (UTC)
X-Forefront-Antispam-Report: CIP:157.56.240.101; KIP:(null); UIP:(null); IPV:NLI; H:BL2PRD0510HT001.namprd05.prod.outlook.com; RD:none; EFVD:NLI
X-SpamScore: -20
X-BigFish: VPS-20(zzdb82h98dI9371Ic85fhzz1f42h2148h208ch1ee6h1de0h1fdah2073h2146h1202h1e76h1d1ah1d2ah1fc6hzz1d7338h1de098h1033IL17326ah8275bh8275dh18c673h1c8fb4h1de097h186068hz2fh109h2a8h839hd24hf0ah1288h12a5h12bdh137ah1441h1504h1537h153bh162dh1631h1758h18e1h1946h19b5h19ceh1ad9h1b0ah1bceh224fh1d07h1d0ch1d2eh1d3fh1de9h1dfeh1dffh1e1dh1fe8h1ff5h20f0h2216h9a9j1155h)
Received-SPF: pass (mail110-co1: domain of juniper.net designates 157.56.240.101 as permitted sender) client-ip=157.56.240.101; envelope-from=santoshpk@juniper.net; helo=BL2PRD0510HT001.namprd05.prod.outlook.com ; .outlook.com ;
X-Forefront-Antispam-Report-Untrusted: SFV:NSPM; SFS:(199002)(189002)(377454003)(24454002)(54316002)(87266001)(47446002)(31966008)(56776001)(69226001)(74502001)(79102001)(74662001)(63696002)(46102001)(77982001)(74876001)(59766001)(80022001)(66066001)(65816001)(51856001)(74366001)(81342001)(19300405004)(4396001)(76796001)(76786001)(76576001)(87936001)(81816001)(54356001)(53806001)(81542001)(2656002)(76482001)(74706001)(81686001)(77096001)(50986001)(56816003)(49866001)(47976001)(47736001)(15202345003)(561944002)(33646001)(18717965001)(83072001)(80976001)(85306002)(16236675002)(19609705001)(19580395003)(74316001)(19580405001)(83322001)(15975445006)(24736002); DIR:OUT; SFP:; SCL:1; SRVR:BN1PR05MB124; H:BN1PR05MB121.namprd05.prod.outlook.com; CLIP:116.197.184.18; FPR:; RD:InfoNoRecords; A:1; MX:1; LANG:en;
Received: from mail110-co1 (localhost.localdomain [127.0.0.1]) by mail110-co1 (MessageSwitch) id 1383932316121743_20732; Fri, 8 Nov 2013 17:38:36 +0000 (UTC)
Received: from CO1EHSMHS021.bigfish.com (unknown [10.243.78.247]) by mail110-co1.bigfish.com (Postfix) with ESMTP id 19B1AA8004D; Fri, 8 Nov 2013 17:38:36 +0000 (UTC)
Received: from BL2PRD0510HT001.namprd05.prod.outlook.com (157.56.240.101) by CO1EHSMHS021.bigfish.com (10.243.66.31) with Microsoft SMTP Server (TLS) id 14.16.227.3; Fri, 8 Nov 2013 17:38:35 +0000
Received: from BN1PR05MB124.namprd05.prod.outlook.com (10.255.199.28) by BL2PRD0510HT001.namprd05.prod.outlook.com (10.255.100.36) with Microsoft SMTP Server (TLS) id 14.16.371.2; Fri, 8 Nov 2013 17:38:27 +0000
Received: from BN1PR05MB121.namprd05.prod.outlook.com (10.255.199.16) by BN1PR05MB124.namprd05.prod.outlook.com (10.255.199.28) with Microsoft SMTP Server (TLS) id 15.0.810.5; Fri, 8 Nov 2013 17:38:20 +0000
Received: from BN1PR05MB121.namprd05.prod.outlook.com ([169.254.13.238]) by BN1PR05MB121.namprd05.prod.outlook.com ([169.254.13.111]) with mapi id 15.00.0810.005; Fri, 8 Nov 2013 17:38:19 +0000
From: Santosh P K <santoshpk@juniper.net>
To: Glen Kent <glen.kent@gmail.com>, "Bhatia, Manav (Manav)" <manav.bhatia@alcatel-lucent.com>
Subject: RE: Security aspects with S-BFD
Thread-Topic: Security aspects with S-BFD
Thread-Index: Ac7b2ToBrFn7tnaZR4yTSVGAJsb+GwAzhE4AAABrHHA=
Date: Fri, 08 Nov 2013 17:38:19 +0000
Message-ID: <ed5747584fdb464bb7d1d9a1d04d0835@BN1PR05MB121.namprd05.prod.outlook.com>
References: <20211F91F544D247976D84C5D778A4C32E4FACB1@SG70YWXCHMBA05.zap.alcatel-lucent.com> <CAPLq3UMV4es_NMZdeB=QEEWyJ0bBQq86hpos-hFbkOtGn_C6-g@mail.gmail.com>
In-Reply-To: <CAPLq3UMV4es_NMZdeB=QEEWyJ0bBQq86hpos-hFbkOtGn_C6-g@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [116.197.184.18]
x-forefront-prvs: 00246AB517
Content-Type: multipart/alternative; boundary="_000_ed5747584fdb464bb7d1d9a1d04d0835BN1PR05MB121namprd05pro_"
MIME-Version: 1.0
X-OriginatorOrg: juniper.net
X-FOPE-CONNECTOR: Id%0$Dn%*$RO%0$TLS%0$FQDN%$TlsDn%
Cc: "rtg-bfd@ietf.org" <rtg-bfd@ietf.org>
X-BeenThere: rtg-bfd@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: "RTG Area: Bidirectional Forwarding Detection DT" <rtg-bfd.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rtg-bfd>, <mailto:rtg-bfd-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/rtg-bfd>
List-Post: <mailto:rtg-bfd@ietf.org>
List-Help: <mailto:rtg-bfd-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rtg-bfd>, <mailto:rtg-bfd-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 08 Nov 2013 17:40:47 -0000

Glen,
   Sequence number has a meaning at initiator. Initiator on receiving the packet from the reflector can look in to sequence number and reject/accept based on that.

Thanks
Santosh P K

From: rtg-bfd-bounces@ietf.org [mailto:rtg-bfd-bounces@ietf.org] On Behalf Of Glen Kent
Sent: Friday, November 08, 2013 10:54 PM
To: Bhatia, Manav (Manav)
Cc: rtg-bfd@ietf.org
Subject: Re: Security aspects with S-BFD

This is akin to saying that sequence numbers will not be used for authenticating S-BFD packets, right? If thats how it is, then cant we simply set this to 0, and ignore it on receipt.

Glen

On Thu, Nov 7, 2013 at 10:18 PM, Bhatia, Manav (Manav) <manav.bhatia@alcatel-lucent.com<mailto:manav.bhatia@alcatel-lucent.com>> wrote:
Hi,

S-BFD describes the reflector sessions which raises interesting security considerations.

Since the reflector sessions are stateless (that's one of the biggest advantages) it's impossible for the reflector to keep track of the sequence number that its heard from its peers. This means, that the reflector is susceptible to both inter-session and intra-session replay attacks. We had a discussion internally amongst the co-authors and had the following proposal that we wanted to vet before the WG members.

Would like to hear the WGs opinion on this.

1. The Initiator picks up a crypto sequence number depending upon the authentication mode that its using (meticulous or non meticulous). It sends a packet to the Reflector with this seq num.

2. The reflector maintains no session state and hence does not look at the crypto sequence number before accepting the packet. It looks at the Key ID (draft-ietf-bfd-generic-crypto-auth-05) in the incoming packet (or it can do it based on its own database where it maps the neighbor to the key iD) and verifies the authentication data. If everything looks good, it processes the packet.

3. When responding the Reflector needs to compute the Authentication data. It uses the same sequence number that it received in the S-BFD packet that it is responding to. It knows the Key ID, and thus the SA. It computes the authentication data and sends the S-BFD packet out.

4. The Initiator receives the response from the Reflector. It only accepts the S-BFD packet if it either comes with the same sequence number as it had sent or its within the window that it finds acceptable (described in detail in Sec 3.4 of draft-ietf-bfd-generic-crypto-auth-05)

Benefits of this scheme.

1. Reflectors continue to remain stateless despite using security.

2. Reflectors are not susceptible to replay attacks as they always respond to S-BFD packets irrespective of the sequence number carried.

3. An attacker cannot forge packets from the Reflector since the Initiator will only accept S-BFD packets that come with the sequence number that it had originally used when sending the S-BFD packet.

Drawbacks of this scheme.

1. Reflectors are susceptible to DoS attacks since they respond to all incoming S-BFD packets. This gets worse when cryptography is used as the work load drastically increases as security is employed.

Cheers, Manav