Re: [IPsec] IKEv2 initial contact handling?

Yoav Nir <ynir@checkpoint.com> Wed, 10 April 2013 05:11 UTC

Return-Path: <ynir@checkpoint.com>
X-Original-To: ipsec@ietfa.amsl.com
Delivered-To: ipsec@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id A88A121F8D2A for <ipsec@ietfa.amsl.com>; Tue, 9 Apr 2013 22:11:53 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 0.701
X-Spam-Level:
X-Spam-Status: No, score=0.701 tagged_above=-999 required=5 tests=[AWL=-8.701, BAYES_00=-2.599, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-8, URIBL_SBL=20]
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 0zwlgGgtx9cS for <ipsec@ietfa.amsl.com>; Tue, 9 Apr 2013 22:11:52 -0700 (PDT)
Received: from smtp.checkpoint.com (smtp.checkpoint.com [194.29.34.68]) by ietfa.amsl.com (Postfix) with ESMTP id F071521F8C3C for <ipsec@ietf.org>; Tue, 9 Apr 2013 22:11:51 -0700 (PDT)
Received: from DAG-EX10.ad.checkpoint.com ([194.29.34.150]) by smtp.checkpoint.com (8.13.8/8.13.8) with ESMTP id r3A5BoiV008157; Wed, 10 Apr 2013 08:11:50 +0300
X-CheckPoint: {5164F46C-0-1B221DC2-1FFFF}
Received: from IL-EX10.ad.checkpoint.com ([169.254.2.54]) by DAG-EX10.ad.checkpoint.com ([169.254.3.48]) with mapi id 14.02.0342.003; Wed, 10 Apr 2013 08:11:49 +0300
From: Yoav Nir <ynir@checkpoint.com>
To: Kanaga Kannappan <kanaga_k@yahoo.com>
Thread-Topic: [IPsec] IKEv2 initial contact handling?
Thread-Index: AQHONUQjOyZyB07NbE6zMjx8VDexcZjOtwCA
Date: Wed, 10 Apr 2013 05:11:49 +0000
Message-ID: <141C986B-330F-41D7-8FF5-7C70DE68BA0B@checkpoint.com>
References: <1365526990.17344.YahooMailNeo@web141003.mail.bf1.yahoo.com>
In-Reply-To: <1365526990.17344.YahooMailNeo@web141003.mail.bf1.yahoo.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
x-originating-ip: [172.31.20.42]
x-kse-antivirus-interceptor-info: scan successful
x-kse-antivirus-info: Clean
Content-Type: multipart/alternative; boundary="_000_141C986B330F41D78FF57C70DE68BA0Bcheckpointcom_"
MIME-Version: 1.0
Cc: "ipsec@ietf.org" <ipsec@ietf.org>
Subject: Re: [IPsec] IKEv2 initial contact handling?
X-BeenThere: ipsec@ietf.org
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Discussion of IPsec protocols <ipsec.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ipsec>, <mailto:ipsec-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/ipsec>
List-Post: <mailto:ipsec@ietf.org>
List-Help: <mailto:ipsec-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ipsec>, <mailto:ipsec-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 10 Apr 2013 05:11:53 -0000

On Apr 9, 2013, at 8:03 PM, Kanaga Kannappan <kanaga_k@yahoo.com<mailto:kanaga_k@yahoo.com>> wrote:

Hi All,

How to handle "Initial Contact Notification" during simultaneous IKEv2 SA negotiation?


The simplest answer is not to handle it. It makes sense that peers will do a simultaneous negotiation for rekeying an IPsec SA. Most gateways do this proactively, but only in response to traffic. So if both are configured to expire SAs after 1 hour, but renegotiate after 55 minutes, then if there's a packet when the SA is 56 minutes old, it could trigger a simultaneous re-negotiation.

OTOH when initiating the first IKE SA, it's not likely to start from both sides at the same time. You could probably reproduce such a case in the lab. What you're supposed to do when presented with an Initial Contact, is delete all "other" IKE SAs.My code only erases established SAs (not things that are in the middle of the initial exchanges) so if they're simultaneous either both will be set up or only one based on the tie-breaker logic in RFC 5996.

But suppose your code is different. The worst case is that each side has deleted the IKE SA that it has initiated, and both gateways end up with one IKE SA each (different SAs). If your code has a recovery mechanism such as RFC 6290, that issue gets resolved quickly.

I don't think this edge case is something to worry about.

Yoav