History log of /system/core/fs_mgr/fs_mgr.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
397a3642145dbd0919f8148ff24f0cafe1714b55 24-Sep-2013 Rom Lemarchand <romlem@google.com> fs_mgr: check that fstab is not NULL in fs_mgr_free_fstab

Make sure fstab is not NULL before freeing it

Bug: 10911605
Change-Id: I549c0a470dd183fb15a2f3c5cf4f3dd393b6e307
/system/core/fs_mgr/fs_mgr.c
4eaf905858c6a1d7cf0639bed3e8de3bd7987646 19-Sep-2013 Ken Sumrall <ksumrall@android.com> Create a separate copy of the fsck logs

The log_target parameter of android_fork_execvp_ext() is now a
bit field, and multiple targets can be set to log to multiple
places at the same time.

The new target LOG_FILE will log to a file specified by the new
parameter file_path.

Set LOG_FILE and log to a file in /dev (the only writable filesystem
avilable when e2fsck runs) when invoking e2fsck in fs_mgr.

Bug: 10021342

Change-Id: I63baf644cc8c3afccc8345df27a74203b44d0400
/system/core/fs_mgr/fs_mgr.c
887f2892062c64fa688fc9525ebd09cc98ca70d8 12-Sep-2013 Ken Sumrall <ksumrall@android.com> New fstab flags to support more expressive SD card permissions

Bug: 10330128

Change-Id: I41fb178b839487b604762fbc1ccba097d25c7aa0
/system/core/fs_mgr/fs_mgr.c
3ad3d1c4b5856d4e314febc5671c74e78a76db00 23-Feb-2013 Geremy Condra <gcondra@google.com> Add basic verity support to fs_mgr.

This change adds a "verify" fs_mgr flag specifying that
the device in question should be verified.

Devices marked with this flag are expected to have a
footer immediately after their data containing all
the information needed to set up a verity instance.

Change-Id: I10101f2c3240228ee0932e3767fe35e673d2e720
/system/core/fs_mgr/fs_mgr.c
5bc31a2632f453e03edac714b865773970bba608 09-Jul-2013 Ken Sumrall <ksumrall@android.com> Add support for swap entries in fstab

Swap entries can optionally specify a swapprio= or zramsize= flag
in the fs_mgr flags field.

Change-Id: I30530501efd4112af4e158898a9f65f6443c4fdb
/system/core/fs_mgr/fs_mgr.c
e18c0d508a6d8b4376c6f0b8c22600e5aca37f69 17-Apr-2013 Nick Kralevich <nnk@google.com> fs_mgr: make block devices read-only

When a filesystem is mounted read-only, make the underlying
block device read-only too. This helps prevent an attacker
who is able to change permissions on the files in /dev
(for example, symlink attack) from modifying the block device.

