On Fri, 16 Feb 2001, Bruce Evans wrote:
What is it you're trying to accomplish here, exactly? Is it prevent paths
MNAMELEN to be used as targets of mounting operations? Or is it to
truncate strings reported via statfs to some arbitrary bound? If it's the
It is to not permit mount()
In mount.h, we have a #define MNAMELEN80
and in struct statfs {} we have:
charf_mntonname[MNAMELEN]; /* directory on which mounted */
but the kernel does no check to see if the mountpath is longer
than MNAMELEN, it just accepts it ? It's impossible to umount(8)
it, because
This looks right, except that Bruce says that SCARG isn't to be
used, instead just use uap-path.
-Alfred
* Martin Blapp [EMAIL PROTECTED] [010215 09:46] wrote:
In mount.h, we have a #define MNAMELEN80
and in struct statfs {} we have:
charf_mntonname[MNAMELEN]; /* directory
* Alfred Perlstein [EMAIL PROTECTED] [010215 10:15] wrote:
This looks right, except that Bruce says that SCARG isn't to be
used, instead just use uap-path.
Also, you can't call strlen on a userland pointer. please test patches
before submitting them!
-Alfred
* Martin Blapp [EMAIL
As has been pointed out, this is simply incorrect due to an attempt to use
kernel string operators on a string in the kernel address space. Generally
speaking, it's a bad idea to explicitly perform string activities on
userland strings, instead, to rely on the bounds checking in copyinstr()
and
On Thu, 15 Feb 2001, Robert Watson wrote:
As has been pointed out, this is simply incorrect due to an attempt to use
kernel string operators on a string in the kernel address space. Generally
speaking, it's a bad idea to explicitly perform string activities on
userland strings, instead, to