Age | Commit message (Collapse) | Author |
|
Switch insmod from using init_module to finit_module. From
"man finit_module":
The finit_module() system call is like init_module(), but reads the
module to be loaded from the file descriptor fd. It is useful when the
authenticity of a kernel module can be determined from its location in
the file system; in cases where that is possible, the overhead of
using cryptographically signed modules to determine the authenticity
of a module can be avoided.
finit_module is preferred over init_module because it allows LSMs, such
as SELinux, to perform a permission check on kernel module loads based on
the file from which the module is loaded. This functionality is not yet
implemented in the Linux kernel, but is on the SEAndroid TODO list.
See https://bitbucket.org/seandroid/wiki/wiki/ToDo
Bug: 27824855
Change-Id: Id0ea88cd1930393c8c73ce38e63d5b2eeadf946a
|
|
Set ro.crypto.state flag to unencrypted and unsupported accordingly
Bug: 18002358
Change-Id: I1f88ce9704c5505d7b63256e2ebe5f8441c79ad0
|
|
This ensures that all users on device follow a consistent path for
setup and validation of encryption policy.
Also add remaining user-specific directories and fix linking order.
Bug: 25796509
Change-Id: I8c2e42a78569817f7f5ea03f54b743a6661fdb9c
|
|
Change-Id: I6d986853929c0237c0d958329b8e9aab47907a00
|
|
Fix ugly special cases for user 0: initialize them explicitly.
Bug: 26704408
Change-Id: I1b8536b9e5e87ea98b4009a309f2e22c56006651
|
|
|
|
am: 436a8aa9de
* commit '436a8aa9de9c90a8ee95e02e97bf65e50c80d4f4':
Allow paths of .rc files to be specified at mount_all
|
|
In current implementation, the mount_all command imports all .rc files
under /{system,vendor,odm}/etc/init/ after mouting filesystems is complete.
There's a need from ODMs to import different .rc files under different boot
modes (e.g., factory mode). Without this support, they will have to fiddle
around the init implementation.
This commit makes mount_all import the .rc files/directories specified
as additional arguments. If no path is given, the original ones are applied
the same way as the current implementation.
BUG: 26549689
Change-Id: Ie67ce13dde4c440ff8bf534826bc392c882a433f
|
|
Changes to the way FBE works to support lifecycles mean that these
commands aren't needed any more.
Bug: 22358539
Change-Id: Id73339e0aa8070dd688f35b5d59de75236961395
|
|
am: a8c931b7f5
* commit 'a8c931b7f57c8ce74f520d591e99bb367f91dc81':
init: Allows shutting down cleanly.
|
|
When ro.build.shutdown_timeout is set, init will send a SIGTERM signal to
all services on reboot. The normal shutdown process will continue once
all services have exited or after the shutdown timeout
(ro.build.shutdown_timeout).
If ro.build.shutdown_timeout is not set, we assume a 0s timeout.
Bug: 26216447
Test: manual: Ask to reboot. All services exit cleanly.
Change-Id: If921f6e8d87211e500ac9fa86f3e1eabe02d18cf
|
|
am: 42a86f8d1e
* commit '42a86f8d1e918356e86d4eb3fb2444a8c42d25ff':
Set up dm-verity in EIO mode instead of logging mode
|
|
|
|
Needed so we can make the user0 key on first boot
Change-Id: I4699dbf2efdec44bb09bc4cfa7eeb59e56cb93ab
|
|
Change-Id: Idf9444fece4aa89c93e15640de59a91f6e758ccf
|
|
If the device is corrupted, set up dm-verity in EIO mode instead of
logging mode. This prevents corrupted blocks from being returned to
user space. Note that restart mode is used by default and a warning
will be displayed to the user after corruption is first detected.
Bug: 19277516
Change-Id: I38966d73eb814836bc34b4bad1192583e5010b36
|
|
Change-Id: I747b279bc49f9f82b8f8859c49b3fc2a4e3b4977
|
|
Create a Parser class that uses multiple SectionParser interfaces to
handle parsing the different sections of an init rc.
Create an ActionParser and ServiceParser that implement SectionParser
and parse the sections corresponding to Action and Service
classes.
Remove the legacy keyword structure and replace it with std::map's
that map keyword -> (minimum args, maximum args, function pointer) for
Commands and Service Options.
Create an ImportParser that implements SectionParser and handles the
import 'section'.
Clean up the unsafe memory handling of the Action class by using
std::unique_ptr.
Change-Id: Ic5ea5510cb956dbc3f78745a35096ca7d6da7085
|
|
systems after mount_all"
* commit '08a6775f8cdadf48e7b5f4f4d710180fda43b2b6':
init: import init rc scripts from file systems after mount_all
|
|
Import /{system,vendor,odm}/etc/init/... after file systems are mounted
Bug: 23186545
Change-Id: Idb0cae9773f904c0330054c8b3e31eb87b2fb7cb
|
|
* commit 'd1b11a04903be74ba6a47307d8c3ef2731e3f4ab':
Add |opts| argument to android_fork_execvp_ext
|
|
to allow the caller to send data to the child's stdin.
Bug: 21725996
Change-Id: I818f5cf61045286c8d64a91b6d50f05740329be1
|
|
* commit '4036f5ab2ffbe5a2e47d46aa376e9791385cc31b':
Create Service and ServiceManager classes
|
|
Change-Id: I363a5e4751ad83d2f4096882a6fbbeddca03acfe
|
|
Change-Id: Ibc802572898b6913c1f5d94aaae19974bfc0eb85
|
|
* commit '2f9e1db37416cdb580d870218b5fbfbed47a3758':
Stop calling fsck on shutdown by default
|
|
|
|
|
|
Change-Id: Ie7a64e65de3a20d0c7f7d8efc0f7c1ba121d07fe
|
|
* commit 'a21d85620560896bbed0cd43db9ed3224ab4e974':
init: Create classes for Action and Command
|
|
This creates the concept of 'event_trigger' vs 'property_trigger'
Previously these were merged into one, such that 'on property:a=b &&
property:b=c' is triggered when properties a=b and b=c as expected,
however combinations such as 'on early-boot && boot' would trigger
during both early-boot and boot. Similarly, 'on early-boot &&
property:a=b' would trigger on both early-boot and again when property
a equals b.
The event trigger distinction ensures that the first example fails to
parse and the second example only triggers on early-boot if
property a equals b.
This coalesces Actions with the same triggers into a single Action object
Change-Id: I8f661d96e8a2d40236f252301bfe10979d663ea6
|
|
builtins."
* commit 'bd5f10addfba8df40c8293d95c002044acbfa526':
init: do expand_props before calling the builtins.
|
|
Also switch expand_props to std::string.
Bug: 22654233
Change-Id: I62910d4f74e2b1a5bd2b14aea440767a2a8462b7
|
|
Change-Id: I7d7a614a5eb987ef6aecd32ed15a6eaa43e93957
|
|
Bug: 22654233
Change-Id: Id6091f58432f75e966b9871256049fbe17766c10
|
|
for mount_all"
* commit '7f12fa275604504ed874c08d6b7f906e8e522c73':
init: use init's property expansion code for mount_all
|
|
Change-Id: I3bd00c74cd126b66927eca7812943f8427009356
Signed-off-by: Nan Liu <nan.liu619@gmail.com>
|
|
Instead, run the command only when sys.powerctl is set to
"shutdown,userrequested". This way, we can avoid running
fsck when shutdown is triggered due to a low power state.
This is a follow-up CL for http://r.android.com/158525.
Bug: 21853106
Change-Id: Ie57c23cd25162cc2a8726f876a9ba212080105fb
|
|
* commit 'ab64465d1f16f414c0bde5e3c4707c32b8220bbc':
Use fsck.f2fs -a instead of -f for faster boot
|
|
and run fsck with -f on clean shutdown instead.
With -f, fsck.f2fs always performs a full scan of the /data
partition regardless of whether the partition is clean or not.
The full scan takes more than 2 seconds on volantis-userdebug
and delays the OS boot.
With -a, the command does almost nothing when the partition
is clean and finishes within 20-30ms on volantis-userdebug.
When the partition has an error or its check point has
CP_FSCK_FLAG (aka "need_fsck"), the command does exactly the
same full scan as -f to fix it.
Bug: 21853106
Change-Id: I126263caf34c0f5bb8f5e6794454d4e72526ce38
|
|
* commit 'ee923139c346e6751203fc7d2a341388e01c7b19':
Set up user directory crypto in init.
logd: switch to unordered_map from BasicHashtable
rootdir: make sure the /oem mountpoint is always available
|
|
|
|
into mnc-dr-dev
* commit 'd5ef984195779aa9e27d7baabdd751d641eea1a0':
Change init sequence to support file level encryption
|
|
File level encryption must get the key between mounting userdata and
calling post_fs_data when the directories are created. This requires
access to keymaster, which in turn is found from a system property.
Split property loaded into system and data, and load in right order.
Bug: 22233063
|
|
encryption"" into mnc-dev
* commit '8104616696ac5e806b16a393ea02c4f5d8efc328':
Revert "Change init sequence to support file level encryption"
|
|
This reverts commit d815178b7512cb44d8b5f234e3f823b5a3e44dea.
Change-Id: I7e3f55d3092fcd04ea9f62f1971c9d42570f096c
|
|
into mnc-dev
* commit 'a65e402b613e927697d35e7936c6d80908d77e88':
Change init sequence to support file level encryption
|
|
File level encryption must get the key between mounting userdata and
calling post_fs_data when the directories are created. This requires
access to keymaster, which in turn is found from a system property.
Split property loaded into system and data, and load in right order.
Bug: 22233063
Change-Id: I8a6c40d44e17de386417a443c9dfc3b4e7fe59a5
|
|
(cherry-picked from commit b94032b79c3cded501e2d5f7c328cf8c0c3911c4)
Bug: 19704432
Change-Id: Ife4928ffbee39c8ae69e6ba66d9ce5ef5a0beb76
|
|
(chery-picked from commit 806d10be2336f32cdca16c2540cbf3d548f2fec7)
Move all key management into vold
Reuse vold's existing key management through the crypto footer
to manage the device wide keys.
Use ro.crypto.type flag to determine crypto type, which prevents
any issues when running in block encrypted mode, as well as speeding
up boot in block or no encryption.
This is one of four changes to enable this functionality:
https://android-review.googlesource.com/#/c/148586/
https://android-review.googlesource.com/#/c/148604/
https://android-review.googlesource.com/#/c/148606/
https://android-review.googlesource.com/#/c/148607/
Bug: 18151196
Change-Id: I6a8a18f43ae837e330e2785bd26c2c306ae1816b
|