In particular, this change would have stopped the LG Thrill / Optimus
3D rooting exploit
(http://vulnfactory.org/blog/2012/02/26/rooting-the-lg-thrill-optimus-3d/)
as that exploit modified the raw block device corresponding to /system.

This change also makes UID=0 less powerful. Block devices cannot
be made writable again without CAP_SYS_ADMIN, so an escalation
to UID=0 by itself doesn't give full root access.

adb/mount: Prior to mounting something read-write, remove the
read-only restrictions on the underlying block device. This avoids
messing up developer workflows.

Change-Id: I135098a8fe06f327336f045aab0d48ed9de33807
/system/core/fs_mgr/fs_mgr.c
bf021b4cd760a48b38c58347a35157180593c4b8 20-Mar-2013 Ken Sumrall <ksumrall@android.com> fs_mgr: Capture the output of e2fsck and add to the kernel log

Currently, the output of e2fsck is not saved, and we have no insight
into how many errors e2fsck is finding and fixing. Using the new
abbreviated logging feature in liblogwrap, up to the first 100 lines,
and last 4K bytes of the output of e2fsck is captured by fs_mgr, and
added to the kernel log.

Usually, the filesystem will be clean, and this will only add a few
lines to the kernel log on boot, but when things go wrong, it should
save enough to indicate what the problem is, without potentially
filling the kernel log with only e2fsck output if the filesystem is
really corrupted.

Change-Id: I9c264798e6fe721c8f818b5ce15d0975027ddbdd
/system/core/fs_mgr/fs_mgr.c
6c2c121386f5e19ed74dc8d706bcb1e6f65fc1ba 23-Feb-2013 Ken Sumrall <ksumrall@android.com> fs_mgr: add support for new recoveryonly flag

If a device has an ext4 partition that contains the radio
firmware, and that filesystem is not mounted in normal
operation, we need a flag to prevent mount_all from
mounting it, so the new flag recoveryonly was added.

Change-Id: I361800c494e751b04c4faf956870f15fd0d8fe20
/system/core/fs_mgr/fs_mgr.c
ab6b852235d99d752678312c155a3f1c140fb483 13-Feb-2013 Ken Sumrall <ksumrall@android.com> fs_mgr: support a unified fstab format.

Update fs_mgr to support more flags needed to unify the 3
fstabs currently in android into one.

Change-Id: Ie46cea61a5b19882c55098bdd70f39e78fb603be
/system/core/fs_mgr/fs_mgr.c
1626b98c5b1d4755f0f146698d487732dcc0a2cc 12-Nov-2012 Ken Sumrall <ksumrall@android.com> am 7fd51b36: am b20fa762: Merge "Fix fs_mgr to properly invoke e2fsck on encrypted devices" into jb-mr1.1-dev

* commit '7fd51b36dabedee4de159213237e71ba20865812':
Fix fs_mgr to properly invoke e2fsck on encrypted devices
d42d327c176d5819423f4bf9e211bb12bb5dde72 07-Nov-2012 Ken Sumrall <ksumrall@android.com> Fix fs_mgr to properly invoke e2fsck on encrypted devices

Change-Id: Ie220f5cb7b614a48ec8afe66f4721ede3a368166
/system/core/fs_mgr/fs_mgr.c
07266528740d860ed42ea881214e44cd0411bd6a 27-Sep-2012 Elliott Hughes <enh@google.com> am cfd7c2a0: am 1c0c5250: Merge "Rename getline to fs_getline for fs_mgr"

* commit 'cfd7c2a05166a3ff27b2145b007834408d95a2e0':
Rename getline to fs_getline for fs_mgr
cfd7c2a05166a3ff27b2145b007834408d95a2e0 27-Sep-2012 Elliott Hughes <enh@google.com> am 1c0c5250: Merge "Rename getline to fs_getline for fs_mgr"

* commit '1c0c52503dcedff1a75775bf8bfffe7ec77b722b':
Rename getline to fs_getline for fs_mgr
295b82bd691d413c07665c7e7607fe0e5d3485f5 27-Aug-2012 Irina Tirdea <irina.tirdea@intel.com> Rename getline to fs_getline for fs_mgr

fs_mgr defines its own version of getline and uses it
internally. This leads to a build error if getline is
also defined in bionic, since fs_mgr will see readline
as defined internally.

Rename getline in fs_mgr to a local name (fs_getline)
so that there will no longer be any conflicts.

This is needed it we want to add getline in bionic.

Change-Id: I3a32be71a645e122629802d98ff8f9ab9c419e86
Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
/system/core/fs_mgr/fs_mgr.c
e50ac5f7771872331df70251d23d6bd8155da4a7 14-Aug-2012 Jeff Sharkey <jsharkey@android.com> Support shared-subtree and bind mount flags.

Bug: 6925012
Change-Id: Id8d887d17c6b1b2f90cfd1a1de991ccaba730b7d
/system/core/fs_mgr/fs_mgr.c
5dc5bfefa078f2aded34f85db4613ba91ad49b76 24-Jul-2012 Ken Sumrall <ksumrall@android.com> Mount/unmount filesystems before running e2fsck

This works around a performance problem in the firmware of
some emmc chips.

Change-Id: Ia414b4604d11e47ce9cb3f86ac82602e081bb09e
/system/core/fs_mgr/fs_mgr.c
c1bf89663ca71949b508007d4df2b5b06038f96d 07-Jan-2012 Ken Sumrall <ksumrall@android.com> A filesystem manager library to mount filesystems for init.

Instead of specifying in init what to mount, and having various hacks in init
itself to deal with encryption, use a filesystem manager library to do the
work, that can also be invoked by vold when mounting an encrypted volume.
Keep all the magic filesystem info an a device specific fstab file.

Change-Id: Ib988f1e4fb0638ba1d5fd98407fa6d8cf862aaca
/system/core/fs_mgr/fs_mgr.c