Whamcloud - gitweb
LU-17724 gss: fix bad use of user buffer in rsi upcall 30/54730/3
authorSebastien Buisson <sbuisson@ddn.com>
Thu, 11 Apr 2024 06:58:19 +0000 (08:58 +0200)
committerOleg Drokin <green@whamcloud.com>
Tue, 23 Apr 2024 19:57:39 +0000 (19:57 +0000)
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 <sbuisson@ddn.com>
Change-Id: Ice781b4506822f1fd4ce0a062ce742f51e366525
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/54730
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/ptlrpc/gss/lproc_gss.c

index 4e6b9a1..1584e98 100644 (file)
@@ -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);
        }