Re: mount --bind accounting

Alexander Viro (viro@math.psu.edu)
Sun, 3 Jun 2001 20:18:57 -0400 (EDT)


On Sun, 3 Jun 2001 Andries.Brouwer@cwi.nl wrote:

> Something entirely different.
>
> Last year I added the comment
> /* No capabilities? What if users do thousands of these? */
> in super.c for "mount --bind".
> Now that I do some polishing there I noticed the comment again.
>
> Each bind does an alloc_vfsmnt() and hence takes some kernel memory.
> Any user can therefore take all kernel memory, until
> kmalloc(sizeof(struct vfsmount), GFP_KERNEL)
> fails. Bad security.
> I suppose something needs to be done about that.

Like looking at mount_is_safe(), maybe?

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/