From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_PASS,URIBL_BLOCKED,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 10CB4C43381 for ; Mon, 25 Feb 2019 21:02:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CA2EE20842 for ; Mon, 25 Feb 2019 21:02:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1551128551; bh=6Y+YL4FzaE6pcAP7Jf+1fthlV0wOOYaGp9uq9ekTbJE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:List-ID:From; b=eNjSmyLBgfEa6o8DsxSA4y0NQhyfwX4vU9nH28Gm3239GHeSTRcrJLQzvTswMgFd1 ADxyi3iJ8+icpnxQ2TaQXmTFVWK+QsqYQnojRC7a8SqHJft3v6WxbTH9mtAQk+4G+y vuVFZ8vFG17JF+qnlorPDgYMVbpEM6zwR276+us0= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727351AbfBYVCb (ORCPT ); Mon, 25 Feb 2019 16:02:31 -0500 Received: from mail.kernel.org ([198.145.29.99]:39572 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727323AbfBYVCb (ORCPT ); Mon, 25 Feb 2019 16:02:31 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 34B0D20842; Mon, 25 Feb 2019 21:02:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1551128550; bh=6Y+YL4FzaE6pcAP7Jf+1fthlV0wOOYaGp9uq9ekTbJE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=qLFvVC7YhUM+9C9P2ZKkEFcY4yBqw3g4zW+m5J3EKOSHvdCEy3HtErJ+DeUR0xeS7 GPFV8G2ZUahdkfi4Z5sGT2Ry6a/m2hNnYmW8t4aWSnU4v4cMGPbhcp5md5J0H5o80D gkJj/kohbw5IV+yiLlvrEFOZXsiF6V7HD7WuUbSc= Date: Mon, 25 Feb 2019 22:02:28 +0100 From: Greg KH To: Ilya Dryomov Cc: stable@vger.kernel.org Subject: Re: [PATCH 3.18, 4.4] libceph: handle an empty authorize reply Message-ID: <20190225210228.GC12242@kroah.com> References: <20190225201206.30079-1-idryomov@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190225201206.30079-1-idryomov@gmail.com> User-Agent: Mutt/1.11.3 (2019-02-01) Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org On Mon, Feb 25, 2019 at 09:12:06PM +0100, Ilya Dryomov wrote: > The authorize reply can be empty, for example when the ticket used to > build the authorizer is too old and TAG_BADAUTHORIZER is returned from > the service. Calling ->verify_authorizer_reply() results in an attempt > to decrypt and validate (somewhat) random data in au->buf (most likely > the signature block from calc_signature()), which fails and ends up in > con_fault_finish() with !con->auth_retry. The ticket isn't invalidated > and the connection is retried again and again until a new ticket is > obtained from the monitor: > > libceph: osd2 192.168.122.1:6809 bad authorize reply > libceph: osd2 192.168.122.1:6809 bad authorize reply > libceph: osd2 192.168.122.1:6809 bad authorize reply > libceph: osd2 192.168.122.1:6809 bad authorize reply > > Let TAG_BADAUTHORIZER handler kick in and increment con->auth_retry. > > Cc: stable@vger.kernel.org > Fixes: 5c056fdc5b47 ("libceph: verify authorize reply on connect") > Link: https://tracker.ceph.com/issues/20164 > Signed-off-by: Ilya Dryomov > Reviewed-by: Sage Weil > [idryomov@gmail.com: backport to 4.4: extra arg, no CEPHX_V2] > --- > net/ceph/messenger.c | 12 ++++++++---- > 1 file changed, 8 insertions(+), 4 deletions(-) What is the git commit id of this patch in Linus's tree? thanks, greg k-h