From fe8c195f7a5ef3e653b6eaff8863c4c94e97e28c Mon Sep 17 00:00:00 2001 From: Sebastien Buisson Date: Thu, 11 Apr 2024 08:58:19 +0200 Subject: [PATCH] LU-17724 gss: fix bad use of user buffer in rsi upcall Use the proper kernel buffer to print message out when upcall_cache_set_upcall() returns an error. Fixes: 2153e86541 ("LU-17497 obdclass: check upcall incorrect values") Test-Parameters: trivial Test-Parameters: testgroup=review-dne-selinux-ssk-part-2 Signed-off-by: Sebastien Buisson Change-Id: Ice781b4506822f1fd4ce0a062ce742f51e366525 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/54730 Reviewed-by: James Simmons Reviewed-by: Andreas Dilger Reviewed-by: Oleg Drokin Tested-by: jenkins Tested-by: Maloo --- lustre/ptlrpc/gss/lproc_gss.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lustre/ptlrpc/gss/lproc_gss.c b/lustre/ptlrpc/gss/lproc_gss.c index 4e6b9a1..1584e98 100644 --- a/lustre/ptlrpc/gss/lproc_gss.c +++ b/lustre/ptlrpc/gss/lproc_gss.c @@ -209,8 +209,8 @@ static ssize_t rsi_upcall_seq_write(struct file *file, rc = upcall_cache_set_upcall(rsicache, kbuf, count, true); if (rc) { - CERROR("%s: incorrect rsi upcall %.*s. Valid value for sptlrpc.gss.rsi_upcall is an executable pathname: rc = %d\n", - rsicache->uc_name, (int)count, buffer, rc); + CERROR("%s: incorrect rsi upcall %s. Valid value for sptlrpc.gss.rsi_upcall is an executable pathname: rc = %d\n", + rsicache->uc_name, kbuf, rc); GOTO(out, rc); } -- 1.8.3.1