[Gen-art] Gen-ART Telechat review of draft-ietf-anima-grasp-api-08

Paul Kyzivat <pkyzivat@alum.mit.edu> Tue, 01 December 2020 02:06 UTC

Return-Path: <pkyzivat@alum.mit.edu>
X-Original-To: gen-art@ietfa.amsl.com
Delivered-To: gen-art@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 4846D3A00E0; Mon, 30 Nov 2020 18:06:47 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.001
X-Spam-Level:
X-Spam-Status: No, score=-2.001 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=alum.mit.edu
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 sUE-0at1bnEB; Mon, 30 Nov 2020 18:06:45 -0800 (PST)
Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2046.outbound.protection.outlook.com [40.107.223.46]) (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 95F313A0100; Mon, 30 Nov 2020 18:06:44 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HqWfHmUjZkEfTrHkrR51SlM5wMc1UdBRsOL/CLC990rI1oc8dfE7E5VpAvQHSLFx4jaxz+ycZ85sq2DNPadRgyLn6+IVBX/Nzu14wxNPkblFMFG+BA1RLqZsk2WghSK1MmeC22Qw8KCR3tWpyC44HLNWHJ5D9FJ5t0snTr3vvzKplr2PyGqcnrMRgbKf0zZKSSxLMcThFr9VgHT7gczLrNMuWztyxD8W2sArmbqBcqgbdUCZ53FuOxCXwWKBXefnYOzlLjlG/a9xowLQQf09j8VTy44xsgw/sU1Vq3ehFpRAGz6sP2dJtAfG7Us3fUHMsbsz8c3FrJPjLg/JbBBD8A==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=JGXUKoSqaN25B/ChkyKm8mDzvOekBDD3R46Z/cDKZH0=; b=Bn/R37f2dlzqOTRhZ4fCyX1qAZWTlMtlTaXJZWhpNUbLmoAI/w1trCUwvaai7jfc6Wi44GVm5ggj7yzYEk/6WEk70ZQZe61m5Gz2+JSYCtudH0msHdpBL1WdR9gfwESyk0SpUqCFzclWGg9s8MWWfTZCIehF+1efADzgo3JrxXDljzhCqNPnQ7mAhwdWypFb2vW7HKQJp9+V4m6glW+N/UTFRXGgcFvrmgGSlWtKaQYShI+l4RAkbxS2fwZI+V9r7XbNw7C9h+wdyU0YE1ACXWYBoNA3gJxZj2sEsT25jdPcPNer6H6RrsrbBNH1hYf2q4oiUDgTPYXuckRdJQedFQ==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 18.7.68.33) smtp.rcpttodomain=ietf.org smtp.mailfrom=alum.mit.edu; dmarc=bestguesspass action=none header.from=alum.mit.edu; dkim=none (message not signed); arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alum.mit.edu; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=JGXUKoSqaN25B/ChkyKm8mDzvOekBDD3R46Z/cDKZH0=; b=GcZlakOsBGsq4UYd/pr/MntLkh+zQWET/yIEFeNBxIYGYgKiX0TXaN/jr1qiUt6Ouh/1AdxDnJVYu5fbh4jrJZrhXb46CD47jVXTuaO/MxOXsUm3Rt1j/nmsSnxG0ULdu0os2kkal4NtkKC2IykPV0B1A7G/fbtbK349Lk1SXGo=
Received: from MN2PR08CA0011.namprd08.prod.outlook.com (2603:10b6:208:239::16) by MN2PR12MB3120.namprd12.prod.outlook.com (2603:10b6:208:cf::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3611.25; Tue, 1 Dec 2020 02:06:42 +0000
Received: from BL2NAM02FT010.eop-nam02.prod.protection.outlook.com (2603:10b6:208:239:cafe::fa) by MN2PR08CA0011.outlook.office365.com (2603:10b6:208:239::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3611.20 via Frontend Transport; Tue, 1 Dec 2020 02:06:42 +0000
X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 18.7.68.33) smtp.mailfrom=alum.mit.edu; ietf.org; dkim=none (message not signed) header.d=none;ietf.org; dmarc=bestguesspass action=none header.from=alum.mit.edu;
Received-SPF: Pass (protection.outlook.com: domain of alum.mit.edu designates 18.7.68.33 as permitted sender) receiver=protection.outlook.com; client-ip=18.7.68.33; helo=outgoing-alum.mit.edu;
Received: from outgoing-alum.mit.edu (18.7.68.33) by BL2NAM02FT010.mail.protection.outlook.com (10.152.77.53) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3611.27 via Frontend Transport; Tue, 1 Dec 2020 02:06:42 +0000
Received: from PaulKyzivatsMBP.localdomain (c-24-62-227-142.hsd1.ma.comcast.net [24.62.227.142]) (authenticated bits=0) (User authenticated as pkyzivat@ALUM.MIT.EDU) by outgoing-alum.mit.edu (8.14.7/8.12.4) with ESMTP id 0B126eVD010490 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT); Mon, 30 Nov 2020 21:06:40 -0500
From: Paul Kyzivat <pkyzivat@alum.mit.edu>
To: draft-ietf-anima-grasp-api.all@ietf.org
Cc: General Area Review Team <gen-art@ietf.org>
Message-ID: <033a81cb-0a38-b291-80cb-c94e2147de3c@alum.mit.edu>
Date: Mon, 30 Nov 2020 21:06:40 -0500
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:78.0) Gecko/20100101 Thunderbird/78.5.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-EOPAttributedMessage: 0
X-MS-PublicTrafficType: Email
X-MS-Office365-Filtering-Correlation-Id: 18cb5a87-75f5-47d1-1442-08d8959dbf1c
X-MS-TrafficTypeDiagnostic: MN2PR12MB3120:
X-Microsoft-Antispam-PRVS: <MN2PR12MB31203A33F2A60BCCF4472D42F9F40@MN2PR12MB3120.namprd12.prod.outlook.com>
X-MS-Oob-TLC-OOBClassifiers: OLM:10000;
X-MS-Exchange-SenderADCheck: 1
X-Microsoft-Antispam: BCL:0;
X-Microsoft-Antispam-Message-Info: JhX4OwIqWQUhOZ+d1on1xe9CXKGIFzSPaUKcSnRPhjTMe5OHHUioE4Rn+xKowc+yetFUaiHBHGT49JiXXNlMh7zdKNVgwpujwGUylE2SOP3q6ZM0ccHhiGKlRv0mqpd8KtXbsmA5fJd80rNdxgDWF+FjHr618d22RqsJw6ad94dDO3qcxoZsDY7k9DZmPHXHG+QVU55YhhBDHz+ANv+2kmrGLow7nMpFYSBuNiB+Zz73FzUcDfsASbWhv7OFcuryYE7QjQWk5MhEXPty4b2DNlUHNg0d7SzXVJtE3tGURN1rnFjIfgzgKEidaRv/iF1nPKvM+WRYrKjV80ik6UgaRT1cxHt1TZYVtVyijRBfzGw3THbfyzFlILR0YKuJl1Ri0fGrdU3NQOGLrVcHwbI7kwPotDjhDPaX4oU0K0xr1n6+InkUpdn4KFGQ/npyahIR6lJnWMfzjeDOMlH4GJZ2LVz4go3xVu5u5cD5/UVY73vsAXtg8zieCZ0Q9Zvr2oJI
X-Forefront-Antispam-Report: CIP:18.7.68.33; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:outgoing-alum.mit.edu; PTR:outgoing-alum.mit.edu; CAT:NONE; SFS:(39860400002)(136003)(376002)(396003)(346002)(46966005)(478600001)(4001150100001)(8936002)(6916009)(4326008)(186003)(8676002)(450100002)(82310400003)(82740400003)(70586007)(47076004)(356005)(7596003)(70206006)(786003)(75432002)(83380400001)(30864003)(31696002)(5660300002)(26005)(2616005)(956004)(336012)(31686004)(86362001)(2906002)(966005)(316002)(43740500002); DIR:OUT; SFP:1101;
X-OriginatorOrg: alum.mit.edu
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 Dec 2020 02:06:42.0998 (UTC)
X-MS-Exchange-CrossTenant-Network-Message-Id: 18cb5a87-75f5-47d1-1442-08d8959dbf1c
X-MS-Exchange-CrossTenant-Id: 3326b102-c043-408b-a990-b89e477d582f
X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3326b102-c043-408b-a990-b89e477d582f; Ip=[18.7.68.33]; Helo=[outgoing-alum.mit.edu]
X-MS-Exchange-CrossTenant-AuthSource: BL2NAM02FT010.eop-nam02.prod.protection.outlook.com
X-MS-Exchange-CrossTenant-AuthAs: Anonymous
X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem
X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB3120
Archived-At: <https://mailarchive.ietf.org/arch/msg/gen-art/v9g_3ef53mnBzWwKrmdE57ETD1I>
Subject: [Gen-art] Gen-ART Telechat review of draft-ietf-anima-grasp-api-08
X-BeenThere: gen-art@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "GEN-ART: General Area Review Team" <gen-art.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/gen-art>, <mailto:gen-art-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/gen-art/>
List-Post: <mailto:gen-art@ietf.org>
List-Help: <mailto:gen-art-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/gen-art>, <mailto:gen-art-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 01 Dec 2020 02:06:47 -0000

