Commit graph

473 commits

Author SHA1 Message Date
Kenny Root
5054417c10 Add /data/app-lib for native library sharing
Change-Id: I7419676d987178fd2422c50d74f966e27af9f62e
2012-09-08 22:39:44 -07:00
Jeff Sharkey
58d3980f31 Keep /mnt/secure private to default namespace.
When vold mounts things in /mnt/secure/staging, it expects to MS_MOVE
those mountpoints when vetting is finished.  However, the kernel
doesn't allow MS_MOVE when the source is shared to child namespaces.

To work around this, create a tmpfs at /mnt/secure and mark it as
private (not shared).  Verified that vold can now successfully move
from the staging area.

Bug: 7094858
Change-Id: I5e05b1005c63efa277935c9bbd18cbf3ffdd47a3
2012-09-06 14:15:46 -07:00
Mike Lockwood
35ea5e4f23 import init.${ro.hardware}.rc last to allow overriding default USB configuration
Change-Id: I2194466fb7cf7ff5313d146601155ebe6043fd42
2012-08-28 10:25:13 -07:00
Wink Saville
f824ad7b35 am 582b1152: am baba9984: Merge "Define TCP buffer sizes for HSPAP, HSDPA, HSUPA and EVDO"
* commit '582b11527cd6d968f163fbee73f92d82b679e330':
  Define TCP buffer sizes for HSPAP, HSDPA, HSUPA and EVDO
2012-08-23 14:11:35 -07:00
Jeff Sharkey
42a1e6c9d8 Merge "Iteration on multi-user external storage." into jb-mr1-dev 2012-08-22 18:17:23 -07:00
Wink Saville
582b11527c am baba9984: Merge "Define TCP buffer sizes for HSPAP, HSDPA, HSUPA and EVDO"
* commit 'baba99840400f5b835d44b6d91e2190136277988':
  Define TCP buffer sizes for HSPAP, HSDPA, HSUPA and EVDO
2012-08-22 15:32:17 -07:00
Wink Saville
baba998404 Merge "Define TCP buffer sizes for HSPAP, HSDPA, HSUPA and EVDO" 2012-08-22 15:00:00 -07:00
Jeff Sharkey
bfcd810b79 Iteration on multi-user external storage.
Define /storage as top-level concept, so that we enforce permissions
uniformly.  Moves external storage paths from headers to per-device
environment variables.  Added missing mount flags, and we no longer
have adb-specific external storage.

Bug: 6925012
Change-Id: Ic7ca953be2f552d3f0ec9e69f89fef751daa1b29
2012-08-22 14:28:37 -07:00
Jeff Sharkey
61f1359486 Remove sdcard groups from services.
Even with the groups, services no longer have access.

Change-Id: I2b4871b276ffd309c08c404b1211b33406dbebd5
2012-08-20 14:31:47 -07:00
Jeff Sharkey
5dd0f86fbf Migrate sdcard0 to shell-accessible location.
Also remove mount() from adb, since it can come online long before
data partition is ready.  Set EXTERNAL_STORAGE environment variable
to point to owner for backwards compatibility.

Bug: 7005701
Change-Id: I63444f6636624eb7ad89f053daa289663424639e
2012-08-20 13:11:11 -07:00
Jeff Sharkey
2be5338a84 Merge "Multi-user external storage support." into jb-mr1-dev 2012-08-16 14:33:00 -07:00
Scott Anderson
edb2d634b3 Merge "ueventd.rc: Add /dev/uhid for bluedroid" into jb-mr1-dev 2012-08-16 12:22:51 -07:00
Jeff Sharkey
885342a0f2 Multi-user external storage support.
Remount rootfs as recursively shared, so that mount changes are
propagated into child namespaces.  Mount external storage for access
from adb.

Clean multi-user dependencies for use in Dalvik.  Also define
external storage paths.

Bug: 6925012
Change-Id: I375de581a63f4f36667894c56a34a9dd45361e8f
2012-08-15 21:10:07 -07:00
Scott Anderson
3ad289dca6 ueventd.rc: Add /dev/uhid for bluedroid
Change-Id: Ica71265856fce1abc0a0ba9c0b1ca016510c61b7
Signed-off-by: Scott Anderson <saa@android.com>
2012-08-15 15:02:00 -07:00
Keun-young Park
847cb4d125 am 8f19b11a: am c4c731e7: Merge "[MIPS] Enable SD-card functionality to work"
* commit '8f19b11a42423ecd4ac8373041f64cb3001caf78':
  [MIPS] Enable SD-card functionality to work
2012-08-14 18:29:15 -07:00
Keun-young Park
8f19b11a42 am c4c731e7: Merge "[MIPS] Enable SD-card functionality to work"
* commit 'c4c731e78ca1a3527093a35280381616d1cb667d':
  [MIPS] Enable SD-card functionality to work
2012-08-14 18:27:25 -07:00
Keun-young Park
c4c731e78c Merge "[MIPS] Enable SD-card functionality to work" 2012-08-14 17:30:07 -07:00
Jean-Baptiste Queru
96539e8153 am ee0d281a: am c95c15b1: Merge "Char device /dev/dri/card0 was not created during startup."
* commit 'ee0d281a3e5fe611bdda23db18fa0e5684ee43ed':
  Char device /dev/dri/card0 was not created during startup.
2012-08-14 08:41:16 -07:00
Jean-Baptiste Queru
ee0d281a3e am c95c15b1: Merge "Char device /dev/dri/card0 was not created during startup."
* commit 'c95c15b1923611f48c44c18ad158e57b9d915fdf':
  Char device /dev/dri/card0 was not created during startup.
