From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935863AbdIYOO5 (ORCPT ); Mon, 25 Sep 2017 10:14:57 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44212 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933355AbdIYOOz (ORCPT ); Mon, 25 Sep 2017 10:14:55 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com A21D5272A3 Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx10.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=dhowells@redhat.com Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20170921205742.144596-3-ebiggers3@gmail.com> References: <20170921205742.144596-3-ebiggers3@gmail.com> <20170921205742.144596-1-ebiggers3@gmail.com> To: Eric Biggers Cc: dhowells@redhat.com, keyrings@vger.kernel.org, Michael Halcrow , linux-security-module@vger.kernel.org, linux-kernel@vger.kernel.org, Eric Biggers Subject: Re: [PATCH v2 2/3] KEYS: don't revoke uninstantiated key in request_key_auth_new() MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <30193.1506348893.1@warthog.procyon.org.uk> Date: Mon, 25 Sep 2017 15:14:53 +0100 Message-ID: <30194.1506348893@warthog.procyon.org.uk> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.39]); Mon, 25 Sep 2017 14:14:55 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Eric Biggers wrote: > Fix this by removing the call to key_revoke(). key_put() is sufficient, > as it's not possible for an uninstantiated authkey to have been used for > anything yet. Note that the owner can call keyctl_describe() upon it, though that shouldn't wait because KEY_LOOKUP_PARTIAL would be specified. However, this is probably fair enough, and it should be gc'd quickly because it'll lose its last ref. David