lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230420215331.88326-2-junxiao.bi@oracle.com>
Date:   Thu, 20 Apr 2023 14:53:31 -0700
From:   Junxiao Bi <junxiao.bi@...cle.com>
To:     linux-kernel@...r.kernel.org,
        linux-security-module@...r.kernel.org, linux-block@...r.kernel.org
Cc:     paul@...l-moore.com, nathanl@...ux.ibm.com, axboe@...nel.dk,
        jmorris@...ei.org, serge@...lyn.com, konrad.wilk@...cle.com,
        joe.jin@...cle.com, junxiao.bi@...cle.com
Subject: [PATCH V4 2/2] blktrace: allow access trace file in lockdown mode

blktrace trace files are per-cpu relay files that are used by kernel to
export IO metadata(IO events, type, target disk, offset and len etc.) to
userspace, no data from IO itself will be exported. Bypass lockdown for
these files will make blktrace work in lockdown mode.

Signed-off-by: Junxiao Bi <junxiao.bi@...cle.com>
---
 kernel/trace/blktrace.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c
index d5d94510afd3..e1a9f8b7d710 100644
--- a/kernel/trace/blktrace.c
+++ b/kernel/trace/blktrace.c
@@ -490,10 +490,16 @@ static struct dentry *blk_create_buf_file_callback(const char *filename,
 					&relay_file_operations);
 }
 
+static bool blk_bypass_lockdown(struct inode *inode)
+{
+	return true;
+}
+
 static const struct rchan_callbacks blk_relay_callbacks = {
 	.subbuf_start		= blk_subbuf_start_callback,
 	.create_buf_file	= blk_create_buf_file_callback,
 	.remove_buf_file	= blk_remove_buf_file_callback,
+	.bypass_lockdown	= blk_bypass_lockdown,
 };
 
 static void blk_trace_setup_lba(struct blk_trace *bt,
-- 
2.24.3 (Apple Git-128)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