2012-08-14 08:39:22 -07:00
Jean-Baptiste Queru
c95c15b192 Merge "Char device /dev/dri/card0 was not created during startup." 2012-08-14 08:06:44 -07:00
Kenny Root
605103fb55 resolved conflicts for merge of 4dcd52ab to jb-mr1-dev
Change-Id: Ibd0c03a7883a2e31adab18543c016776b7b36866
2012-08-13 10:21:35 -07:00
Kenny Root
4dcd52ab11 am 297f802f: Merge "Add support for reloading policy from /data/system."
* commit '297f802f25d093274c1f5fb890ee8dfacfbf159e':
  Add support for reloading policy from /data/system.
2012-08-13 09:50:00 -07:00
Stephen Smalley
ae6f3d7c05 Add support for reloading policy from /data/system.
To support runtime policy management, add support for reloading
policy from /data/system.  This can be triggered by setting the
selinux.loadpolicy property to 1, whether from init.rc after
mounting /data or from the system_server (e.g. upon invocation of
a new device admin API for provisioning policy). ueventd and
installd are restarted upon policy reloads to pick up the new
policy configurations relevant to their operation.

Change-Id: I97479aecef8cec23b32f60e09cc778cc5520b691
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
2012-08-09 09:59:10 -04:00
Colin Cross
b35e36e5a9 init.rc: make last_kmsg readable only by user system and group log
chown /proc/last_kmsg to user system group log during init, and
chmod it to readable only by user and group.

Bug: 6925227
Change-Id: I645b6a2d4fecc01a2bd4b7fa7ed6aae3ef638cb9
2012-08-03 12:25:25 -07:00
Dima Zavin
35fc46d8e3 am 018227f5: am ce76e2d0: Merge "Modify init.rc and init.goldfish.rc for SE Android."
* commit '018227f5394c3126f4a858596cb85dee1893b895':
  Modify init.rc and init.goldfish.rc for SE Android.
2012-08-01 09:52:28 -07:00
Dima Zavin
018227f539 am ce76e2d0: Merge "Modify init.rc and init.goldfish.rc for SE Android."
* commit 'ce76e2d00e63339083ea693db33de05cbba5600e':
  Modify init.rc and init.goldfish.rc for SE Android.
2012-08-01 09:49:59 -07:00
Dima Zavin
ce76e2d00e Merge "Modify init.rc and init.goldfish.rc for SE Android." 2012-08-01 09:14:42 -07:00
Benoit Goby
0245e15bb7 rootdir: Create /data/misc/adb on boot
Change-Id: I0f8d11391cdcfbaa50f87f637a2962c6663b2767
2012-07-27 14:00:02 -07:00
Benoit Goby
0574d6b077 init.rc: Add socket for adbd
Change-Id: Ic97fd464440ff4a29fc9da7ad15949ac5215ade3
2012-07-26 19:01:16 -07:00
Stephen Smalley
1eee419e7a Modify init.rc and init.goldfish.rc for SE Android.
Set the security context for the init process.
Restore the security contexts of /cache and /data in case they were reset.
Specify the security context for services launched from the rootfs since
we cannot label their executables.
If on the emulator, set a policy boolean and restore the context of
/sys/qemu_trace to allow accesses not normally permitted on a device.

Change-Id: I166ffc267e8e0543732e7118eb0fd4b031efac3b
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
2012-07-26 15:37:45 -04:00
Naveen Kalla
e8b76a36ba Define TCP buffer sizes for HSPAP, HSDPA, HSUPA and EVDO
Change-Id: I0fbd76aca69059917d363b2dcbfc843bbf4386f8
2012-07-26 00:26:13 -07:00
Lukasz Anaczkowski
e6f8d45da8 Char device /dev/dri/card0 was not created during startup.
This device is required by libdrm for GPUs like IvyBridge.

Change-Id: I0ac47056a9cec2100f3e6eaa5591571fe6bbc145
Signed-off-by: Lukasz Anaczkowski <lukasz.anaczkowski@intel.com>
Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2012-07-23 16:08:17 -07:00
Wink Saville
b3a679386d Add telephony-common and mms-common to BOOTCLASSPATH - DO NOT MERGE
Change-Id: Ib113b8147d20fee1ec69d68cf6a7a02d59ff4df6
2012-07-17 12:23:40 -07:00
Matthew Xie
4c3ac516ff remove dbus and bluetoothd, create bluedroid data dirs
Change-Id: Ifacd570dbadc075e498a626935e035c76a0d83c4
2012-07-16 22:17:02 -07:00
Jeff Sharkey
5acf1d6625 am 87314036: am 55b763ff: Grant sdcard_r to ril-daemon.
* commit '873140368613af2d1c06e18ac2fd6fe24623b9bb':
  Grant sdcard_r to ril-daemon.
2012-07-13 12:18:34 -07:00
Jeff Sharkey
8731403686 am 55b763ff: Grant sdcard_r to ril-daemon.
* commit '55b763ff7b779d7ee91f245e0887332db8782afe':
  Grant sdcard_r to ril-daemon.
2012-07-13 12:16:44 -07:00
Jeff Sharkey
55b763ff7b Grant sdcard_r to ril-daemon.
Bug: 6793799
Change-Id: Ife23c98c30d7b08479d75798c7075005bf281119
2012-07-13 11:21:40 -07:00
Wink Saville
557ed7a487 Merge commit 'de016eef' into mit
* commit 'de016eef':
  Add telephony-common and mms-common to BOOTCLASSPATH
2012-07-11 17:54:19 -07:00
Wink Saville
de016eef33 Add telephony-common and mms-common to BOOTCLASSPATH
Change-Id: Ib113b8147d20fee1ec69d68cf6a7a02d59ff4df6
2012-07-02 15:49:24 -07:00
Jamie Gennis
c06be8a15d am 1e96e16f: am 0f3974c3: Merge "Enable tracing on user builds" into jb-dev
* commit '1e96e16f81ce46adf5329b1db4662b53b927d4e2':
  Enable tracing on user builds
2012-06-12 13:05:49 -07:00
Jamie Gennis
0f3974c3d0 Merge "Enable tracing on user builds" into jb-dev 2012-06-11 12:04:27 -07:00
Jamie Gennis
1279013dee Enable tracing on user builds
This change adds init.rc steps to:
 * allow kernel tracing to be enabled via adb
 * allow a limited set of kernel trace events to be enabled via adb
 * allow the kernel trace to be read via adb
 * allow all users to write to the kernel trace from userland

