On Tue, Dec 08, 2015 at 08:09:47AM -0700, Theo de Raadt wrote:
Currently, it's possible, (as root), to do something like:

# mount_mfs -s 1g swap /

which succeeds, and mounts the empty filesystem as the root filesystem.

This makes the machine inoperable and requires a physical reset, without a 
clean shutdown, as no system binaries are available.

Shouldn't we make mount_mfs error out in this case?

what is "this case"?

mount_mfs as opposed to mount.

It's possible to mount a regular filesystem on a mount point that is
already in use, except for /, which fails with an error.

The behaviour of mount_mfs is inconsistent with that of mount, in
that it allows the root directory to be used as a mount point, whereas
mount does not.

As otto points out, using with -P is potentially useful, but without
there doesn't appear to be a use case.

--
Tati Chevron
Perl and FORTRAN specialist.
SWABSIT development and migration department.
http://www.swabsit.com

Reply via email to