I am the assigned Gen-ART reviewer for this draft. The General Area 
Review Team (Gen-ART) reviews all IETF documents being processed by the 
IESG for the IETF Chair. Please wait for direction from your document 
shepherd or AD before posting a new version of the draft. For more 
information, please see the FAQ at <​ 
http://wiki.tools.ietf.org/area/gen/trac/wiki/GenArtfaq>gt;.

Document: draft-ietf-anima-grasp-api-08
Reviewer: Paul Kyzivat
Review Date: 2020-11-30
IETF LC End Date: 2020-10-28
IESG Telechat date: 2020-12-01

Summary:

This draft is on the right track but has open issues, described in the 
review.

General:

This document has addressed some of the concerns I had during the last 
call review. However some of my concerns remain and some new ones have 
arisen in this version.

Issues:

Major: 3
Minor: 6
Nits:  1

1) MAJOR: Negotiation

The text in section 2.3.5 now makes clear that the sequence of steps in 
the negotiation is non-deterministic - both sides can call 
negotiate_step and negotiate_wait. I believe this can result in the two 
sides not agreeing on what values have been negotiated. (For instance, 
what if one side calls negotiate_step concurrently with the other side 
calling end_negotiate? Which value has been agreed upon?) The loop_count 
adds to the confusion. Are the two sides intended to have independent 
loop count values? It seems these too can become unsynchronized.

