Re: [sipcore] I-D Action: draft-ietf-sipcore-sip-token-authnz-02.txt

Christer Holmberg <christer.holmberg@ericsson.com> Thu, 11 July 2019 15:03 UTC

Return-Path: <christer.holmberg@ericsson.com>
X-Original-To: sipcore@ietfa.amsl.com
Delivered-To: sipcore@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 50FFB1202F3 for <sipcore@ietfa.amsl.com>; Thu, 11 Jul 2019 08:03:11 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.002
X-Spam-Level:
X-Spam-Status: No, score=-2.002 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, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=ericsson.com
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 S0OaT4_quwO9 for <sipcore@ietfa.amsl.com>; Thu, 11 Jul 2019 08:03:08 -0700 (PDT)
Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on060a.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe02::60a]) (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 EF9C3120303 for <sipcore@ietf.org>; Thu, 11 Jul 2019 08:03:03 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CFYOBNfOa+QWt/j/GII5f41jZQ2aS6hifs+Opv8VxQf287qn5qUlLA0N3/U2PtgIAVufno1H4YxKXtIxtlz5IrHh5sCLmDA7v/WBLd1nJUA0lV6bUV7yzAXX96j+gjtlZzQkCq+7/LBDx+p9mMhZgZFSFwCPxe0+Dz+/pqMoJmonm4iItkorOf7DflzI6nYyNXkaJVkcdeSSUh9T1Idvk/GV/Av3awEOeEbWOBd5bDI1+6JrkeVG0eXoWR/ykvuQ2DTVv/2JqOnw5EnPa6o60NDqD8WHoP8Ue+GorjhsFw4KHnB5RKkScEEVGPLEoecMORs+2SJcmARuOHbUuaVPdA==
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=PKiw2PD+K2nTsyeywMK4sQVUezZt5fX0hYNHsKMyAyo=; b=FkkKNJzFCwGE1tiCW29TYHAmHBy5CPObRGOPkalBEa0Qd4ylKyD7l00KKLGXddDyrPgyRUBjuLDFTLUgNLH9d4IKsx/8KG4tnXvXJ6AdsjhXH7WBH+SIKQGcZOoRKJnwz5cu3eLyWPD49F4Q27bX/q2BIxBC4736vw/x5QE7gQx/pun+OhdKW8saZIsVbG6yoK2AwN8Ne1gQNERaTlp79oZF41cQG+nN2nsIPwQSfadMPTIsgxGU56eX6AvZRcuZ9iCp/05kX0e+9e8DMEDpmxTcAhzEgD1hGCBf8XGN8zoy0h7EibP5PBYFPHFV/AcJjcXLr6tG8xU/D/7WfxvvTw==
ARC-Authentication-Results: i=1; mx.microsoft.com 1;spf=pass smtp.mailfrom=ericsson.com;dmarc=pass action=none header.from=ericsson.com;dkim=pass header.d=ericsson.com;arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ericsson.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=PKiw2PD+K2nTsyeywMK4sQVUezZt5fX0hYNHsKMyAyo=; b=rJhQtfzxsaSIJ71zlYLYsFaL/x8zuAhJaxBKnaqC0AkpyUr3FyAHsld8eLNOYdbLBtmFWgscC0O3hKVnVigaGZfX08qXOv8TAryEkyPqp4cNQW81+EGkp8zojxvsmV5mB3l+qjbNO/G4FrFTERhweQt8tMDOUqDoPmZPVuPC2Os=
Received: from HE1PR07MB3161.eurprd07.prod.outlook.com (10.170.245.23) by HE1PR07MB4188.eurprd07.prod.outlook.com (20.176.166.29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2073.9; Thu, 11 Jul 2019 15:02:59 +0000
Received: from HE1PR07MB3161.eurprd07.prod.outlook.com ([fe80::5050:a3a9:be80:cf43]) by HE1PR07MB3161.eurprd07.prod.outlook.com ([fe80::5050:a3a9:be80:cf43%5]) with mapi id 15.20.2073.008; Thu, 11 Jul 2019 15:02:59 +0000
From: Christer Holmberg <christer.holmberg@ericsson.com>
To: Paul Kyzivat <pkyzivat@alum.mit.edu>, "sipcore@ietf.org" <sipcore@ietf.org>
Thread-Topic: [sipcore] I-D Action: draft-ietf-sipcore-sip-token-authnz-02.txt
Thread-Index: AQHVNLWxruT/m/C2REGBvr04oIfCDqa/Al8AgAHwRACAACa0QIAAOvWAgACKbgCAAH00gIAARqSA///Z+ACAADMUgP//1TCAgABAXACAATj+gIAAOeSAgABE8QCAALlBgIAAP24AgAA3OYD//9JzgAAHn32A
Date: Thu, 11 Jul 2019 15:02:59 +0000
Message-ID: <7AEC21E0-B0A6-4303-B936-F183ED6EC05D@ericsson.com>
References: <156249821133.14592.1211919336596009446@ietfa.amsl.com> <c8d5c42e-ab21-80e8-3189-c8592dd02d3a@alum.mit.edu> <HE1PR07MB3161C55955B2FCED2C0F6A9993F60@HE1PR07MB3161.eurprd07.prod.outlook.com> <68ed93ae-57df-6bc7-774b-47959417abda@alum.mit.edu> <HE1PR07MB3161D46B4A44FC7E789ADDB893F10@HE1PR07MB3161.eurprd07.prod.outlook.com> <4a9787e5-b5e2-bc08-0fa0-fae6bd44148d@alum.mit.edu> <527F4C39-F065-4335-A939-6D443F1801E7@ericsson.com> <5bb63c0c-130d-7f69-10b0-1ed1b274cc58@alum.mit.edu> <87AD4BB8-CE77-4FD7-BB72-6643DF513058@ericsson.com> <168b1354-b35b-edee-e5f9-d4ddbecfae40@alum.mit.edu> <607A513F-8616-4777-8B5E-59390E845709@ericsson.com> <b6ca4c79-5a17-10da-3882-20bc8b0e9b98@alum.mit.edu> <89A28FAE-A25A-4AFF-9A94-91E09FDD6C3B@ericsson.com> <2aa8cb91-aac6-b66e-e54a-b9f6c650ce02@alum.mit.edu> <D7218ABE-F204-407B-ADE1-39DAB98C2A98@ericsson.com> <cd23be26-c383-8b72-cdf1-4436a6bc175f@alum.mit.edu> <59F235A8-2BD4-49B5-8890-E793E1CF40EC@ericsson.com> <64b7d784-3f34-dd11-d7e2-b22fe621cd70@alum.mit.edu>
In-Reply-To: <64b7d784-3f34-dd11-d7e2-b22fe621cd70@alum.mit.edu>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
user-agent: Microsoft-MacOutlook/10.1a.0.190609
authentication-results: spf=none (sender IP is ) smtp.mailfrom=christer.holmberg@ericsson.com;
x-originating-ip: [89.166.49.243]
x-ms-publictraffictype: Email
x-ms-office365-filtering-correlation-id: 42ab8d2b-e5e2-4838-d7fb-08d70610dd64
x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(2017052603328)(7193020); SRVR:HE1PR07MB4188;
x-ms-traffictypediagnostic: HE1PR07MB4188:
x-microsoft-antispam-prvs: <HE1PR07MB41882DFE525167355CD9ADA093F30@HE1PR07MB4188.eurprd07.prod.outlook.com>
x-ms-oob-tlc-oobclassifiers: OLM:10000;
x-forefront-prvs: 0095BCF226
x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(346002)(366004)(376002)(396003)(39860400002)(136003)(199004)(189003)(66946007)(14444005)(256004)(76116006)(186003)(66446008)(64756008)(66556008)(102836004)(14454004)(66476007)(26005)(86362001)(71190400001)(5660300002)(33656002)(2906002)(66066001)(2501003)(6506007)(229853002)(6116002)(3846002)(316002)(81156014)(2616005)(6512007)(2171002)(44832011)(476003)(305945005)(25786009)(8676002)(6486002)(478600001)(110136005)(76176011)(6246003)(71200400001)(446003)(99286004)(36756003)(53936002)(8936002)(81166006)(68736007)(58126008)(6436002)(486006)(11346002)(7736002); DIR:OUT; SFP:1101; SCL:1; SRVR:HE1PR07MB4188; H:HE1PR07MB3161.eurprd07.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1;
received-spf: None (protection.outlook.com: ericsson.com does not designate permitted sender hosts)
x-ms-exchange-senderadcheck: 1
x-microsoft-antispam-message-info: YXRcpAabLNm49D8FnBhdCqh6fhjSOOeb7J4WvaQTPU+9l0kukE9fXDZPbYfWXC/r569Ta6TX4+bpfgm8t9w0UgKE6l8KMts2BSnfJ6gans12IKYFmzHXItwGykcTCBeqnnS84bvI/Ol3rtHfZ/VI80a1MTcktZFw+CiBCHGW4V5gYA2nQESZvOEVWagqAwpNyt2JRYTWhI51fpNGAETRF0qWs7gfkHrLrHzzjRWOXB0zFmG/JAMEwuDX7zm5xAZJ4633mmeJpBnBvEEhTizMHHfRgWz1wGzy7d5VfiWSrJjtFuitBgx1K+L5Wc9HfwYC1MX0riHiYLbcIP6B7PH4LDjbHsADwrsv40AJnaYkDxGkGpot1d1hwXgDH6vMB1xjI2BoJ9KHAmitfOZ7h2bLcjDHQNVOpxg2zNMsTdDcFrg=
Content-Type: text/plain; charset="utf-8"
Content-ID: <A70FDE8302CD1C45A69196118061D845@eurprd07.prod.outlook.com>
Content-Transfer-Encoding: base64
MIME-Version: 1.0
X-OriginatorOrg: ericsson.com
X-MS-Exchange-CrossTenant-Network-Message-Id: 42ab8d2b-e5e2-4838-d7fb-08d70610dd64
X-MS-Exchange-CrossTenant-originalarrivaltime: 11 Jul 2019 15:02:59.7972 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 92e84ceb-fbfd-47ab-be52-080c6b87953f
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: christer.holmberg@ericsson.com
X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR07MB4188
Archived-At: <https://mailarchive.ietf.org/arch/msg/sipcore/KUPJ4qeMf2BrJAiuBLQxmwZO_FA>
Subject: Re: [sipcore] I-D Action: draft-ietf-sipcore-sip-token-authnz-02.txt
X-BeenThere: sipcore@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: SIP Core Working Group <sipcore.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/sipcore>, <mailto:sipcore-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/sipcore/>
List-Post: <mailto:sipcore@ietf.org>
List-Help: <mailto:sipcore-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/sipcore>, <mailto:sipcore-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 11 Jul 2019 15:03:19 -0000

Hi,

    >>>>>> All I am saying is that one should not send a token to someone that it has NOT been issued for.
    >>>>>
    >>>>>     Then you are saying that a token should *never* be included in a request
    >>>>>     to a target for which you have not received a challenge some time in the
    >>>>>     past.
    >>>>>
    >>>>>     That is a bit extreme, but I guess you can specify that if you think it
    >>>>>     is the right thing to do.
    >>>>
    >>>> That is my understanding of the generic OAuth security considerations: you don't give a token to someone it was not intended for.
    >>>>
    >>>> Of course, if you know (based on whatever configuration/policy) that it's ok to give the token to the target I guess you could do it.
    >>>>
    >>>>>     But note that this logic won't always work for Proxy-Authenticate. You
    >>>>>     *might* know that a particular proxy will be visited (if it is mentioned
    >>>>>     on a Route header), but it is pretty common for the request to visit
    >>>>>     proxies unknown (at least in advance) to the UAC.
    >>>>
    >>>> It is important to remember that, since the token needs to be protected, a proxy needs to have the
    >>>> associated protection credentials to be able to access the token.
    >>>
    >>> I'm lost here. How is the token protected? Is it because it is passed by
    >>> reference, and other credentials are needed to dereference it? Or is it
    >>> passed by value but encrypted?
    >> 
    >>      That depends on how your protect it.
    >> 
    >>      If the oauth2 token itself is encrypted, and only authorized entities can decrypt it, then I guess it does 
    >>      not matter if a non-authorized user gets it, as it will not be able to use it.
    >
    > Is this going to be defined, or is the intent to leave it open?
    > I don't understand how things can work if it is left open.
    
    We normally don't specify HOW to protect SIP information, because it can done in  many different ways, we only say when 
    some piece of information needs to be protected.

    Also, in the case of oauth2 tokens, as they can be encoded in many different ways, some of which have their own built-in protections (e.g., JWT), we can't specify a single solution that works for all. We can only specify what security characteristics must be fulfilled.

    >>  But, if the oauth2 token is sent in "plain text", then the SIP signaling needs to be protected/encrypted. 
    >>  But, in that case, if I make a phone call to you, and the call itself is valid, then I should not send you the 
    >>  oauth2 token unless it's meant for you, because once you decrypt the signaling you will have access to it.
    >> 
    >>     What is important is that a non-authorized user should not have access to a non-protected oauth2 token.
    >
    > I don't see how this can work. How does the UAC *know* if the server it 
    > is sending credentials to is authorized to receive those credentials?
    >    
    > In general the UAC doesn't know what proxies and UAS the request will 
    > visit. All it knows is the request-URI. Since there generally isn't a 
    > direct connection from UAC to UAS TLS authentication doesn't help.
 
    In that case you should use encoding with built-in protection, that only authorized entities are able to decrypt. JWT provides 
    such protection, so I assume it wouldn't matter if a non-authorized entity receives it. And, as far as the OAuth token is concerned, you don't have to protect the SIP signaling when using JWT (there may of course be other reasons why you need to protect the SIP signaling).

   Regards,

   Christer