Bug: 6513400
Change-Id: Ic3c189b5697aa5edf88d2f507c932971bed6caff
2012-06-08 14:26:29 -07:00
Bhanu Chetlapalli
a7fbf8a673 [MIPS] Enable SD-card functionality to work
Change-Id: I711f533214b9b7bce2ff1000a55d6b8f310f2399
Signed-Off-By: Bhanu Chetlapalli <bhanu@mips.com>
2012-06-07 15:15:52 -07:00
Arve Hjønnevåg
6ba76f0190 Merge "init.rc: Set owner for /sys/power/autosleep" 2012-06-06 16:42:07 -07:00
Dima Zavin
5f2d00b067 rootdir: init.rc: remove audio app/sys groups, merge to fg
With this change, the audio rr/fifo threads will just run in
the fg cgroup.

Also, the RR budget for the apps fg/bg threads has been bumped
to 80%. Ideally, the bg budget would be much smaller but there
are legacy libraries that seem to be very sensitive to this so
for now keep it at this value.

Bug: 6528015
Change-Id: I08f295e7ba195a449b96cd79d954b0529cee8636
Signed-off-by: Dima Zavin <dima@android.com>
2012-06-04 15:11:33 -07:00
Dima Zavin
df44b88621 core: init.rc: create apps cgroup for fg tasks, move bg under it
Bug: 6538553
Change-Id: I7c29975aa376bcdda9d6bbd1fd3e04fdb1c1b1fe
Signed-off-by: Dima Zavin <dima@android.com>
2012-06-04 13:02:44 -07:00
Colin Cross
4c48025c48 Increase cpu.rt_runtime_us to 10% for fg and bg groups
GPS on yakju puts SCHED_RR threads in the fg and bg groups, and
is unhappy with 0.1% limits.  Increase the limits to 10%.

Change-Id: I971c9b0a815890d41694b965fdd2b023937a4411
2012-05-16 13:49:30 -07:00
Todd Poynor
50efaf2f7f Merge "init: Set perms for interactive cpufreq governor boostpulse" into jb-dev 2012-05-11 15:54:13 -07:00
Colin Cross
367e7b195b Increase rt_runtime_us to 1000 for foreground and bg_non_interactive
rt_runtime_us=0 can cause deadlocks if a SCHED_FIFO/SCHED_RR thread
is moved into the wrong cgroup.

Change-Id: I4633392fb529039dff6ba5d3a6b672e0de9fc2d9
2012-05-10 13:56:43 -07:00
Todd Poynor
4ff10e63c3 init: Set perms for interactive cpufreq governor boostpulse
Change-Id: Ia4b028f58f9d48bad2525744497f10884d11c5d6
2012-05-03 15:20:48 -07:00
Arve Hjønnevåg
70a163f519 init.rc: Set owner for /sys/power/autosleep
Change-Id: Ia18cce973c71e7561ca84b23e37b0b8e056a7143
2012-05-02 18:00:34 -07:00
Glenn Kasten
7e057eb004 Merge "Increase budget" into jb-dev 2012-05-01 16:18:15 -07:00
Jeff Tinker
94a55df34d Merge "Fix failure to play pinned movies" into jb-dev 2012-05-01 15:11:47 -07:00
Glenn Kasten
59e6eb0999 Increase budget
Change-Id: I6706a408990abf8d420db73280df2818b8827140
2012-05-01 13:36:32 -07:00
Jeff Tinker
65f1fbcad3 Fix failure to play pinned movies
DRM server process needs to be able to access movies on sdcard
to acquire rights.

related-to-bug: 6414503

Change-Id: If90404e32fd437b8fb7d5a6ec8dfb30a499ef733
2012-04-30 22:10:12 -07:00
Todd Poynor
33045a627d init: Set perms for cpufreq interactive governor input boost sysfs
Change-Id: Ie475c95d81635a068db11e7018895024247878b4
2012-04-27 20:28:44 -07:00
Nick Kralevich
25dd43a9a5 Restrict zygote to system user.
CVE-2011-3918: Address denial of service attack against Android's
zygote process. This change enforces that only UID=system can
directly connect to zygote to spawn processes.

Change-Id: I89f5f05fa44ba8582920b66854df3e79527ae067
2012-04-27 14:18:02 -07:00
Todd Poynor
8d3ea1d1e1 init: set perms for cpufreq interactive governor boost -- DO NOT MERGE
Change-Id: I6509cda358b4a75706afd01a5b5a36eabe492554
Signed-off-by: Todd Poynor <toddpoynor@google.com>
2012-04-25 18:20:31 -07:00
Kenny Root
f8bbaba57b Add directory for forward locked apps in ASECs
Forward locked apps on internal storage will be stored in ASEC
containers using ext4. This way permissions can be preserved whether on
internal or external storage.

Change-Id: I942f8f0743c210330a11e2b1d0204df7a5ddb2ae
2012-04-25 14:18:25 -07:00
Glenn Kasten
b91bd9f599 Update cgroups
Change-Id: If4488944e8a1c8af7b13847069d03b7ea4a30785
2012-04-23 17:36:34 -07:00
Todd Poynor
f35c203558 init.rc: Set perms for cpufreq interactive governor above_hispeed_delay
Change-Id: Ib9c3fb4e43759af590a6e033b8ba04c0023d5f07
2012-04-19 13:17:24 -07:00
Mike Lockwood
b47cd10acf Merge "init.rc: Add support for new USB accessory configurations" 2012-04-17 10:40:09 -07:00
Robert Greenwalt
5fa860dea3 Merge "Add MDNS service" 2012-04-12 16:48:11 -07:00
Todd Poynor
6a35bb3529 Merge "init.rc: Set owner and permissions for cpufreq files" 2012-04-11 15:28:57 -07:00
Todd Poynor
0653b97b25 init.rc: Set owner and permissions for cpufreq files
Change-Id: Iaaf8491915567dbe22cab1798081a00fed4fb2e2
2012-04-11 14:50:09 -07:00
Mike Lockwood
4f5d5176a3 init.rc: Add support for new USB accessory configurations
Also moved USB scripts to new file init.usb.rc

