Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23

Axel.Nennker@telekom.de Thu, 04 January 2024 11:24 UTC

Return-Path: <Axel.Nennker@telekom.de>
X-Original-To: oauth@ietfa.amsl.com
Delivered-To: oauth@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id DDAEFC157935 for <oauth@ietfa.amsl.com>; Thu, 4 Jan 2024 03:24:26 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.102
X-Spam-Level:
X-Spam-Status: No, score=-7.102 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_BLOCKED=0.001, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=telekom.de
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 j6SW8R81Uz7m for <oauth@ietfa.amsl.com>; Thu, 4 Jan 2024 03:24:22 -0800 (PST)
Received: from mailout21.telekom.de (mailout21.telekom.de [194.25.225.215]) (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 4A066C14F5FE for <oauth@ietf.org>; Thu, 4 Jan 2024 03:24:20 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telekom.de; i=@telekom.de; q=dns/txt; s=dtag1; t=1704367461; x=1735903461; h=from:to:subject:date:message-id:references:in-reply-to: mime-version; bh=ZWZiIxMHXkr3whbJZ+wddN/Nu+YRUta1z7n5ICsNHY8=; b=295bpcR13Tzr1dMssOEQwXaK06h89fLt7wQWcxUYWvGxjs8zUzvdBPOJ nyqS+zZkLK0Is+ihinghnidXcCOSLIj1mquNsWZurp+sHQ+DhXi6iTOir z75DZlJ6Kyp5fRajM7gUuOCctfW+bc5WFQFvjXFPEVqwKv3tyCjv7TOXm 3snwCjQtbkrf91e4bpheuVzRHngqCK0dvaosPlABkanfQJn4KvKjl47ZM WaeDR7kVnGuk2UkR43i/l9XSO6jdUs0+kczeXNQfZHrSHZE1OLJlk0WvS 7rzXvlu9+2XDavG5yuZZfAtEdyzIh9FTzuSeYJXTBYGNzUNrf2qbqesmU g==;
Received: from qde9xy.de.t-internal.com ([10.171.254.32]) by MAILOUT21.dmznet.de.t-internal.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 04 Jan 2024 12:24:17 +0100
IronPort-SDR: 65969561_HI5tlmeuhds+YttMDbe+04wyLAZ89G634p+S0SrPEJtykBo wwybjacxeLgYJ1KOvy2tsOLwcmHigR/fMMGNVqw==
X-IronPort-AV: E=Sophos;i="6.04,330,1695679200"; d="scan'208,217";a="817636551"
X-MGA-submission: MDGm4+OmA1EtZvZ/JazUmJ4Wx3GS6nigOCvIqrffsZGqZnwB466+aRikJwE8fabSCS+YkbGqh/IZFRx4HJOZcr5XYC4fQC+6jAEvbVaWuOlbHl+RfB4Gjx5MpUTasIRlI6jXRVqE8Uv7YZSry5KX6whCEb5JAzNmL+gNlVTNOgZsKQ==
Received: from he101393.emea1.cds.t-internal.com ([10.169.119.197]) by QDE9Y1.de.t-internal.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 04 Jan 2024 12:24:17 +0100
Received: from HE104281.emea1.cds.t-internal.com (10.169.119.195) by HE101393.emea1.cds.t-internal.com (10.169.119.197) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1258.28; Thu, 4 Jan 2024 12:24:16 +0100
Received: from HE102779.emea1.cds.t-internal.com (10.171.40.45) by HE104281.emea1.cds.t-internal.com (10.169.119.195) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1258.28 via Frontend Transport; Thu, 4 Jan 2024 12:24:16 +0100
Received: from DEU01-BE0-obe.outbound.protection.outlook.com (104.47.7.169) by O365mail10.telekom.de (172.30.0.242) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1258.28; Thu, 4 Jan 2024 12:24:12 +0100
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QeEKogJS0FKar5/U19C4y8PxKtaWUd4NCJSuweDvYpzUBq1ROzVC2oVjHGl6FMzh8ARLqh+qW3eVG46UJrZFDnk0Fh552l1nVDEKzgr+eoekQ5PWGf7X3WxoYAzNCDXaWxUd5AIH6vGlUnqlcLijCIHSfEpgSluZQlBXFEpL9Cn5PJI1kHH++TgY7jNHQBUE7AmSjTYLrT7Fr45sHmMMSNFglcH3U43K24YQlTEbpcsiV1f/teJl6SD+kO3yyAnD7sKyb5PMymXdGSrAZdk2bx9rqdThaprb6vjH/KNt9znuPkQK65UBT7ZV5NvtgJil5Jf4eV5SrV9IA628a7phMQ==
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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ZWZiIxMHXkr3whbJZ+wddN/Nu+YRUta1z7n5ICsNHY8=; b=MWmVRDrY3ao1tH78npVXVcjNQ4fk9RJ3qXSNX0ttLp9Da2aAPbnrkwExbN1FkZue6cN1kRcOPy7rfmBUwTbvSKkUVYmtpnVJOogyaUSRLi6Q1jYdMChGfZyjAZHEP77kz5wctivsKLCNsS8nf7VftGJoFX3FujqLEqYSgFv6epSPVcRBq955Z0Lg+h+H2CKFe5OvU1gSG7TVjTi7weY3ImGZPXJSmriXsOFJZXu/t8tQe5qdcTAhMMg0SEfh+7A9zopAvye2xN6QLGCd6t3Xe5Dw6hiPQ/manYO9hAIvQTAz84x15bjYFHRAUJJwW9Ax+x31t9CkdkUllnHuXZhRRQ==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=telekom.de; dmarc=pass action=none header.from=telekom.de; dkim=pass header.d=telekom.de; arc=none
Received: from BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM (2603:10a6:b10:3d::11) by BE1P281MB1906.DEUP281.PROD.OUTLOOK.COM (2603:10a6:b10:3d::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7159.15; Thu, 4 Jan 2024 11:24:04 +0000
Received: from BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM ([fe80::14a5:9afb:6277:deb8]) by BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM ([fe80::14a5:9afb:6277:deb8%6]) with mapi id 15.20.7135.023; Thu, 4 Jan 2024 11:24:04 +0000
From: Axel.Nennker@telekom.de
To: mail=40danielfett.de@dmarc.ietf.org, oauth@ietf.org
Thread-Topic: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23
Thread-Index: AQHaOZMu8XOvd8yc7Eya/zp6mVi8dLDGRgvagAHQhwCAADH0t4AADZoAgAACeo+AACCagIAABBXHgADSE4CAAC1reQ==
Date: Thu, 04 Jan 2024 11:24:04 +0000
Message-ID: <BE1P281MB2097E8949CA350C979F59AAEED672@BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM>
References: <AS8PR10MB74277A2DAC89D987531F7F74EECBA@AS8PR10MB7427.EURPRD10.PROD.OUTLOOK.COM> <6bdfa6d8-594c-40b2-a5ed-4a8ca9943929@danielfett.de> <BE1P281MB20977CD398EB9C1C4A18150EED61A@BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM> <60861607-c450-4b62-8155-f9012a6565f2@danielfett.de> <BE1P281MB2097707E4E61A1DCF7A03500ED602@BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM> <e6ea482f-2984-4aca-92c7-479836064dd3@danielfett.de> <BE1P281MB20971C3BF0ECBF6F46BEB220ED602@BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM> <CDD28A99-05F0-4534-98EE-B086BF786E58@mit.edu> <BE1P281MB209791393882B1DFA919CBA4ED602@BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM> <a429db26-71dd-4df6-b9cd-3032d9a7e4c0@danielfett.de>
In-Reply-To: <a429db26-71dd-4df6-b9cd-3032d9a7e4c0@danielfett.de>
Accept-Language: en-US
Content-Language: en-GB
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=telekom.de;
x-ms-publictraffictype: Email
x-ms-traffictypediagnostic: BE1P281MB2097:EE_|BE1P281MB1906:EE_
x-ms-office365-filtering-correlation-id: 74ac0775-b8ea-4c95-7b6f-08dc0d17a8a0
x-ms-exchange-senderadcheck: 1
x-ms-exchange-antispam-relay: 0
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: PWIhh7aUJBGin+XQokG7wM/JSroGSX/jkLe2XSeBVxWzQF7lMxGKxy9dkTYIf+0Uv8BkMKbR80FkMTepPlQ7360xf3+kDC8Rd+bgrizIjoNWG6YzC82ll7nyvaCIvD7hOAVjCMmONlEMDkkVP6Ex36+G22SUS9cBwn+vrdXnzUBBEDzkCvmKlT/TDjYHGiXwjynQRvqylRcLH5+b9k3jYAvaxbv6cVgSc9uDojzMn9thw2WSje5ccAnvMfeNy0FvP/K5EOIyGXqXAYqQY9Fnu/JblckffOyL8YPxcIgeb4DsWE4W8uvGW18hhic0HVL3Ny0wquUD303vCREAwfQdYizOLUKuCgdTXGix+3Wu1zh9Y3TigBc53on7IyO+rJsl5zzeYYjpDVsmvBp0a176eVFTowwAg7WPLJA2yVfdA58uhG4wJH8F8HDLwC400LhQ9+DC88ZEp82yUyTxNka+fV4dZHAYoR7kcwHYnulh7aAq1hhMttUOKXSZ0NFJumy5dXWmH8MP0WZSE4gKmETO5lG6EE2hG8NPe6mcTyAUF5cG8jpD0/eZHgl2GSS1pJhmHO3CifkPLq6y0Or3zUzDiuAjXdV77pksxhMIO+sZJXh/t4qPcoX3DIfeFYFDURZ02Lr2R7nFhOC+XJb7ooY6ug==
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM; PTR:; CAT:NONE; SFS:(13230031)(39860400002)(346002)(366004)(136003)(376002)(396003)(230922051799003)(186009)(451199024)(64100799003)(1800799012)(9686003)(86362001)(15650500001)(30864003)(5660300002)(21615005)(66574015)(2906002)(76116006)(66946007)(110136005)(66556008)(66476007)(66446008)(64756008)(316002)(966005)(52536014)(7696005)(53546011)(83380400001)(6506007)(478600001)(8676002)(8936002)(122000001)(71200400001)(82960400001)(41300700001)(38100700002)(166002)(33656002)(38070700009)(55016003)(579004)(559001); DIR:OUT; SFP:1101;
x-ms-exchange-antispam-messagedata-chunkcount: 1
x-ms-exchange-antispam-messagedata-0: RklrB9qKNbW78WrCwuuGII1nMqmFwW+vuH/o4hHPXv5en6hXxLIHPrnZ3YDRXTysG1jWolBF5Gkrzc/15nAm00qjup4J+T7hgiVVqe9Xfh1oe3KEC4qqoIVvD8MYbrU00Y37oZV/5lpdwU6rQtmmg8qeyza9S2ybyTM+/aTb7v1KlghIWMahm98WYTDTCDjKlLrEOW/QVa6GV/PY2oF7YNIuU5Y7AiPtaXxfHhuzwdncO9h/9s8Z4oXJmrXSys28HSFvcyQCb/uZySfDd+V/8y+FkhisaA/2H2uHTzTgdsPEAHmX36EeRDR5+h4P0BDb/j4nesNo6I9VuzAwRkDnhYonraUGfxB3gSOhy6tqYCywaLnlxdB+BlXeOFvCpY9nsMmNoxiHEWJt+koayUQSqvbGbemsAVZloHez/jTbk69pihRCQtUYXcLFwUJJlebooS5ZkiBc26HZISo1j6FrJbKZkXl3i3kCV+D5sUlUxVJFlAUZOabL9r6BXrvor6fT9S78F1DebuRcB8t6BW8VG6Lo05cQ1TfGKVCpD7uWaE2VihuPK8iy2h8Vr3kyWePrbKEpO4Eq3lwMRlX5xiQwynE5GJ6APSC+HhxWfqfhL15dt/ORbpXVlNuyTdrZXEyJDN3tr4rcOsTuz4rQX8oCFTowSUuQpmHgFLyhnCT8eOIIHgrwbPBEBiotW4VS+CS2fkgNzBM7xlDE4N8Q+8nwAfbGCrBreIa/uuZMc4Za0OdeP42ft1mjFOPD/o5ERe0tD2lLYODOPBhKC2g4XwJ+VpffRipRiAEOcW9Zcf3ED6zMezHBgNO020H+P+osr9a50pdNf1ArJC6JbF1TMuDcnL9x0eE9txibtBR1ENnk+apHYkNVJds2byA3qze3A4HzGKBM3IMKN1Jykn9sSUsC8TifSjgsg3fX7bqSBv+J8jiiDVqezg+8kU0BJ+qkaFXTccl4Na1gwSNd2G+r0V0Zorn6wMYkSHhqxFUcsD07VSHbfhn52pqxxl6uzXzMIRwhshTyj2PvZBc8dYQ92ngnYw1i9Wo4UWrEwFyYs6Fa0C7TWzhTA+wVQk2/9sTjA3YE84Wg85mHVCMT2qrLXMrSPD46ABjBW6tE6JQFso0ivr/cg2o4FTGWWb0oLRXOIbf7t6Sxb6Aj9wVAcELNfWcpopaISPvE2UFLDw3tz6dnEJTVn3tcahrj3BopvFEbhp9DaOXScgsvilqYjcdagQHU4MuQz7vyIaU+VbGSUHayTgYJAx4o08D+kcf0AbP809gbJClg0Ugs+lm8kuXx7W58Y3xveRYj5mfK9z73wQTJ3Bq8gLJp1F3CcAL8EfVIPP2WOLo2peIBX+jTgSLDbCe+A7iSQq6Mi/vEUlvMvgci/Sn5A5DGEn2xqES/ZFFLzrbORZqBRS0lK3LyFYTkk1x98FXA6Ca5hbbkqeWlS6iK7o+14lLXpBPtY9ToqcR42IsVA7oyF8Xh1eSY6GbPzM0pa2ViuvRlDavhTozAaORIARqs/5mIOeOGEprrtMsMU0B/xbKpQr+4X0ZxLAYr2L4CsZND2Rh/iC9XSv8qreLNPjij96SeXjPe8S/WeMNZu263ToS4EK1AtXv8i+eLWWP/dKFb/D2/bdujaADCJzdp4R0klgT2QxcEyuKYt10zVhagpSQ/AJxwtXMeAcRxAJEDQQ==
Content-Type: multipart/alternative; boundary="_000_BE1P281MB2097E8949CA350C979F59AAEED672BE1P281MB2097DEUP_"
MIME-Version: 1.0
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: BE1P281MB2097.DEUP281.PROD.OUTLOOK.COM
X-MS-Exchange-CrossTenant-Network-Message-Id: 74ac0775-b8ea-4c95-7b6f-08dc0d17a8a0
X-MS-Exchange-CrossTenant-originalarrivaltime: 04 Jan 2024 11:24:04.3631 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: bde4dffc-4b60-4cf6-8b04-a5eeb25f5c4f
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: 5oU0HvJINXqekSVNpMCECMbqqNgl0WQVvJ4VIjMB6XcPAH2qnOtdguMU2Q9MEr5C3z9JnehYMM1L6ZN7W873dg==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: BE1P281MB1906
X-OriginatorOrg: telekom.de
Archived-At: <https://mailarchive.ietf.org/arch/msg/oauth/rjBhgQeNmPTv_lpGwPuHX6ApE0Y>
Subject: Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23
X-BeenThere: oauth@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: OAUTH WG <oauth.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/oauth>, <mailto:oauth-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/oauth/>
List-Post: <mailto:oauth@ietf.org>
List-Help: <mailto:oauth-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/oauth>, <mailto:oauth-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 04 Jan 2024 11:24:27 -0000

Sorry, for me an all-capitalized MAY is not a recommendation to use PKCE
MAY   This word, or the adjective "OPTIONAL", mean that an item is
   truly optional.  One vendor may choose to include the item because a
   particular marketplace requires it or because the vendor feels that
   it enhances the product while another vendor may omit the same item.
   An implementation which does not include a particular option MUST be
   prepared to interoperate with another implementation which does
   include the option, though perhaps with reduced functionality. In the
   same vein an implementation which does include a particular option
   MUST be prepared to interoperate with another implementation which
   does not include the option (except, of course, for the feature the
   option provides.)

"Clients that have ensured that the authorization server supports Proof Key for Code Exchange (PKCE, [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]) MAY rely on the CSRF protection provided by PKCE. "

And leaving the interpreting of "ensure" as an exercise to the reader, is not spec-language.

But, this email is my last comment on this. I do not seem to get support for my concerns.

Sorry, again, for commenting so late in the discussion.

//Axel


From: OAuth <oauth-bounces@ietf.org> on behalf of Daniel Fett <mail=40danielfett.de@dmarc.ietf.org>
Date: Thursday, 4. January 2024 at 08:41
To: oauth@ietf.org <oauth@ietf.org>
Subject: Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23
Am 03.01.24 um 20:10 schrieb Axel.Nennker@telekom.de<mailto:Axel.Nennker@telekom.de>:
Why not RECOMMEND PKCE for CSRF protection, instead of that "MAY"?

That's the case already, PKCE is RECOMMENDED/REQUIRED for clients (which includes the CSRF protection).

It is just that omitting "state" is a MAY, because "(to) rely on the CSRF protection provided by PKCE" effectively means that.

-Daniel


And in some cases MUST (verb) PKCE?

//Axel

From: Justin Richer <jricher@mit.edu><mailto:jricher@mit.edu>
Date: Wednesday, 3. January 2024 at 19:53
To: Nennker, Axel <Axel.Nennker@telekom.de><mailto:Axel.Nennker@telekom.de>
Cc: mail=40danielfett.de@dmarc.ietf.org<mailto:mail=40danielfett.de@dmarc.ietf.org> <mail=40danielfett.de@dmarc.ietf.org><mailto:mail=40danielfett.de@dmarc.ietf.org>, oauth@ietf.org<mailto:oauth@ietf.org> <oauth@ietf.org><mailto:oauth@ietf.org>
Subject: Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23
On Jan 3, 2024, at 12:30 PM, Axel.Nennker@telekom.de<mailto:Axel.Nennker@telekom.de> wrote:

The email discussion triggered me jumping into the discussion.
Also, I am looking into this from a Camara PoV.
https://github.com/camaraproject/IdentityAndConsentManagement
Camara is about to define what is a MUST for authorization servers etc and we are taking FAPI and the OAuth2 security best practices as input.

So, when we write our own security profile in Camara, we are probably going to copy the language "Authorization servers MUST support PKCE [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]."
We then have no problem requiring clients to use PKCE.

Coming back to draft-ietf-oauth-security-topics-23. That document's language feels like it would really, really likes to require PKCE support, but then it does not go there.
"Public clients MUST use PKCE"
"For confidential clients, the use of PKCE [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>] is RECOMMENDED"
"Authorization servers MUST support PKCE [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]."
"Although PKCE was designed as a mechanism to protect native apps, this advice applies to all kinds of OAuth clients, including web applications."


I read this as pretty clear advice — the AS has to support it, but doesn’t universally require it. Public clients have to use it, so an AS could reasonably require it automatically for public clients. Confidential clients can use it, and it’s a good idea, but it would be surprising for an AS to enforce it on a confidential client. Of course, even today, an AS can decide that any particular client has to use PKCE for whatever reason, so we’re not that different in the "maybe" space than we are now.


The following two lines are talking about different things:

I still think that the MAY in 2.1
"Clients that have ensured that the authorization server supports Proof Key for Code Exchange (PKCE, [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]) MAY rely on the CSRF protection provided by PKCE. "

This is not about the client using or not using PKCE — it’s about the client relying on PKCE for CSRF protection, which was previously relegated to state and nonce parameters alone.

and the MUST in 2.1.1
"Authorization servers MUST support PKCE [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]."

This just means it has to be available at the AS for anyone to use, and, as above, possibly required for some circumstances.

do not go well together.

//Axel


 — Justin


From: OAuth <oauth-bounces@ietf.org<mailto:oauth-bounces@ietf.org>> on behalf of Daniel Fett <mail=40danielfett.de@dmarc.ietf.org<mailto:mail=40danielfett.de@dmarc.ietf.org>>
Date: Wednesday, 3. January 2024 at 17:48
To: oauth@ietf.org<mailto:oauth@ietf.org> <oauth@ietf.org<mailto:oauth@ietf.org>>
Subject: Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23

Hi Axel,

It is to be expected that not all AS will immediately upgrade to adhere to the security BCP after its release. So a client who wants to use PKCE may encounter AS that don't support it.

See also the discussion in https://mailarchive.ietf.org/arch/msg/oauth/ZiwEfenZZlboikXxBLes5ebPmBw/

-Daniel
Am 03.01.24 um 17:39 schrieb Axel.Nennker@telekom.de<mailto:Axel.Nennker@telekom.de>:
Hi Daniel,

there is also this sentence in this section https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#name-authorization-code-grant in a paragraph on it own.

"Authorization servers MUST support PKCE [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]."

Why must a client "ensure" that the AS supports PKCE if the security best practices say the AS MUST support PKCE?

//Axel


From: OAuth <oauth-bounces@ietf.org><mailto:oauth-bounces@ietf.org> on behalf of Daniel Fett <mail=40danielfett.de@dmarc.ietf.org><mailto:mail=40danielfett.de@dmarc.ietf.org>
Date: Wednesday, 3. January 2024 at 14:01
To: oauth@ietf.org<mailto:oauth@ietf.org> <oauth@ietf.org><mailto:oauth@ietf.org>
Subject: Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23

Hi Axel,

I would be happy to see OAuth move away from state as a CSRF protection mechanism in the future, but there is not too much to be gained from relying solely on PKCE right now. The main advantage is that relying on PKCE incentivizes clients to properly manage the session state in a cookie instead of relying on a parameter. Beyond that, there's a small reduction in effort required by the client, messages will be smaller messages, etc.. The disadvantage is that a client puts CSRF protection in the hands of the AS. Therefore, we chose the wording "ensure" to say that the client has be sure that the AS actually implements PKCE correctly before relying on it. What that means in the concrete instance is up to the client.

Likewise, to your second point, I do not see enough of an advantage to RECOMMEND relying solely on PKCE for CSRF protection.

The main intention here is to open the door to rely on PKCE, e.g., in closed ecosystems, ecosystems with in-depth conformance testing, first-party applications and similar. This also helps to avoid a lot of convoluted language telling client developers how to properly choose, track, and check state values in profiles such as FAPI (and the pitfalls when interpreting that language).

-Daniel
Am 02.01.24 um 10:31 schrieb Axel.Nennker@telekom.de<mailto:Axel.Nennker@telekom.de>:
Hi,

sorry for being late in the game.

I am not too happy with this section:
"Clients that have ensured that the authorization server supports Proof Key for Code Exchange (PKCE, [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]) MAY rely on the CSRF protection provided by PKCE."


  1.  Maybe a minor point that is due to not being a native speaker, but the verb "ensure" seems too strong.
If the AZ states in its metadata, that it supports PKCE than this is "ensurance" enough, right? The client does not have to "ensure" the support by actually testing compliance, right?
I suggest rephrasing that to "If the authorization server states in its meta-data support for Proof Key for Code Exchange (PKCE, [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]) the client MAY rely on the CSRF protection provided by PKCE."
  2.  I suggest changing the "MAY" into a recommendation for all OAuth2-based protocols. OIDC flows can easily support PKCE, and new clients SHOULD use PKCE, I think.
Suggestion:
"If the authorization server states in its meta-data support for Proof Key for Code Exchange (PKCE, [RFC7636<https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html#RFC7636>]), it is RECOMMENDED the client relies on the CSRF protection provided by PKCE."

Kind regards
Axel




From: OAuth <oauth-bounces@ietf.org><mailto:oauth-bounces@ietf.org> on behalf of Daniel Fett <fett=40danielfett.de@dmarc.ietf.org><mailto:fett=40danielfett.de@dmarc.ietf.org>
Date: Thursday, 28. December 2023 at 14:38
To: oauth@ietf.org<mailto:oauth@ietf.org> <oauth@ietf.org><mailto:oauth@ietf.org>
Subject: Re: [OAUTH-WG] Shepherd Review of draft-ietf-oauth-security-topics-23

Hi Hannes,

thanks again for your feedback! It is incorporated in the editor's copy now.

- https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.html

- Diff to published version: https://author-tools.ietf.org/api/iddiff?doc_1=draft-ietf-oauth-security-topics&url_2=https://oauthstuff.github.io/draft-ietf-oauth-security-topics/draft-ietf-oauth-security-topics.txt
I plan to publish the next version once we have resolved the discussion points from Roman's AD review.

-Daniel


Am 04.10.23 um 15:41 schrieb Tschofenig, Hannes:
Hi all,

here are some comments as part of my shepherd review of the OAuth Security BCP.

First, I want to send a big "Thanks" to everyone in the group for the work on this document and to the authors in particular. It has taken us a while to come up with such an impressive list of security recommendations for OAuth 2.0.

At this point in time my review comments can only be minor given the amount of feedback this documents has already received.

Here are a few remarks.

I believe we should indicate that the specification updates other OAuth RFCs. The obvious documents it updates are RFC 6749, RFC 6750 and RFC 6819.
You can set these "updates" in the template you are using.

In Section 1 you say:
"
It does not supplant the security advice given in
   [RFC6749], [RFC6750], and [RFC6819], but complements those documents.
"

In the subsequent paragraph you state that you "depreciate some modes of operation".

I believe you are need to be clear about what you are doing in relationship to these prior documents. It might also be useful to say something about OAuth 2.1.


Expand abbreviations on first use. Example: "AS" and "PKCE" in Section 2.1. The AS abbreviation is only expanded later in Section 3. Decide whether you want to use abbreviations or not. You mix them throughout the document without no reasons.
Listing the abbreviations in Section 1.2 may also be useful. There are not that many abbreviations anyway.


I have wording suggestions for this paragraph:

FROM:
"

   Authorization servers SHOULD use client authentication if possible.

   It is RECOMMENDED to use asymmetric (public-key based) methods for
   client authentication such as mTLS [RFC8705] or using signed JWTs
   ("Private Key JWT") in accordance with [RFC7521] and [RFC7523] (in
   [OpenID.Core] defined as the client authentication method
   private_key_jwt).  When such methods for client authentication are
   used, authorization servers do not need to store sensitive symmetric
   keys, making these methods more robust against a number of attacks.

"

TO:
"

   Authorization servers SHOULD enforce client authentication, if possible.

   It is RECOMMENDED to use asymmetric cryptography for
   client authentication, such as mTLS [RFC8705] or using signed JWTs
   ("Private Key JWT"), in accordance with [RFC7521] and [RFC7523] (in
   [OpenID.Core] defined as the client authentication method
   private_key_jwt).  When asymmetric cryptography for client authentication is
   used, authorization servers do not need to store sensitive symmetric
   keys, making client authentication more robust against leakage of keys.

"

(Note: For the reader it is always better if they are told what attacks
are prevented rather than saying "a number of attacks". You don't want the reader
to guess what you mean.)

Section 2 is a summary of what follows in Section 4. Maybe you can make this explicit
either in the title of Section 2 or in the first paragraph of Section 2.



Section 3.

You write:

"
   These attackers conform to the attacker model that was used in formal
   analysis efforts for OAuth [arXiv.1601.01229].  This is a minimal
   attacker model.  Implementers MUST take into account all possible
   types of attackers in the environment in which their OAuth
   implementations are expected to run.
"

When you say "these attackers" please clarify which attackers you are talking about.
Prior to this paragraph you have just spoken about various forms of network attackers.
Just before that you talked about network and web attackers.

Then, you introduce more attackers and you keep talking about "this attacker model" and
"these attackers". Make it easier for the reader by referring explictly which attackers
you are talking about in a specific paragraph.

Then, you conclude the section with a hint that there is an even stronger attacker model.
As a reader I might want to know what this stronger attacker model looks like and why you
do not consider it in this document.


Section 4.1.1:

You write:
"
Note: Vulnerabilities of this kind can also exist if the
   authorization server handles wildcards properly.
"

I believe you are saying that the vulnerabilities caused by incorrect redirect URI validation parsing when you refer to "this kind".
I would also remove the "note"


Section 4.1.3:

You write:

"
   *  Servers on which callbacks are hosted MUST NOT expose open
      redirectors (see Section 4.11).
"

Are you talking about authorization servers (which is what was referenced in the paragraph before)?


Section 4.10.1: Sender-constrained Access Tokens

The text gives the reader the impression that the token binding would be an option for developers to use.
I don't think that this is the case. I am particularly referring to this sentence:

"

   *  *DPoP* ([I-D.ietf-oauth-dpop]): DPoP (Demonstration of Proof-of-
      Possession at the Application Layer) outlines an application-level
      sender-constraining for access and refresh tokens that can be used
      in cases where neither mTLS nor OAuth Token Binding (see below)
      are available.
"

I would change it to:
"

   *  *DPoP* ([I-D.ietf-oauth-dpop]): DPoP (Demonstration of Proof-of-
      Possession at the Application Layer) outlines an application-level
      sender-constraining for access and refresh tokens that can be used
      in cases where mTLS is not available.
"

I would then remove the subsequent text talking about old, expired drafts.
Alternatively, you could move the text to the appendix.


Section 4.10.2: Audience Restricted Access Tokens

In the text you say:

"
   Audience restriction essentially restricts access tokens to a
   particular resource server.  The authorization server associates the
   access token with the particular resource server and the resource
   server SHOULD verify the intended audience.
"

You have to put a MUST here. If the resource server does not check the audience
restriction when using audience restricted access tokens then you obviously do not
get the value from it. It is like using DPOP and not using the proof-of-possession.

Likewise the SHOULD language in this sentence is also questionable:

"
The client SHOULD tell the authorization server the intended resource
   server.  The proposed mechanism [RFC8707] could be used or by
   encoding the information in the scope value.
"

If the client does not tell the authorization server what the intended resource server
is then how should the authorization server know (unless in a very limited setup).

Also the reference to RFC 8707 is a bit weak. We standardized resource indicators: why not
recommend using it?

Section 4.10.3: The section heading is "Discussion: Preventing Leakage via Metadata".
The content of the section is not really a discussion but rather a description of why
this path has not been taken. I wonder whether it would be better to move this section
to the appendix and then start the text by explaining why other solutions have been used instead of this approach.


Section 4.11: I would put the definition about what an "open redirector" is into the terminology section since you
are using the term already in earlier sections. Here is the definition:

"
An open redirector is an endpoint that forwards a user’s
   browser to an arbitrary URI obtained from a query parameter.
"


Typos/Wording:

FROM:
"
Afterwards, the updated the OAuth attacker model is presented.
"

TO:
"
Afterwards, the updated OAuth attacker model is presented.
"

Section 4.1:

"... wild ."
         ^

Consider using the guidelines for inclusive language:
https://www.rfc-editor.org/part2/#inclusive_language

For example, "If the attacker is able to ... , **he** will directly get access to ..."

Another example is "whitelisted".

Section 4.1.2: a wording suggestion.

FROM:
"
The attack
   described here combines this behavior with the client as an open
   redirector (see Section 4.11.1) in order to get access to access
   tokens.
"

TO:
"
The attack
   described here combines this behavior with the client as an open
   redirector (see Section 4.11.1) to obtain access tokens.
"


Section 4.7.1: word missing

FROM:

"
PKCE provides robust protection against CSRF attacks even in presence
   of an that can read the authorization response (see Attacker A3 in
   Section 3).
"

TO:

"
PKCE provides robust protection against CSRF attacks even in presence
   of an attacker that can read the authorization response (see Attacker A3 in
   Section 3).
"



Section 4.18.2: capitalization

FROM:

"
Wildcard origins like "*" in postMessage MUST not be used as
   attackers can use them to leak a victim's in-browser message to
   malicious origins.
"
TO:

"
Wildcard origins like "*" in postMessage MUST NOT be used as
   attackers can use them to leak a victim's in-browser message to
   malicious origins.
"

You might also want to replace the short title "oauth-security-topics" (which can be found on each page) with something like "OAuth 2.0 Security BCP".

Ciao
Hanns



_______________________________________________

OAuth mailing list

OAuth@ietf.org<mailto:OAuth@ietf.org>

https://www.ietf.org/mailman/listinfo/oauth

--

Please use my new email address: mail@danielfett.de<mailto:mail@danielfett.de>


_______________________________________________

OAuth mailing list

OAuth@ietf.org<mailto:OAuth@ietf.org>

https://www.ietf.org/mailman/listinfo/oauth


_______________________________________________

OAuth mailing list

OAuth@ietf.org<mailto:OAuth@ietf.org>

https://www.ietf.org/mailman/listinfo/oauth
_______________________________________________
OAuth mailing list
OAuth@ietf.org<mailto:OAuth@ietf.org>
https://www.ietf.org/mailman/listinfo/oauth




_______________________________________________

OAuth mailing list

OAuth@ietf.org<mailto:OAuth@ietf.org>

https://www.ietf.org/mailman/listinfo/oauth