- Dec 12, 2016
-
-
Treehugger Robot authored
-
Treehugger Robot authored
-
Treehugger Robot authored
-
- Dec 10, 2016
-
-
Jeff Sharkey authored
-
Nick Kralevich authored
This is unused by core policy and by any device policy except for hikey. Test: device boots Test: no denials ever collected Change-Id: I36a6790499e4aeedd808457b43fd72370fa48e53
-
Nick Kralevich authored
Because I'm nitpicky. Test: policy compiles Change-Id: I4d886d0d6182d29d7b260cf1f142c47cd32eda29
-
Nick Kralevich authored
Test: no denials showing up in log collection Test: device boots Bug: 28760354 Change-Id: I089cfcf486464952fcbb52cce9f6152caf662c23
-
Nick Kralevich authored
Remove domain_deprecated and add denials picked up by log collection. Addresses the following auditallow messages: avc: granted { search } for comm="debuggerd" name="arm" dev="sda35" ino=57521 scontext=u:r:debuggerd:s0 tcontext=u:object_r:apk_data_file:s0 tclass=dir avc: granted { read } for comm="debuggerd" path="/data/app/dji.pilot-Z6Q2X6YjYNN2Ag8otZTCdg==/lib/arm/libtpnsWatchdog.so" dev="sda35" ino=57854 scontext=u:r:debuggerd:s0 tcontext=u:object_r:apk_data_file:s0 tclass=file avc: granted { getattr } for comm="debuggerd64" path="/data/app/com.google.android.youtube-2/lib/arm64/libcronet.so" dev="sda35" ino=1384657 scontext=u:r:debuggerd:s0 tcontext=u:object_r:apk_data_file:s0 tclass=file avc: granted { read open } for comm="debuggerd" path="/data/app/dji.pilot-We9wJivxEqhzfdtQrNFvaA==/lib/arm/libtpnsWatchdog.so" dev="sda35" ino=57575 scontext=u:r:debuggerd:s0 tcontext=u:object_r:apk_data_file:s0 tclass=file Bug: 28760354 Test: Device boots Test: No unexpected denials in denial collection logs. Change-Id: I1ae6203e37ddd4a19551d8063d26071ac20f2f3e
-
- Dec 09, 2016
-
-
Jeff Sharkey authored
After a series of recent commits, installd has fully migrated over to Binder, and all socket-based communication has been removed. Test: builds, boots, apps install fine, pre-OTA dexopt works Bug: 13758960, 30944031 Change-Id: Ia67b6260de58240d057c99b1bbd782b44376dfb5
-
- Dec 08, 2016
-
-
dcashman authored
app_domain was split up in commit: 2e00e637 to enable compilation by hiding type_transition rules from public policy. These rules need to be hidden from public policy because they describe how objects are labeled, of which non-platform should be unaware. Instead of cutting apart the app_domain macro, which non-platform policy may rely on for implementing new app types, move all app_domain calls to private policy. (cherry-pick of commit: 76035ea0) Bug: 33428593 Test: bullhead and sailfish both boot. sediff shows no policy change. Change-Id: I4beead8ccc9b6e13c6348da98bb575756f539665
-
Treehugger Robot authored
-
Treehugger Robot authored
-
- Dec 07, 2016
-
-
Nick Kralevich authored
Addresses the following denial: avc: denied { ioctl } for comm="top" path="/dev/pts/0" dev="devpts" ino=3 ioctlcmd=5402 scontext=u:r:shell:s0 tcontext=u:object_r:devpts:s0 tclass=chr_file permissive=0 Bug: 33073072 Bug: 7530569 Test: policy compiles. Change-Id: If9178d29f2295be46bb118df00ebf73a6ebc9f81
-
Treehugger Robot authored
-
Nick Kralevich authored
This functionality is being used by priv_apps shipped as part of Android. Don't drop execute_no_trans as we haven't seen any denials here yet. Addresses the following auditallow messages: avc: granted { execute } for comm="GELServices-0" path="/data/data/com.google.android.googlequicksearchbox/files/velour/dex_cache/Ji1opKyKASKEOKNQUu1QyWw_1.jar/Ji1opKyKASKEOKNQUu1QyWw_1.dex" dev="dm-2" ino=1196939 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:app_data_file:s0:c512,c768 tclass=file avc: granted { execute } for comm="CTION_IDLE_MODE" path="/data/data/com.google.android.gms/snet/dalvik-cache/snet.dex" dev="dm-2" ino=1114262 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:app_data_file:s0:c512,c768 tclass=file avc: granted { execute } for comm="lowpool[3]" path="/data/data/com.google.android.gms/files/libAppDataSearchExt_arm64_v8a.so" dev="dm-2" ino=1688320 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:app_data_file:s0:c512,c768 tclass=file avc: granted { execute } for comm="Binder:9196_2" path="/data/data/com.google.android.gms/app_dg_cache/1FECE961A655634046D6AB5E18FE6F74212FBEA6/lib/libdC14BB7282EA1.so" dev="dm-2" ino=1893474 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:app_data_file:s0:c512,c768 tclass=file avc: granted { execute } for comm="Binder:13170_1" path="/data/data/com.google.android.gms/app_fb/f.dex" dev="dm-2" ino=1810720 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:app_data_file:s0:c512,c768 tclass=file Test: policy compiles. Change-Id: I63358697b07c8f620b999e666791f4f385bab776
-
dcashman authored
Bug: 33388095 Test: Builds and boots. Change-Id: Ief9064a16fc733bed54eb76f509ff5aaf5db4baf
-
Treehugger Robot authored
-
Daniel Rosenberg authored
Test: No media_rw_data_file related app denials Change-Id: I1a977db09379f9a3e5bc52c597df12f52929ad19
-
dcashman authored
Make all platform tyeps public to start to prevent build breakage in any devices that may have device-specific policy using these types. Future changes will need to be carefully made to ensure we properly limit types for use by non-platform policy. Test: Builds Change-Id: I7349940d5b5a57357bc7c16f66925dee1d030eb6
-
- Dec 06, 2016
-
-
Bill Yi authored
-
Torne (Richard Coles) authored
webview_zygote needs to preload the WebView implementation, which may be an installed APK, so must be able to read and execute code from inside the APK. Also add additional neverallow assertions to strengthen some restrictions on this domain. Test: WebView apps work after installing a WebView APK. Bug: 21643067 Change-Id: I58aedc5e0a25259e2e20c70d4260579a354b6789
-
dcashman authored
In order to support platform changes without simultaneous updates from non-platform components, the platform and non-platform policies must be split. In order to provide a guarantee that policy written for non-platform objects continues to provide the same access, all types exposed to non-platform policy are versioned by converting them and the policy using them into attributes. This change performs that split, the subsequent versioning and also generates a mapping file to glue the different policy components together. Test: Device boots and runs. Bug: 31369363 Change-Id: Ibfd3eb077bd9b8e2ff3b2e6a0ca87e44d78b1317
-
Jeff Sharkey authored
am: fed665ed Change-Id: I0d6037fb73845cc012609d769b8a0bb009536848
-
Jeff Sharkey authored
-
Nick Kralevich authored
am: cb5f4a3d Change-Id: I5b019efd007c4037757ea9940a629876733186bd
-
- Dec 05, 2016
-
-
Jeff Sharkey authored
Most of this CL mirrors what we've already done for the "netd" Binder interface, while sorting a few lists alphabetically. Migrating installd to Binder will allow us to get rid of one of the few lingering text-based command protocols, improving system maintainability and security. Test: builds, boots Bug: 13758960, 30944031 Change-Id: I59b89f916fd12e22f9813ace6673be38314c97b7
-
Nick Kralevich authored
system/core commit 6a70ded7bfa8914aaa3dc25630ff2713ae893f80 (later amended by 107e29ac1b1c297a0d4ee35c4978e79f47013e2c indicated that logd doesn't want it's memory accessible by anyone else. Unfortunately, setting DUMPABLE isn't sufficient against a root level process such with ptrace. Only one such process exists, "debuggerd". Block debuggerd from accessing logd's memory on user builds. Userdebug and eng builds are unaffected. Add a neverallow rule (compile time assertion + CTS test) to prevent regressions. Bug: 32450474 Test: Policy compiles. Change-Id: Ie90850cd91846a43adaa0871d239f894a0c94d38
-
Nick Kralevich authored
am: 8ee06cc4 Change-Id: I870f2084bd6f483c8e1537a73259e0d0a45f3a07
-
Nick Kralevich authored
-
Nick Kralevich authored
Broke the dragon build: libsepol.report_failure: neverallow on line 304 of system/sepolicy/public/domain.te (or line 8638 of policy.conf) violated by allow kernel device:chr_file { create setattr }; libsepol.check_assertions: 1 neverallow failures occurred Error while expanding policy This reverts commit ed0b4eb3. Change-Id: I5d55ab59ed72ce7c19a10ddbb374f9f3b3fae4fd
-
Nick Kralevich authored
am: 4868f377 Change-Id: I3c57e833dd736ac87718d9e95e0a02e3048de979
-
Treehugger Robot authored
-
Robert Sesek authored
am: 2c222c1e Change-Id: I89d6c56ce6d29dfb184f9eb95aaaa49909e25b44
-
Treehugger Robot authored
-
Nick Kralevich authored
By default, files created in /dev are labeled with the "device" label unless a different label has been assigned. The direct use of this generic label is discouraged (and in many cases neverallowed) because rules involving this label tend to be overly broad and permissive. Today, generically labeled character devices can only be opened, read, or written to by init and ueventd. $ sesearch --allow -t device -c chr_file -p open,read,write out/target/product/marlin/root/sepolicy allow init device:chr_file { setattr read lock getattr write ioctl open append }; allow ueventd device:chr_file { read lock getattr write ioctl open append }; this is enforced by the following SELinux neverallow rule (compile time assertion + CTS test): neverallow { domain -init -ueventd } device:chr_file { open read write }; Start auditallowing ueventd access to /dev character device files with the default SELinux label. This doesn't appear to be used, but let's prove it. While ueventd is expected to create files in /dev, it has no need to open most of the files it creates. Note, however, that because ueventd has mknod + setfscreate permissions, a malicious or compromised ueventd can always create a device node under an incorrect label, and gain access that way. The goal of this change is to prove that no process other than init are accessing generically labeled files in /dev. While I'm here, tighten up the compile time assertion for device:chr_file to include more permissions. Test: policy compiles + device boots with no granted messages. Change-Id: Ic98b0ddc631b49b09e58698d9f40738ccedd1fd0
-
Daniel Micay authored
am: a24d7f53 Change-Id: Ia27cb54e53bbd755adaf588fb4bb2f948ba3d255
-
Treehugger Robot authored
-
Max authored
Only init and ueventd have any access to /dev/port, and neither should have any use for it. As it stands, leaving port in just represents additional attack surface with no useful functionality, so it should be removed if possible, not only from Pixel devices, but from all Android devices. Test: The phone boots successfully Bug:33301618 Change-Id: Iedc51590f1ffda02444587d647889ead9bdece3f
-
Daniel Micay authored
In general, apps shouldn't be executing data from their writable data directories. Allowing this is a security risk and use cases for this are almost always anti-patterns where saner alternatives are available such as using one of the standard systems for shipping libraries (extracted by the package manager or aligned/uncompressed in the apk) or using the existing package system to handle plugins. It's reasonable for the untrusted_app domain to have this (not just for backwards compatibility) for priv_app should be held to a higher standard. Ideally, untrusted apps would be able to opt-in to disabling this and then the default could then be switched at a new API level. It could do more than just hardening apps not requiring it by having documentation explain the risks and offer alternatives to reduce 'legitimate' use. The base system could disable it for all of the bundled untrusted apps. Change-Id: I4efcfaf01c6b6c33c39e98c22a1934e8892e2147
-