Re: KITTEN: IETF 75 - 76

Jeffrey Hutzelman <jhutz@cmu.edu> Thu, 03 September 2009 14:40 UTC

Return-Path: <jhutz@cmu.edu>
X-Original-To: kitten@core3.amsl.com
Delivered-To: kitten@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id CBE723A6B4B for <kitten@core3.amsl.com>; Thu, 3 Sep 2009 07:40:43 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.636
X-Spam-Level:
X-Spam-Status: No, score=-2.636 tagged_above=-999 required=5 tests=[AWL=-0.037, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5esPJ36YtW3T for <kitten@core3.amsl.com>; Thu, 3 Sep 2009 07:40:42 -0700 (PDT)
Received: from smtp02.srv.cs.cmu.edu (SMTP02.SRV.CS.CMU.EDU [128.2.217.197]) by core3.amsl.com (Postfix) with ESMTP id 871F43A6924 for <kitten@ietf.org>; Thu, 3 Sep 2009 07:40:42 -0700 (PDT)
Received: from MINBAR.FAC.CS.CMU.EDU (MINBAR.FAC.CS.CMU.EDU [128.2.216.42]) (authenticated bits=0) by smtp02.srv.cs.cmu.edu (8.13.6/8.13.6) with ESMTP id n83EcnCX019829 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 3 Sep 2009 10:38:49 -0400 (EDT)
Date: Thu, 03 Sep 2009 10:38:49 -0400
From: Jeffrey Hutzelman <jhutz@cmu.edu>
To: Michael B Allen <miallen@ioplex.com>, Nicolas Williams <Nicolas.Williams@sun.com>
Subject: Re: KITTEN: IETF 75 - 76
Message-ID: <A24265FEB13A8A10136EC243@minbar.fac.cs.cmu.edu>
In-Reply-To: <24246_1251926735_n82LPYA9008569_20090902172015.da056c19.miallen@ioplex.com>
References: <4A87A69A.3050408@sun.com> <4A87E02D.7030503@isode.com> <200908180013.29152.leifj@mnt.se> <20090901131202.137bdd90.miallen@ioplex.com> <20090901173110.GL1033@Sun.COM> <396484EF-9812-40CE-9221-F1A1319FD10B@kth.se> <20090901181307.fe1d4efa.miallen@ioplex.com> <98F14484-1B48-45A1-86E7-5E78383F5109@kth.se> <20090901214059.17a309e6.miallen@ioplex.com> <4A9E22D9.9050405@samba.org> <20090902153241.GJ1033@Sun.COM> <24246_1251926735_n82LPYA9008569_20090902172015.da056c19.miallen@ioplex.com>
X-Mailer: Mulberry/4.0.8 (Linux/x86)
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"; format="flowed"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
X-Scanned-By: mimedefang-cmuscs on 128.2.217.197
Cc: kitten@ietf.org, Love@core3.amsl.com, Volker Lendecke <vl@SerNet.DE>, jhutz@cmu.edu
X-BeenThere: kitten@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: Common Authentication Technologies - Next Generation <kitten.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/kitten>, <mailto:kitten-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/kitten>
List-Post: <mailto:kitten@ietf.org>
List-Help: <mailto:kitten-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/kitten>, <mailto:kitten-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 03 Sep 2009 14:40:44 -0000

--On Wednesday, September 02, 2009 05:20:15 PM -0400 Michael B Allen 
<miallen@ioplex.com> wrote:

> On Wed, 2 Sep 2009 10:32:41 -0500
> Nicolas Williams <Nicolas.Williams@sun.com> wrote:
>> Absolutely no polling.
>>
>> Async I/O is not rocket science.  We can quibble over details, but we've
>> only got so many workable models.  And we have to be mindful that not
>> one model will result in fully portable application code.
>>
>> Here are some reasonable models:
>>
>>  - Completion callback (or, rather, a callback indicating that there's
>>    work to do, not necessarily completion)
>>
>>    This implies either a threaded process model or an async I/O process
>>    model with one common event loop provided by the OS.
>>
>>    This model is the simplest for apps to use, and it will be portable
>>    to Linux, *BSD, Solaris, Windows.  But not necessarily to embedded
>>    devices, real-time OSes, etc...
>>
>>  - Return handles to I/O resources that the app can feed into its event
>>    loop.
>>
>>    This is much more OS-specific.  On Unix/Unix-like OSes this means
>>    returning an array of file descriptors.  On Windows it means
>>    returning and array of file handles.  This too may not be terribly
>>    portable.  And it requires that the application plug the returned
>>    resources into its event loop, and take them out, on every call to
>>    these GSS functions.
>
> There is another model:
>
>> > while (1) {
>         gss_process_events(&minor, ...);
>> >
>> > 	ret = gss_call(&minor, GSS_C_NOWAIT, ...);
>> > 	if (ret != 0 && minor == EAGAIN) {
>> > 		continue;
>> > 	}
>> > 	...
>> > 	break;
>> > }

That's not another model.  That's equivalent to using the synchronous form 
of the call, if gss_process_events() blocks until the mech is ready to be 
called, or to polling, if it eventually times out.