Change-Id: I98e099fbd8de3eb3e1e18c9ef69312608033a50c
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-04-11 12:35:49 -07:00
Jamie Gennis
db49739f39 Add tracing initialization to init.rc.
This change adds init.rc steps to allow kernel tracing to support inserting
messages from any userland process.

Change-Id: I01970728d7132a25408fed09a213a015ac05ccaf
2012-04-10 15:52:39 -07:00
Robert Greenwalt
1d91fcf7c0 Add MDNS service
Adds both the new service and another socket for netd.

Change-Id: Ie0271a2c48aa55217ae3fcdcc8e121b86b5a589b
2012-04-06 15:38:21 -07:00
Nick Kralevich
c8583c680a Merge "change files in /dev/log/ to 666" 2012-03-29 10:40:00 -07:00
Nick Kralevich
3439cc6145 change files in /dev/log/ to 666
With newer Android kernels, anyone can read from the files in
/dev/log. If you're in the logs group (have the READ_LOGS) permission,
you'll see all entries. If you're not in that group, you'll see
log messages associated with your UID.

Relax the permissions on the files in /dev/log/ to allow an application
to read it's own log messages.

Bug: 5748848
Change-Id: Ie740284e96a69567dc73d738117316f938491777
2012-03-29 09:32:33 -07:00
Marius Renn
71513567dc Multi-Project Commit: Move of filterfw out of system/media (6 of 7)
This is part of the multi-project commit to move the filter-framework
from system/media/mca to frameworks/base/media/mca.

Note that the filter-framework will soon be replaced with a refactored
version currently under API review (also to go under frameworks/base).
This move is done now to unblock the PDK efforts.

Change-Id: I87d034a30bb4b98a85a028cb728e37fb97256039
2012-03-27 10:56:06 -07:00
Nick Kralevich
31fb858654 Merge "drmserver: add group drm" 2012-03-26 13:06:12 -07:00
Benoit Goby
62e5cbaebc Merge "Revert "Reimplement the "adb root" command to more closely match its previous behavior"" 2012-03-26 12:56:49 -07:00
Nick Kralevich
3c9eed88c5 drmserver: add group drm
Make the drm server run as UID=drm, GID=drm. This ensures that
any files created by the drmserver app do not have GID=system.

Bug: 5834297
Change-Id: I3409ad350e9cc82bb0982cdbe470ec1f10b1ca67
2012-03-26 11:30:03 -07:00
Kenny Root
2affe824ba Merge "Put keystore into the drmrpc group" 2012-03-21 17:54:16 -07:00
Mike Lockwood
9865be95cf Merge commit '19155b5'
Do not start sshd by default

Change-Id: I22e6dbb6834321709e9b7c5ae49846d7f9f7c67a
2012-03-21 16:30:54 -07:00
Mike Lockwood
a9bb7261b4 Merge commit '9dd2eef'
sshd to init.rc

Change-Id: I8eedc3b47f1260502034067d9006cac827cb1089
2012-03-21 16:28:04 -07:00
Mike Lockwood
19155b5cd3 init.rc: Do not start sshd by default
Change-Id: Ieacd4e8fbfcd91ed2342b7a104a9b1f4114fc6d5
Signed-off-by: Mike Lockwood <lockwood@google.com>
2012-03-21 11:58:05 -07:00
Arve Hjønnevåg
1670f831a5 init.rc: Fix permissions on /sys/power/state and /sys/power/wakeup_count
Change-Id: I06a1a2affebdf64f008eaa61a0851f1e832059c5
2012-03-20 20:34:24 -07:00
Benoit Goby
7941cf87f6 Revert "Reimplement the "adb root" command to more closely match its previous behavior"
This reverts commit 535164e9d9.
2012-03-16 15:30:05 -07:00
Nick Kralevich
f3ef1271f2 init.rc: Add documentation
Android developers should never place files in /data/local/tmp.
Files or directories in /data/local/tmp can be minipulated by the
shell user.

Android developers should never create world-writable files
or directories. This is a common source of security vulnerabilities.

Change-Id: I6d2cd620ab49d8ca3f39282f7d2ed682a9ba91c3
2012-03-14 15:36:47 -07:00
Kenny Root
ad5b9c7205 Put keystore into the drmrpc group
The keystore service needs to access hardware crypto devices to
fulfill its function on devices with hardware crypto. This role
was assigned to the (now misnamed) drmrpc group.

Change-Id: Ia32f9e96b4372f0974984451680f9a0f6157aa01
2012-03-13 15:51:04 -07:00
Chia-chi Yeh
89c5926f08 am 0b32a75b: am c8d1a0e1: am 5ebced39: init.rc: update the permission of /data/local.
* commit '0b32a75b7c7f25bd9ab325f44626c402fd9b9b23':
  init.rc: update the permission of /data/local.
2012-03-08 14:31:23 -08:00
Chia-chi Yeh
c8d1a0e18e am 5ebced39: init.rc: update the permission of /data/local.
* commit '5ebced39093d1223566166b8cc6abfe6729c487d':
  init.rc: update the permission of /data/local.
2012-03-08 14:27:08 -08:00
Chia-chi Yeh
5383476727 am 5ebced39: init.rc: update the permission of /data/local.
* commit '5ebced39093d1223566166b8cc6abfe6729c487d':
  init.rc: update the permission of /data/local.
