From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757615AbdLQXxu (ORCPT ); Sun, 17 Dec 2017 18:53:50 -0500 Received: from out3-smtp.messagingengine.com ([66.111.4.27]:50271 "EHLO out3-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756958AbdLQXxs (ORCPT ); Sun, 17 Dec 2017 18:53:48 -0500 X-ME-Sender: From: "Tobin C. Harding" To: kernel-hardening@lists.openwall.com Cc: "Tobin C. Harding" , Steven Rostedt , Tycho Andersen , Linus Torvalds , Kees Cook , Andrew Morton , Daniel Borkmann , Masahiro Yamada , Alexei Starovoitov , linux-kernel@vger.kernel.org, Network Development Subject: [PATCH 0/3] kallsyms: don't leak address Date: Mon, 18 Dec 2017 10:53:29 +1100 Message-Id: <1513554812-13014-1-git-send-email-me@tobin.cc> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This set plugs a kernel address leak that occurs if kallsyms symbol look up fails. This set was prompted by a leaking address found using scripts/leaking_addresses.pl on a PowerPC machine in the wild. Patch set does not change behaviour when KALLSYMS is not defined (suggested by Linus). RFC has been in flight for 3 weeks with no negative response. Patch 1 - return error code if symbol look up fails. Patch 2 - print to buffer if symbol look up returns an error. Patch 3 - maintain current behaviour in ftrace. Patch 3 (the ftrace stuff) is untested. thanks, Tobin. Tobin C. Harding (3): kallsyms: don't leak address when symbol not found vsprintf: print if symbol not found trace: print address if symbol not found include/linux/kernel.h | 2 ++ kernel/kallsyms.c | 6 ++++-- kernel/trace/trace.h | 24 ++++++++++++++++++++++++ kernel/trace/trace_events_hist.c | 6 +++--- lib/vsprintf.c | 18 +++++++++++++++--- 5 files changed, 48 insertions(+), 8 deletions(-) -- 2.7.4