Also, the goal of negotiation isn't clear to me. I gather it must be for 
the two sides to agree on a particular value for the objective. But for 
that to work there must be some rules about how values can change in 
each step so that the result stabililizes, rather than causing a battle 
that ends with loop count exhaustion. This could be achieved by always 
negotiating *down*, or always *up*. But that requires that the objective 
value type have an ordering function. Given the general nature of the 
objective I don't think that can be assumed.

ISTM that more work is needed to define the negotiation process in a way 
that ensures it ends with both sides agreeing on a single value for the 
objective.

2) MINOR: Dry Run Negotiation

Dry Run negotiation is very under-specified. Why would it be used? I 
guess that an ASA might use dry run negotiation to inform future actual 
negotiation. Can anything be inferred from a dry run negotiation about 
how an actual negotiation will go? When participating in a dry run 
negotiation, how should an ASA decide what response to make? Should it 
take into account current resource availability? Or should it respond 
based on best-case or worst-case resource availability? Or what?

This requires further clarification.

3) MAJOR: Confusing semantics of 'request_negotiate'

In section 2.3.5 I don't understand the following:

          1.  The 'session_nonce' parameter is null.  In this case the
              negotiation has succeeded in one step and the peer has
              accepted the request.  The returned 'proffered_objective'
              contains the value accepted by the peer, which is therefore
              equal to the value in the requested 'objective'.  For this
              reason, no session nonce is needed, since the session has
              ended.

