Skip to content

Commit 6b47ab8

Browse files
committed
io_uring: use correct pointer for io_uring_show_cred()
Previous commit changed how we index the registered credentials, but neglected to update one spot that is used when the personalities are iterated through ->show_fdinfo(). Ensure we use the right struct type for the iteration. Reported-by: syzbot+a6d494688cdb797bdfce@syzkaller.appspotmail.com Fixes: 1e6fa52 ("io_uring: COW io_identity on mismatch") Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent ef9865a commit 6b47ab8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

fs/io_uring.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8974,7 +8974,8 @@ SYSCALL_DEFINE6(io_uring_enter, unsigned int, fd, u32, to_submit,
89748974
#ifdef CONFIG_PROC_FS
89758975
static int io_uring_show_cred(int id, void *p, void *data)
89768976
{
8977-
const struct cred *cred = p;
8977+
struct io_identity *iod = p;
8978+
const struct cred *cred = iod->creds;
89788979
struct seq_file *m = data;
89798980
struct user_namespace *uns = seq_user_ns(m);
89808981
struct group_info *gi;

0 commit comments

Comments
 (0)