[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210712060710.441739464@linuxfoundation.org>
Date: Mon, 12 Jul 2021 08:07:27 +0200
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-kernel@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
stable@...r.kernel.org,
Anatoly Trosinenko <anatoly.trosinenko@...il.com>,
Miklos Szeredi <mszeredi@...hat.com>
Subject: [PATCH 5.4 063/348] fuse: reject internal errno
From: Miklos Szeredi <mszeredi@...hat.com>
commit 49221cf86d18bb66fe95d3338cb33bd4b9880ca5 upstream.
Don't allow userspace to report errors that could be kernel-internal.
Reported-by: Anatoly Trosinenko <anatoly.trosinenko@...il.com>
Fixes: 334f485df85a ("[PATCH] FUSE - device functions")
Cc: <stable@...r.kernel.org> # v2.6.14
Signed-off-by: Miklos Szeredi <mszeredi@...hat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
---
fs/fuse/dev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/fuse/dev.c
+++ b/fs/fuse/dev.c
@@ -1869,7 +1869,7 @@ static ssize_t fuse_dev_do_write(struct
}
err = -EINVAL;
- if (oh.error <= -1000 || oh.error > 0)
+ if (oh.error <= -512 || oh.error > 0)
goto copy_finish;
spin_lock(&fpq->lock);
Powered by blists - more mailing lists