2012-03-08 14:26:47 -08:00
Chia-chi Yeh
5ebced3909 init.rc: update the permission of /data/local.
Bug: 6131945
Change-Id: I3094a471dcfb02b786f47b6778c8fed3726325ec
2012-03-07 15:13:39 -08:00
Nick Kralevich
e7fd911fd4 Restrict zygote to system user.
CVE-2011-3918: Address denial of service attack against Android's
zygote process. This change enforces that only UID=system can
directly connect to zygote to spawn processes.

Change-Id: I89f5f05fa44ba8582920b66854df3e79527ae067
2012-01-27 13:06:53 -08:00
James Dong
dae26c6ac4 am 3e9c9ac5: am 032afc1d: Merge "Close a security hole - do not give world readable/writable access to /data/drm" into ics-mr1
* commit '3e9c9ac5ee7a36653b90cb86eb6445496b536c16':
  Close a security hole - do not give world readable/writable access to /data/drm
2012-01-11 16:19:37 -08:00
James Dong
d95c615219 am 032afc1d: Merge "Close a security hole - do not give world readable/writable access to /data/drm" into ics-mr1
* commit '032afc1d52289f486538c9ed53f17b9889ea94df':
  Close a security hole - do not give world readable/writable access to /data/drm
2012-01-11 16:18:16 -08:00
James Dong
3e9c9ac5ee am 032afc1d: Merge "Close a security hole - do not give world readable/writable access to /data/drm" into ics-mr1
* commit '032afc1d52289f486538c9ed53f17b9889ea94df':
  Close a security hole - do not give world readable/writable access to /data/drm
2012-01-11 16:18:11 -08:00
Dima Zavin
f90b0e04a6 rootdir: convert all usages of $prop to ${prop}
Change-Id: Ic2472606e869d23c0f499a192cd7bb21ca3cf5b5
Signed-off-by: Dima Zavin <dima@android.com>
2012-01-11 04:36:13 -08:00
Dima Zavin
3e7b7739e3 init: import the hardware specific init file in init.rc
This removes the hardcoding of the file import in init and instead
allows the init.rc file to fully control what is loaded.

Change-Id: I933e5bbab57f1e8705a370d660f92c6508da94d2
Signed-off-by: Dima Zavin <dima@android.com>
2012-01-11 04:35:58 -08:00
Dima Zavin
683a09352a rootdir: convert all usages of $prop to ${prop}
Change-Id: Ic2472606e869d23c0f499a192cd7bb21ca3cf5b5
Signed-off-by: Dima Zavin <dima@android.com>
2012-01-10 09:37:55 -08:00
James Dong
09cdc0ea12 Close a security hole - do not give world readable/writable access to /data/drm
o related-to-bug: 5834297

Change-Id: I8e459610b4f69999be37364c2359b2bac82d4a2a
2012-01-06 15:20:20 -08:00
Dima Zavin
7634bf87cf init: import the hardware specific init file in init.rc
This removes the hardcoding of the file import in init and instead
allows the init.rc file to fully control what is loaded.

Change-Id: I933e5bbab57f1e8705a370d660f92c6508da94d2
Signed-off-by: Dima Zavin <dima@android.com>
2012-01-05 15:02:00 -08:00
Mike Lockwood
9dd2eef07b add sshd to init.rc
Change-Id: Ide6e8cca58f090e84d85d0298058c523863d1c43
Signed-off-by: Mike Lockwood <lockwood@google.com>
2011-12-29 11:48:04 -05:00
Nick Kralevich
27cca21a5d set mmap_min_addr to 32768
Bug: 5712789
Change-Id: I586a99cd63d8fba06bc2562b1cfce531ee4f554c
2011-12-06 08:31:17 -08:00
Nick Kralevich
f9557fba34 Set /proc/sys/kernel/dmesg_restrict to 1
Set dmesg_restrict to 1 to help limit inadvertent information leaks
from the kernel to non-privileged programs.  Root and programs with
CAP_SYSLOG will continue to have access to dmesg output.

See "dmesg_restrict" in Documentation/sysctl/kernel.txt from the
Linux kernel source code.

Bug: 5585365
Change-Id: Iffcf060ea4bd446ab9acf62b8b61d315d4ec4633
2011-11-08 14:46:19 -08:00
Nick Kralevich
1e339a710e Merge "Set kptr_restrict to 2." 2011-11-08 11:39:43 -08:00
Dima Zavin
3c58933aa7 am 4a253908: rootdir: init.rc: write default oom_adj before starting ueventd
* commit '4a2539085062a715b0d345eb50ea48738423c909':
  rootdir: init.rc: write default oom_adj before starting ueventd
2011-11-07 17:32:02 +00:00
Dima Zavin
4a25390850 rootdir: init.rc: write default oom_adj before starting ueventd
Otherwise, ueventd's oom_adj value would have been 0 and it could
easily get killed early during low memory events

Change-Id: I1adbd18c37215b26ae77e70f7b8dbd1e143fc2d4
Signed-off-by: Dima Zavin <dima@android.com>
2011-11-04 12:45:56 -07:00
Nick Kralevich
2e7c833279 Set kptr_restrict to 2.
To make writing kernel exploits harder, set /proc/sys/kernel/kptr_restrict
to "2". This prohibits users from accessing kernel symbols via /proc/kallsyms

Bug: 5555668
Change-Id: Ib31cb6fcb4d212a0b570ce9e73ae31f721ed801b
2011-11-02 09:24:27 -07:00
Mathias Agopian
04a875902e restart surfaceflinger and drmserver when servicemanager dies
Bug: 5450389

Change-Id: Ib4e73836721e25e2a88185167b030ea75e0d74e3
2011-10-31 14:27:47 -07:00
sinikang
8cdd4c335f am aa75df74: [maguro] : add setprop net.tcp.buffersize.hspa
* commit 'aa75df74db5beffd25821ed6c360c36197d7bac1':
  [maguro] : add setprop net.tcp.buffersize.hspa
2011-10-17 17:03:15 -07:00
sinikang
aa75df74db [maguro] : add setprop net.tcp.buffersize.hspa
-window size optimized for hspa
-Patchset2 : space removed

Change-Id: Ia4d1043d1a93c929721a4d7cca60ce9ff8bbf67a
Signed-off-by: sinikang <sinikang@samsung.com>
2011-10-17 15:56:02 -07:00
Nick Kralevich
d707fb3fb6 enable heap randomization.
Bug: 5250555

Change-Id: I7acb0645402611875c481aec33ece85fced7a336
2011-10-11 15:35:39 -07:00
Wink Saville
4e803c3c18 Merge "Add log group to rild to improve log collection on modem issue" 2011-10-10 12:24:48 -07:00
Jeffrey Tinker
f791e17bc9 Merge "Add drmrpc group to mediaserver and drmserver so they can make the drm rpc calls" 2011-10-07 19:40:35 -07:00
Jeffrey Tinker
65c4df51f8 Add drmrpc group to mediaserver and drmserver so they can make the drm rpc calls
Bug 4598045 Implementing secure video path on TI OMAP4 chip for ICS

Change-Id: Iacfe3e79f067172085b96bb4cd4484101aa5be1e
2011-10-06 18:19:46 -07:00
Kazuhiro Ondo
e65e946382 Add log group to rild to improve log collection on modem issue
Add log group to ril-daemon service. rild is the best place to
know the issue on the modem in many time. It would be helpful
if rild alone can capture the snapshot of logcat buffers at
the moment of problem.

Change-Id: Ie0dcda126fb748a00e650427de35541672359287
2011-09-30 11:53:09 -07:00
David 'Digit' Turner
a503456526 emulator: Move qemu-props to core service
The qemu-props program is launched at boot to read a series of
system property assignments from the emulator and apply them.

This is necessary to deal with the dynamic nature of the emulated
platform (e.g. the screen density which depends on the skin and
cannot be hard-coded in the platform image).

This patch ensures that qemu-props is started before any other
service that may read one of these properties (e.g. surface flinger).
This is done by encapsulating the program into a 'core' service.
Core services are all stared before regular ones.

Before the patch, qemu-props was started manually inside a script
that is called from a late emulator-specific boot service
(goldfish-setup).

The problem was that sometimes qemu-props was run too late.
This resulted in random flakiness, especially when running
on a low-end host machine.

Fix for bug 2161189 (and probably a few others)

Change-Id: I2933a25dcb5fecbb1fc238f157264e621b8f295b
2011-09-16 00:25:16 +02:00
JP Abgrall
8e3ff70444 init.rc: allow all users to open the qtaguid misc dev
The netfilter xt_qtaguid module uses a misc dev so that processes
that use the module can be tracked.
Every process that does socket tagging must open that dev.

Change-Id: I6af3e0f0180637b14455dd9607724523f142c402
2011-09-11 16:12:27 -07:00
Robert Greenwalt
1ac40f4ef1 Increase the window sizes on wifi and lte.
Set to 524288,1048576,2097152, 262144,524288,1048576.

bug:5226360
Change-Id: Id9d4257c51a355d78246b4ca59ab462fbe5b72be
2011-09-07 15:40:26 -07:00
Dima Zavin
ca47cef749 init: add charge mode handling
Introduces a 'charger' section that is processed when androidboot.mode
supplied on the kernel commandline is "charger".

In this mode, sections such as fs, post-fs, etc are skipped. Only the
'early-init' and 'init' sections of the init rc files are processed before
processing the 'charger' section.

Change-Id: If9eb6334de18f04cbcf2aab784578e2993615242
Signed-off-by: Dima Zavin <dima@android.com>
2011-09-02 12:11:18 -07:00
JP Abgrall
85e37b0a81 init: allow mediaserver to tag socket (group net_bw_acct)
The mediaserver needs to do communication on behalf of other apps
(browser, ...).
It needs to be able to tag sockets. The kernel will check for net_bw_acct
group membership.

Change-Id: I7fb063fdb7d9435d7f979df6622ff17f34049cbc
2011-08-18 00:10:06 -07:00
Dianne Hackborn
d09196d00c Merge "Activity Manager now takes care of setting OOM values." 2011-08-08 14:55:14 -07:00
Chia-chi Yeh
a24687197d init.rc: add inet permission to VPN daemons explicitly.
Racoon still needs it after dropping root privilege, or pure IPSec VPN
will fail. Mtpd works without it because net_raw implies inet. However
it would be better to set all of them clearly without the assumption.

Change-Id: I50762af2c25ec9cc559e528c7b14f469494fd553
2011-08-08 10:11:40 -07:00
Dianne Hackborn
06787f4089 Activity Manager now takes care of setting OOM values.
All init needs to do is make these files writeable so that the
activity manager can set them.

Change-Id: Ieea43208fadc01504d813be379aecbafcadf0d34
2011-08-07 16:30:24 -07:00
Mike Lockwood
7804cbf483 Move some common USB configuration logic to init.rc
Change-Id: Ib75ccfd9c4aa8aace936370c33f33a922ca3c51f
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-07-29 12:59:32 -04:00
Eric Laurent
3507616870 Fix issue 4604090: notification sound interrupted.
Removed system from mediaserver groups. Not needed anymore
now that AudioFlinger acquires wake locks via PowerManagerService.

Change-Id: I177b968a0a30557d871188bf3991b96d9b391d3c
2011-07-25 18:41:30 -07:00
Conley Owens
4a2b0fcd6e am aa4a66a1: am 1e5e2d76: am af6e3266: am d0b93f43: Merge "Create world readable, system writeable /data/resource-cache."
* commit 'aa4a66a16dd9b97fb876bb296366442b8745a10b':
  Create world readable, system writeable /data/resource-cache.
2011-07-15 14:12:23 -07:00
Conley Owens
aa4a66a16d am 1e5e2d76: am af6e3266: am d0b93f43: Merge "Create world readable, system writeable /data/resource-cache."
* commit '1e5e2d7673a9ea915283f6626fa692cc169b0e67':
  Create world readable, system writeable /data/resource-cache.
2011-07-15 11:30:44 -07:00
Chia-chi Yeh
56286d6fdb Merge "init: update permissions for VPN." 2011-07-10 16:16:06 -07:00
Chia-chi Yeh
9bb4d411e0 init: update permissions for VPN.
VPN no longer uses system properties to keep network parameters.
Besides, profiles are now stored and encrypted by keystore.

Change-Id: I7575f04f350b7d8d5ba7008eb874a72180d057e8
2011-07-08 20:03:03 -07:00
Chia-chi Yeh
50d9819ef4 Merge "init: clean up init.rc as now mkdir handles EEXIST." 2011-07-08 19:26:45 -07:00
Chia-chi Yeh
ea74414159 init: clean up init.rc as now mkdir handles EEXIST.
Change-Id: I3fa2a618ef27197315fc128738a284ac644e86c0
2011-07-08 16:52:18 -07:00
Eric Laurent
f48fd5d403 Temporary workaround for issue 4604090
There was a regression caused by a change in Honeycomb that removed
mediaserver process from system group to improve security: This prevents
the audio HAL (which runs in mediaserver process) from taking wake locks
while audio is playing thus causing the pcm stream to get unexpectedly
suspended.

This temporary workaround is just to allow ICS dogfood in better conditions until
a real fix taking into account the security issue is implemented.

Change-Id: Ic19a23da4b4383559188b6f5c3a82604c3d95d74
2011-07-07 11:45:59 -07:00
Mike Lockwood
e89675584d Merge "init.rc: Allow system process to configure RNDIS USB ethernet address" 2011-07-06 17:53:56 -07:00
Mathias Agopian
64416c816c Merge "don't restart surfaceflinger when the window manager dies" 2011-07-06 11:10:41 -07:00
Mike Lockwood
9350a00ce6 init.rc: Allow system process to configure RNDIS USB ethernet address
Change-Id: Id339d8359e592dbc1279e423d9a5adc3a775949d
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-07-06 12:45:49 -04:00
Mathias Agopian
b4daef4531 don't restart surfaceflinger when the window manager dies
Change-Id: Ia3c60e6c5471e2b72d53c936de44b730c68095e0
2011-07-01 17:11:51 -07:00
Brian Carlstrom
856f63c0df Merge "Revert "Add keychain user"" 2011-07-01 13:43:33 -07:00
Eino-Ville Talvala
1c9a996c50 Add mobile filter framework library into the bootclasspath.
Change-Id: Ia9ae45de5d58ba5e98821fd04add96c6062c1a18
2011-07-01 10:30:01 -07:00
Brian Carlstrom
0491893023 Revert "Add keychain user"
This reverts commit 6541ef1562.

Bug:4970237
Change-Id: I23a90eb89c1d19893d2ba7065fc624c0521cb06e
2011-07-01 09:50:31 -07:00
vidya rao
9d94942bcd am 6a18a077: am 04cf629b: Move RILD to class main
* commit '6a18a07774123c409cefd9a92f1c4c6504f4edfd':
  Move RILD to class main
2011-06-27 14:15:33 -07:00
vidya rao
6a18a07774 am 04cf629b: Move RILD to class main
* commit '04cf629be5e99a3a920aecc0b059444bd07e9d84':
  Move RILD to class main
2011-06-24 22:54:11 -07:00
vidya rao
04cf629be5 Move RILD to class main
-- This is needed so the modems (LTE & CDMA) are powered on and running
   before unlocking encrypted devices

Change-Id: I842f5286499fd76abc554ded550fb837d12b324e
2011-06-24 16:41:29 -07:00
Mike Lockwood
535164e9d9 Reimplement the "adb root" command to more closely match its previous behavior
The adb gadget driver used to reset the USB bus when the adbd daemon exited,
and the host side adb relied on this behavior to force it to reconnect
with the new adbd instance after init relaunches it.  The new gadget
drivers no longer automatically reset the USB bus when adbd is restarted
which caused adb to hang since it was no longer forced to reconnect with the
device.  We attempted to work around this on the host side adb, but that
work around has not been reliable.

This change adds a property trigger on the service.adb.root system property
which will reset the USB bus and restart the adbd daemon when adbd sets
the property to 1.  This should be much closer to the previous behavior
and will hopefully fix some problems with automated testing.

Change-Id: I177c37400009a3d83f21a5f9431f94fd1cc19b9b
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-06-22 08:36:53 -04:00
Mike Lockwood
352dfdfaea init.rc: Changes for new USB gadget drivers
Change-Id: I68fcf167c9fc71bb5f44793648a35d3181fd36d7
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-06-17 15:53:58 -04:00
Mårten Kongstad
b45280d259 Create world readable, system writeable /data/resource-cache.
/data/resource-cache is used to store idmap files.

Change-Id: I9b1dbc8d607333b71c05f55a4a402ae92193c36c
2011-05-31 15:41:15 +02:00
jeffhao
2b8f76cdbb Tracking merge of dalvik-dev to master
Reordered bootclasspath to allow verification of all framework methods.
  git cherry-pick --no-commit  ec164a0170955fe63106c2576a65bc4ffb1df425

Address CVE-2011-1090.
  git cherry-pick --no-commit  3365288d3c00072689cd9d733e055561cadc87b5

