Messages in this thread Patch in this message | | | Date | Tue, 7 Mar 2000 23:20:03 -0500 (EST) | From | Alexander Viro <> | Subject | [FIX]: [BUG] 2.3.50 no longer allows regular user to bind unix-domain sockets |
| |
On 8 Mar 2000, Daniel Pittman wrote:
> Between 2.3.50-pre2 and 2.3.50 something changed that caused everything > run as my regular user to fail when binding Unix-domain sockets. > > I suspect a change to `linux/fs/namei.c' is responsible, where it > introduces (as far as I can tell) a new check for CAP_MKNOD before > allowing the creation of Unix domain sockets.
Erm... The check is bogus, indeed. It used to sit in sys_mknod() (which is almost never used to create sockets) and had been moved downwards, where it actually ought to be. The only problem being that it ought to be there in correct form... Fix:
--- fs/namei.c Tue Mar 7 23:14:35 2000 +++ fs/namei.c.new Tue Mar 7 23:15:20 2000 @@ -745,7 +745,7 @@
mode &= ~current->fs->umask;
- if (!S_ISFIFO(mode) && !capable(CAP_MKNOD)) + if ((S_ISCHR(mode)||S_ISBLK(mode)) && !capable(CAP_MKNOD)) goto exit_lock;
error = may_create(dir, dentry);
Linus, apply it, please. Sorry about that... ;-< Al
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |