From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.linuxfoundation.org ([140.211.169.12]:46756 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751117AbdIPB2u (ORCPT ); Fri, 15 Sep 2017 21:28:50 -0400 Subject: Patch "thunderbolt: Make key root-only accessible" has been added to the 4.13-stable tree To: yehezkel.bernat@intel.com, gregkh@linuxfoundation.org, mika.westerberg@linux.intel.com Cc: , From: Date: Fri, 15 Sep 2017 18:28:47 -0700 Message-ID: <1505525327207228@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org List-ID: This is a note to let you know that I've just added the patch titled thunderbolt: Make key root-only accessible to the 4.13-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: thunderbolt-make-key-root-only-accessible.patch and it can be found in the queue-4.13 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >>From 0956e41169222822d3557871fcd1d32e4fa7e934 Mon Sep 17 00:00:00 2001 From: "Bernat, Yehezkel" Date: Tue, 15 Aug 2017 08:19:12 +0300 Subject: thunderbolt: Make key root-only accessible From: Bernat, Yehezkel commit 0956e41169222822d3557871fcd1d32e4fa7e934 upstream. Non-root user may read the key back after root wrote it there. This removes read access to everyone but root. Signed-off-by: Yehezkel Bernat Acked-by: Mika Westerberg Signed-off-by: Greg Kroah-Hartman --- drivers/thunderbolt/switch.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/thunderbolt/switch.c +++ b/drivers/thunderbolt/switch.c @@ -826,7 +826,7 @@ static ssize_t key_store(struct device * mutex_unlock(&switch_lock); return ret; } -static DEVICE_ATTR_RW(key); +static DEVICE_ATTR(key, 0600, key_show, key_store); static ssize_t nvm_authenticate_show(struct device *dev, struct device_attribute *attr, char *buf) Patches currently in stable-queue which might be from yehezkel.bernat@intel.com are queue-4.13/thunderbolt-make-key-root-only-accessible.patch queue-4.13/thunderbolt-remove-superfluous-check.patch queue-4.13/thunderbolt-allow-clearing-the-key.patch