Change-Id: I6a89bc600ced06a0cb84ae1670cb7a6ea39de9c8
2011-05-27 00:50:44 -07:00
Brian Carlstrom
70080d97cf Merge "Make CertInstaller installed CA certs trusted by applications via default TrustManager (6 of 6)" 2011-05-17 10:37:56 -07:00
Brian Carlstrom
a31a351182 Make CertInstaller installed CA certs trusted by applications via default TrustManager (6 of 6)
frameworks/base

        Adding IKeyChainService APIs for CertInstaller and Settings use
    	keystore/java/android/security/IKeyChainService.aidl

    libcore

        Improve exceptions to include more information
    	luni/src/main/java/javax/security/auth/x500/X500Principal.java

        Move guts of RootKeyStoreSpi to TrustedCertificateStore, leaving only KeyStoreSpi methods.
        Added support for adding user CAs in a separate directory for system.
        Added support for removing system CAs by placing a copy in a sytem directory
    	luni/src/main/java/org/apache/harmony/xnet/provider/jsse/RootKeyStoreSpi.java
    	luni/src/main/java/org/apache/harmony/xnet/provider/jsse/TrustedCertificateStore.java

        Formerly static methods on RootKeyStoreSpi are now instance methods on TrustedCertificateStore
    	luni/src/main/java/org/apache/harmony/xnet/provider/jsse/TrustManagerImpl.java

        Added test for NativeCrypto.X509_NAME_hash_old and X509_NAME_hash
        to make sure the implementing algorithms doe not change since
        TrustedCertificateStore depend on X509_NAME_hash_old (OpenSSL
        changed the algorithm from MD5 to SHA1 when moving from 0.9.8 to
        1.0.0)

    	luni/src/test/java/org/apache/harmony/xnet/provider/jsse/NativeCryptoTest.java

        Extensive test of new TrustedCertificateStore behavior
    	luni/src/test/java/org/apache/harmony/xnet/provider/jsse/TrustedCertificateStoreTest.java

        TestKeyStore improvements
        - Refactored TestKeyStore to provide simpler createCA method (and
          internal createCertificate)
        - Cleaned up to remove use of BouncyCastle specific X509Principal
          in the TestKeyStore API when the public X500Principal would do.
        - Cleaned up TestKeyStore support methods to not throw Exception
          to remove need for static blocks for catch clauses in tests.

    	support/src/test/java/libcore/java/security/TestKeyStore.java
    	luni/src/test/java/libcore/java/security/KeyStoreTest.java
    	luni/src/test/java/org/apache/harmony/xnet/provider/jsse/NativeCryptoTest.java

        Added private PKIXParameters contructor for use by
        IndexedPKIXParameters to avoid wart of having to lookup and pass
        a TrustAnchor to satisfy the super-class sanity check.

    	luni/src/main/java/org/apache/harmony/xnet/provider/jsse/TrustManagerImpl.java
    	luni/src/main/java/org/apache/harmony/xnet/provider/jsse/IndexedPKIXParameters.java
    	luni/src/main/java/java/security/cert/PKIXParameters.java

    packages/apps/CertInstaller

        Change CertInstaller to call IKeyChainService.installCertificate
        for CA certs to pass them to the KeyChainServiceTest which will
        make them available to all apps through the
        TrustedCertificateStore. Change PKCS12 extraction to use AsyncTask.

    	src/com/android/certinstaller/CertInstaller.java

        Added installCaCertsToKeyChain and hasCaCerts accessor for use by
        CertInstaller. Use hasUserCertificate() internally. Cleanup coding
        style.

    	src/com/android/certinstaller/CredentialHelper.java

    packages/apps/KeyChain

        Added MANAGE_ACCOUNTS so that IKeyChainService.reset
        implementation can remove KeyChain accounts.

    	AndroidManifest.xml

        Implement new IKeyChainService methods:
        - Added IKeyChainService.installCaCertificate to install certs
          provided by CertInstaller using the TrustedCertificateStore.
        - Added IKeyChainService.reset to allow Settings to remove the
          KeyChain accounts so that any app granted access to keystore
          credentials are revoked when the keystore is reset.

    	src/com/android/keychain/KeyChainService.java

    packages/apps/Settings

        Changed com.android.credentials.RESET credential reset action to
        also call IKeyChainService.reset to remove any installed user CAs
        and remove KeyChain accounts to have AccountManager revoke
        credential granted to private keys removed during the RESET.

    	src/com/android/settings/CredentialStorage.java

        Added toast text value for failure case

    	res/values/strings.xml

    system/core

        Have init create world readable /data/misc/keychain to allow apps
        to access user added CA certificates installed by the CertInstaller.

    	rootdir/init.rc

Change-Id: I768ca8e8e990ff333ce0f7069a0935173498c5ed
2011-05-16 18:05:23 -07:00
Chia-chi Yeh
69f43c90cb Update the device permission of /dev/tun.
Change-Id: Ie8ad60047fc7160997100bd28a0abb439406806a
2011-05-12 13:43:34 -07:00
David 'Digit' Turner
7db617efc0 resolved conflicts for merge of b013bfc1 to honeycomb-plus-aosp
Change-Id: I159dd58c403bc38f9637163d8cd5e6270e4f201c
2011-04-29 13:31:31 +02:00
David 'Digit' Turner
b013bfc171 am 52a64057: Merge "ueventd.rc: Move /dev/qemu_trace to ueventd.goldfish.rc"
* commit '52a64057b60b0ad242e95fdc285ec60e0191d5b5':
  ueventd.rc: Move /dev/qemu_trace to ueventd.goldfish.rc
2011-04-28 02:30:33 -07:00
David 'Digit' Turner
f431d0499b ueventd.rc: Move /dev/qemu_trace to ueventd.goldfish.rc
+ Add /dev/qemu_pipe line for QEMU pipes.

Change-Id: If3c5c675bfc1585a1d6ffcd1042aaedbc2e94763
2011-04-26 18:07:45 +02:00
Jeffrey Tinker
f642c3d12f Make drmserver's primary group be system, so setgid is not required in ueventd.stingray.rc
Change-Id: Ie8a287620d22b5c1bdc459fb288b7403589ab474
2011-03-17 10:55:05 -07:00
Glenn Kasten
cfce282678 Bug 4089635 mediaserver fewer supplementary groups
Change-Id: I90111567564397ca08e87dcfcbdf23337bf79ae6
2011-03-14 11:43:45 -07:00
Glenn Kasten
b7b770dd76 Bug 4086255 drmserver process needs system group
Change-Id: If9a325b9e716abe00f3ad6f20b012861308abd2d
2011-03-11 14:33:11 -08:00