IIUC this requires a network exchange with the peer. I don't see how 
this can complete *immediately*. ISTM that this could only complete 
immediately if it were satisfied from a local cache. That doesn't seem 
appropriate for this function.

Similarly, in bullet 2 I don't see how the proffered_objective would be 
available in the initial call, before a response has been received from 
the peer..

Does "immediately" here simply mean that the negotiation is completed in 
one exchange between the two ends? If so, isn't a session nonce still 
required in an event loop implementation in order to handle the one 
response?

Bullet 2 also says:

              ... The
              returned 'proffered_objective' contains the first value
              proffered by the negotiation peer.  The contents of this
              instance of the objective must be used to prepare the next
              negotiation step (see negotiate_step() below) because it
              contains the updated loop count, sent by the negotiation
              peer.  The GRASP code automatically decrements the loop
              count by 1 at each step, and returns an error if it becomes
              zero.

I guess that the 'proffered_objective' in the return parameters is the 
counter-offer to the objective passed in the call. And that you expect 
the objective value used in any subsequent negotiate_step to be derived 
by modifying this value. So far this new wording has improved my 
understanding.

But the loop_count in the objective is especially confusing. It seems 
that it is handled quite differently from the rest of the objective. You 
specify (in 2.3.2.3) that it has a default value of GRASP_DEP_LOOPCT. 
But who is expected to initialize this? (Is it simply that the ASP 
should use this value if it doesn't have any particular preference?)

Then you say that the GRASP decrements this. Is this decrementing done 
on the calling side before sending the message, the calling side after 
receiving the response? Or by the peer, on receipt or when sending the 
response? Is it permissible for the ASA to modify this value during 
negotiation? Since this seems intended to prevent a loop, having clarity 
about how this value is managed seems important.

4) MINOR: negotiate_wait

The negotiate_wait call allows one ASA to extend the timeout of another 
ASA. This could, in perverse cases, cause an ASA to wait indefinitely. 
ISTM that this is dangerous. I would think it better make the other ASA 
aware of the desire to extend the timeout and let it decide whether to 
do so.

5) MAJOR: Consistency of Objective definitions

In section 2.3.2.3 and elsewhere, presumably all parties that use a 
particular objective must agree on the values of synch, neg, dry, and 
the size and structure of the value.

There is no communication of the size and structure in the abstract API. 
Presumably the implementation of a language binding to the API is 
required to at least communicate the size and alignment requirements to 
the core. The matching of definitions between nodes must be achieved 
solely by the name, the respective language bindings at the two ends, 
and out of band mutual agreement. Furthermore, different language 
bindings may use different in-memory representations of the value. In 
such cases, how is the on-wire format to be determined?

If the two ends disagree on size and structure then problems will occur. 
Perhaps the core can identify size mismatches based on size communicated 
on the wire vs the size defined by the language binding, but there are 
no error codes defined for this situation. And of course differing 
structures with the same size would not be detectable.

Furthermore, there is potential for different ASAs to (accidentally) 
have incompatible definitions for the same objective. What happens in 
this case? How can blame be ascribed so that the problem can be fixed?

IMO more needs to be said about all of this. At the least a number of 
disclaimers that put the burden on the ASAs to recognize the risk, take 
these potential problems into account and avoid them. But there could be 
some requirements placed on API language bindings and core 
implementations to deal with some of these. And probably some added 
error codes to report what problems can be detected.

6) MINOR/MAJOR: Session State

