Re: [kitten] Stating support for HTTP-SASL on the HTTP WG list

Rick van Rein <rick@openfortress.nl> Tue, 07 February 2023 10:48 UTC

Return-Path: <vanrein@vanrein.org>
X-Original-To: kitten@ietfa.amsl.com
Delivered-To: kitten@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 481C8C140C15 for <kitten@ietfa.amsl.com>; Tue, 7 Feb 2023 02:48:45 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -0.666
X-Spam-Level:
X-Spam-Status: No, score=-0.666 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, HEADER_FROM_DIFFERENT_DOMAINS=0.25, PDS_RDNS_DYNAMIC_FP=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, RDNS_DYNAMIC=0.982, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=no autolearn_force=no
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xRAybR9TTnHH for <kitten@ietfa.amsl.com>; Tue, 7 Feb 2023 02:48:43 -0800 (PST)
Received: from fame.vanrein.org (2a02-58-157-9b00--7.ip6.tweak.nl [IPv6:2a02:58:157:9b00::7]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 17953C1526ED for <kitten@ietf.org>; Tue, 7 Feb 2023 02:48:42 -0800 (PST)
Received: by fame.vanrein.org (Postfix, from userid 1000) id 813F72C8E6; Tue, 7 Feb 2023 10:48:41 +0000 (UTC)
Date: Tue, 07 Feb 2023 10:48:41 +0000
From: Rick van Rein <rick@openfortress.nl>
To: Russ Allbery <eagle@eyrie.org>
Cc: kitten@ietf.org
Message-ID: <20230207104841.GE30583@openfortress.nl>
Mail-Followup-To: Russ Allbery <eagle@eyrie.org>, kitten@ietf.org
References: <20230127160101.GB635@openfortress.nl> <048e6943f02302bb5cf7b8c55521931ce3748d30.camel@redhat.com> <20230128215854.629841D6333@pb-smtp20.pobox.com> <87a622tdd1.fsf@hope.eyrie.org> <875ycqtcmd.fsf@hope.eyrie.org>
MIME-Version: 1.0
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: inline
In-Reply-To: <875ycqtcmd.fsf@hope.eyrie.org>
User-Agent: Mutt/1.5.20 (2009-06-14)
Archived-At: <https://mailarchive.ietf.org/arch/msg/kitten/ICSSyWgZgWSrADVfNgjmjiGlBWo>
Subject: Re: [kitten] Stating support for HTTP-SASL on the HTTP WG list
X-BeenThere: kitten@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: Common Authentication Technologies - Next Generation <kitten.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/kitten>, <mailto:kitten-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/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: Tue, 07 Feb 2023 10:48:45 -0000

Hello Russ,

> I think this would work theoretically (at least I don't see why it
> wouldn't), but I'm very curious about how widely this has been tested in
> HTTP scenarios involving round-robin load-balancing.

No, this has not been tested yet.  Not sure it adds much though; if the
mechanism allows a stateless HTTP server then jumping from one to another
does not matter.  On another note, other layers tend to face this same
problem and seem to solve it by a consistent client/server connection,
and only use the round-robin part as an initiation rite.

> Making the client
> replay the state provides enough of a theoretical hook to allow moving an
> in-progress authentication session from one backend server to another, but
> has this been done in practice with Cyrus SASL and similar SASL libraries?

To do this well, Cyrus SASL leaves a few things to be desired, actually;
namely, a state export/import facility.  This is indeed a conflict that we
are aware of -- SASL is stateful and HTTP is stateless.  This is the reason
that an earlier attempt to HTTP-SASL did not make it.  There is much more
clarity now, with the HTTP Authentication framework being written, and the
answer is bouncing the "s2s" value to allow for a fully stateless server.

> My first reaction is that this is asking a lot of the SASL library on the
> server side to be able to reconstitute and continue a halfway-constructed
> SASL session that was negotiated by a different server, but maybe that
> first reaction is erroneous.

You are right, this is a new design aspect, and this is why we did not test
on round-robin HTTP servers.  I am not sure if it is so difficult to build
into a simpler library that has collected less history, though.  SASL can
come along, but some implementations are bound to make an easier link to
HTTP than others.

-Rick