I continue to find the lifetime and state of a session to be unclear. 
The API calls that return session_nonce seem to signal creation of a new 
session. The end_negotiate() call seems to terminate a negotiation 
session. But what causes other sessions to end? This seems important 
because there is state associated with a session that consumes resources 
and can't be reclaimed until the session ends. So it should be important 
for the ASA to end all sessions. Some clarification of this seems 
important both for core implementors and for ASA developers that will be 
using the API.

(Or is this document only for implementors of core and those 
instantiating a particular language binding of the API, with 
documentation for end users left to others?)

7) MINOR/MAJOR: Timeout

Section 2.3.2.2 indicates that the API returns an error response to the 
ASA if the timeout expires. But the other end is presumably still 
working on the request and will eventually send a response. What does 
the core do when it receives this? Must it retain state so that it can 
detect the case and ignore the message? It seems that this could result 
in the two peers disagreeing on some state.

8) MINOR: Text regarding "minimum_TTL"

There is a small problem with the following in section 2.3.4:

       -  If the parameter 'minimum_TTL' is greater than zero, any
          locally cached locators for the objective whose remaining time
          to live in milliseconds is less than or equal to 'minimum_TTL'
          are deleted first.  Thus 'minimum_TTL' = 0 will flush all
          entries.

The first sentence qualifies the paragraph to cases where minimum_TTL is 
greater than zero. But the final sentence then infers the behavior when 
minimum_TTL is equal to zero.

Also, minimum_TTL is typed as an integer, which permits negative values. 
I gather that negative values are not allowed. I can suggest two ways to 
fix this:

       -  The parameter 'minimum_TTL' MUST be greater than or equal to
          zero. Any locally cached locators for the objective whose
          remaining time to live in milliseconds is less than or equal to
          'minimum_TTL' are deleted first.  Thus 'minimum_TTL' = 0 will
          flush all entries.

Or, change they type to unsigned integer. Then the statement can be 
simplified by removing the first sentence:

       -  Any locally cached locators for the objective whose remaining
          time to live in milliseconds is less than or equal to
          'minimum_TTL' are deleted first.  Thus 'minimum_TTL' = 0 will
          flush all entries.

9) MINOR: Terminology - Session nonce

The new first paragraph of section 2.2.3 talks about identifying the 
session by a pseudo-random session identifier, and tagging it with an IP 
for further uniqueness. The 2nd paragraph talks about a session_nonce. 
It isn't clear at this point in the text if these the same thing. Or is 
the session id shared on the wire, the IP tag added by the core, and the 
session_nonce an artifact of the API, shared only between the ASA and 
the core?

Section 2.3.2.7 seems to confirm that the nonce is just an identifier 
used between the core and the ASA. But here it says that using the id 
plus the IP is simply one possible implementation choice.

Further, I question whether "nonce" is the best term to use here. ISTM 
that "handle" (session_handle) would more clearly reflect the purpose of 
this item.

I think it would be helpful to be clearer in distinguishing what is 
fundamental vs what is implementation choice. For instance, in section 
2.2.3:

    A GRASP session consists of a finite sequence of messages (for
    discovery, synchronization, or negotiation) between a pair of ASAs.
    The core identifies it on the wire by a pseudo-random session
    identifier. Further details are given in [I-D.ietf-anima-grasp].

    On the first call in a new GRASP session, the API returns a
    'session_handle' value used to identify the session. This
    value must be used in all subsequent calls for the same session, and
    will be provided as a parameter in the callback functions.  By this
    mechanism, multiple overlapping sessions can be distinguished, both
    in the ASA and in the GRASP core.  The value of the 'session_handle"
    is opaque to the ASA.

This establishes the role and relationship of the two terms, while 
section 2.3.2.7 gives a possible implementation without as much 
confusion. (It will require some rewording to switch from session_nonce 
to session_handle. It already uses "session handle" in passing.)

10) NIT: Terminology - ASA nonce

For similar reasons to those above for session_nonce/session_handle, IMO 
it would be clearer to use asa_handle rather than asa_nonce. But this is 
only a suggestion.