Commit graph

5098 commits

Author SHA1 Message Date
Automerger Merge Worker
4246a5b8ca Merge "priv_app: Remove permissions for config_gz" am: 9baf6d6609 am: 91d4d574f1 am: 61e2d83c76
Change-Id: Id3dc3ab16468ad7102d4c7d73c445edd8245f876
2020-01-27 23:32:08 +00:00
Treehugger Robot
9baf6d6609 Merge "priv_app: Remove permissions for config_gz" 2020-01-27 22:44:13 +00:00
Ashwini Oruganti
5ab5e8ad20 priv_app: Remove permissions for config_gz
Looking at go/sedenials, we see this permission being used by
MediaProvider once like so:

type=1400 audit(0.0:569759): avc: granted { getattr } for comm=4173796E635461736B202331 path="/proc/config.gz" dev="proc" ino=4026532157 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:config_gz:s0 tclass=file app=com.google.android.providers.media.module

This permission should not be granted to all priv-apps now that GMS core
has been split out into its own domain. This change removes the
permission for the priv_app domain and the corresponding auditallow.

Bug: 147833123
Test: TH
Change-Id: I4f60daefcbdd4991c5d2c32330e907a03bfe6fe5
2020-01-27 10:03:22 -08:00
Automerger Merge Worker
40362d1eeb Merge "Revert "Move aidl_lazy_test_server to system_ext"" am: 5f11b2e0ed am: 62ce810826 am: 0123408525
Change-Id: I5796ff8a811f87aa986ee2f360d9c5cef9454e29
2020-01-26 00:28:32 +00:00
Jon Spivack
5f11b2e0ed Merge "Revert "Move aidl_lazy_test_server to system_ext"" 2020-01-25 21:29:45 +00:00
Jon Spivack
4eae75c9d4 Revert "Move aidl_lazy_test_server to system_ext"
Revert submission 1209453-aidl-lazy-presubmit

Reason for revert: b/148282665. A test has begun to fail on git_stage-aosp-master, and I need to verify whether these changes are responsible.

Reverted Changes:
Ib09a2460e: Add aidl_lazy_test to general-tests
Ib08989356: Move aidl_lazy_test_server to system_ext
I694e6ad35: Add aidl_lazy_test_server to Cuttlefish
I65db12c63: Add aidl_lazy_test to presubmit
I7ec80a280: Dynamically stop services with multiple interfaces...

Change-Id: I55f6b0f7800f348259787f62c6faa19a90f8bdcc
2020-01-25 02:55:04 +00:00
Automerger Merge Worker
b1804f17e4 Merge "Whitelisting window_manager_native_boot system property" am: b9b2acff99 am: 622e779b7a am: b848357c5f
Change-Id: I213f33b122e7453988496615d7773445085763c5
2020-01-24 21:32:06 +00:00
Treehugger Robot
b9b2acff99 Merge "Whitelisting window_manager_native_boot system property" 2020-01-24 19:52:07 +00:00
Automerger Merge Worker
0d8bc0ce28 Merge "Move aidl_lazy_test_server to system_ext" am: 65028a3609 am: de87bc5c0f am: e6dd4b2bb4
Change-Id: Ic9a8213482619bfc9cdd9911ea6c7d95ff21c82e
2020-01-24 07:57:56 +00:00
Automerger Merge Worker
174478593a Merge "Allow incidentd to parse persisted log" am: 9db478bb86 am: 46761bbc6a am: f0c476d135
Change-Id: I9df10b36396698260b40982723d55fbf5eb82e9c
2020-01-24 01:48:51 +00:00
Jon Spivack
65028a3609 Merge "Move aidl_lazy_test_server to system_ext" 2020-01-24 01:30:49 +00:00
Mike Ma
9db478bb86 Merge "Allow incidentd to parse persisted log" 2020-01-24 01:04:03 +00:00
Automerger Merge Worker
506fab058f Merge "Support for more binder caches" am: edd4726300 am: a0a4772d9f am: 73c9243d74
Change-Id: I6fc7b0b3a23eb046cf642cf7584e5117cc2be285
2020-01-23 16:15:31 +00:00
Automerger Merge Worker
cb1b85b022 Merge changes I8630c20e,I4aa482cf am: a67cd2333e am: 73391bf5ce am: a4bafa6f1d
Change-Id: Id6a842c83beaab632e55ce99fef48301555aeb32
2020-01-23 15:51:17 +00:00
Lee Shombert
edd4726300 Merge "Support for more binder caches" 2020-01-23 15:44:39 +00:00
Jon Spivack
eb57c756c2 Move aidl_lazy_test_server to system_ext
This allows it to be installed and run during presubmit.

Bug: 147380480
Test: aidl_lazy_test
Change-Id: Ib08989356d02f2bf041d0780ec6c5bf65899c597
2020-01-22 17:36:05 -08:00
Automerger Merge Worker
366f2e9619 Merge "Add rules for Lights AIDL HAL" am: 0545b44e40 am: 7ad4e6350f am: eb9e2be0c5
Change-Id: I64c70d288f47c8339543e2f0902eff5bce47c740
2020-01-22 22:07:27 +00:00
Ryan Savitski
845569e2e5 debug builds: allow perf profiling of most domains
As with heapprofd, it's useful to profile the platform itself on debug
builds (compared to just apps on "user" builds).

Bug: 137092007
Change-Id: I8630c20e0da9c67e4927496802a4cd9cacbeb81a
2020-01-22 22:04:02 +00:00
Ryan Savitski
67a82481f8 initial policy for traced_perf daemon (perf profiler)
The steps involved in setting up profiling and stack unwinding are
described in detail at go/perfetto-perf-android.

To summarize the interesting case: the daemon uses cpu-wide
perf_event_open, with userspace stack and register sampling on. For each
sample, it identifies whether the process is profileable, and obtains
the FDs for /proc/[pid]/{maps,mem} using a dedicated RT signal (with the
bionic signal handler handing over the FDs over a dedicated socket). It
then uses libunwindstack to unwind & symbolize the stacks, sending the
results to the central tracing daemon (traced).

This patch covers the app profiling use-cases. Splitting out the
"profile most things on debug builds" into a separate patch for easier
review.

Most of the exceptions in domain.te & coredomain.te come from the
"vendor_file_type" allow-rule. We want a subset of that (effectively all
libraries/executables), but I believe that in practice it's hard to use
just the specific subtypes, and we're better off allowing access to all
vendor_file_type files.

Bug: 137092007
Change-Id: I4aa482cfb3f9fb2fabf02e1dff92e2b5ce121a47
2020-01-22 22:04:01 +00:00
Ivailo Karamanolev
0545b44e40 Merge "Add rules for Lights AIDL HAL" 2020-01-22 21:34:34 +00:00
Ivailo Karamanolev
254d757289 Add rules for Lights AIDL HAL
Test: manual; yukawa and cuttlefish; adb logcat | grep -i avc
Bug: 142230898
Change-Id: I9f576511d1fc77c5f0ad3cf1b96b038b301773d7
2020-01-22 20:33:42 +01:00
Lee Shombert
097f9794f4 Support for more binder caches
Bug: 140788621

This adds keys for several planned binder caches in the system server
and in the bluetooth server.  The actual cache code is not in this
tree.

Test: created a test build that contains the actual cache code and ran
some system tests.  Verified that no protection issues were seen.

Change-Id: Ibaccb0c0ff8b127d14cf769ea4156f7d8b024bc1
2020-01-22 08:21:08 -08:00
Automerger Merge Worker
b196561251 Merge "reland: untrusted_app_29: add new targetSdk domain" am: db60355f94 am: 1a0201f032 am: 3bfc8f3858
Change-Id: I736145f84fc7860512156c7401f4f67bee1b1202
2020-01-22 15:25:42 +00:00
Jeffrey Vander Stoep
db60355f94 Merge "reland: untrusted_app_29: add new targetSdk domain" 2020-01-22 14:43:36 +00:00
Jeff Vander Stoep
1f7ae8ee3f reland: untrusted_app_29: add new targetSdk domain
Enforce new requirements on app with targetSdkVersion=30 including:
- No RTM_GETLINK on netlink route sockets.

Remove some of the repetitive descriptions in each untrusted_app_N.te
file, and instead refer to the description in
public/untrusted_app.te.

Bug: 141455849
Test: CtsSelinuxTargetSdkCurrentTestCases
Test: libcore.java.net.NetworkInterfaceTest#testGetNetworkInterfaces
Change-Id: I89553e48db3bc71f229c71fafeee9005703e5c0b
2020-01-22 09:47:53 +00:00
Automerger Merge Worker
27599308a9 Merge "Update linkerconfig to generate APEX binary config" am: fa8bcd3d29 am: acfb6c7a1a am: 9ad5c5c93f
Change-Id: Id2e43c896fdc2d80c36d5c95f771aba1515209ef
2020-01-22 08:28:36 +00:00
Kiyoung Kim
fa8bcd3d29 Merge "Update linkerconfig to generate APEX binary config" 2020-01-22 07:58:43 +00:00
Automerger Merge Worker
f202905ef2 Merge "priv_app: Remove permissions for selinuxfs" am: ffd496776a am: 6277ff1c53 am: be2679723d
Change-Id: Icc05020aa43cbb839a5c162422ec5042a9c52c31
2020-01-22 02:11:37 +00:00
Ashwini Oruganti
db553aa416 priv_app: Remove permissions for selinuxfs
Looking at go/sedenials, we see this permission being used by
MediaProvider like so:

type=1400 audit(0.0:3651): avc: granted { getattr } for comm=4173796E635461736B202331 path="/sys/fs/selinux/class/tipc_socket/perms/recvfrom" dev="selinuxfs" ino=67111391 scontext=u:r:priv_app:s0:c512,c768 tcontext=u:object_r:selinuxfs:s0 tclass=file app=com.google.android.providers.media.module

... and numerous other directories, apparently from a filesystem walk.

It appears that this permission should not be granted to all priv-apps
now that GMS core has been split out into its own domain. This change
removes the permission for the priv_app domain and the corresponding
auditallow.

Bug: 147833123
Test: TH
Change-Id: I88146785c7ac3a8c15fe9b5f34f05d936f08ea48
2020-01-21 15:30:12 -08:00
Valerie Hau
7b2a2dff0c Whitelisting window_manager_native_boot system property
Bug: 147096935
Test: build, boot

Change-Id: Iadeefa3cfc9bb17eb19b60dbd18de047fa01b673
2020-01-21 22:54:49 +00:00
Automerger Merge Worker
9c853aebbf Merge "Allow isolated_app to use TCP and UDP sockets brokered over IPC." am: 3689c1481a am: 72fc061517 am: 6951ed98f3
Change-Id: I74992fff78fa7e9af2472be634f4c322f716b7bb
2020-01-21 22:43:29 +00:00
Automerger Merge Worker
a31d2c4b54 Merge "More neverallows for default_android_service." am: 64c8ddb123 am: 41e8d29253 am: 771c280d2b
Change-Id: I6a0f371a6fc11470bb3440afc3eb1ada24c1595f
2020-01-21 22:42:02 +00:00
Robert Sesek
3689c1481a Merge "Allow isolated_app to use TCP and UDP sockets brokered over IPC." 2020-01-21 21:38:40 +00:00
Steven Moreland
64c8ddb123 Merge "More neverallows for default_android_service." 2020-01-21 21:31:57 +00:00
Automerger Merge Worker
11c6f60e2f Merge "Add sysprop for init's perf_event_open LSM hook check" am: c9cc4001e4 am: 0aa85a1806 am: d33a22ff31
Change-Id: I67fa733b4c0ffa504cfb3af7a63e23995b2cd792
2020-01-21 21:04:17 +00:00
Automerger Merge Worker
ebf15a6584 Sepolicy update for Automotive Display Service am: 741b9cd5ac am: 8f52ce8bea am: 2f75747305
Change-Id: If1d84379a1205c6dddf97fcf2eb8d2ca19f2732a
2020-01-21 21:04:03 +00:00
Ryan Savitski
c9cc4001e4 Merge "Add sysprop for init's perf_event_open LSM hook check" 2020-01-21 20:40:50 +00:00
Steven Moreland
a30464c06e More neverallows for default_android_service.
We don't want to accidentally allow this, and a neverallow also means
that the issue will be found during development, instead of review.

Fixes: 148081219
Test: compile policy only
Change-Id: I57990a2a4ab9e5988b09dae2dd6a710ce8f53800
2020-01-21 11:13:22 -08:00
Ryan Savitski
52b3d315a2 Add sysprop for init's perf_event_open LSM hook check
Written exclusively by init. Made it readable by shell for CTS, and for
easier platform debugging.

Bug: 137092007
Change-Id: Ia5b056117502c272bc7169661069d0c8020695e2
2020-01-21 19:03:33 +00:00
Haoxiang Li
741b9cd5ac Sepolicy update for Automotive Display Service
Bug: 140395359
Test: make sepolicy -j
Change-Id: Ib6ddf55210d8a8ee4868359c88e3d177edce9610
Signed-off-by: Changyeon Jo <changyeon@google.com>
2020-01-21 18:43:27 +00:00
Automerger Merge Worker
0dcb0cd7da Revert "untrusted_app_29: add new targetSdk domain" am: 1d241db7e5 am: c5cc25ec03 am: 7900c7f08b
Change-Id: I7c74fbbb7b2546eccd0d30b34d6db52432048c34
2020-01-21 12:59:40 +00:00
Santiago Seifert
1d241db7e5 Revert "untrusted_app_29: add new targetSdk domain"
This reverts commit a1aa2210a9.

Reason for revert: Potential culprit for Bug b/148049462 - verifying through Forrest before revert submission

Change-Id: Ibe4fa1dee84defde324deca87d9de24a1cc2911a
2020-01-21 11:35:24 +00:00
Automerger Merge Worker
0f4d8b13f3 untrusted_app_29: add new targetSdk domain am: a1aa2210a9 am: cc7cc7b562 am: 49303f5f68
Change-Id: I58c2959d4598ea418fa63ad1cf9dba9886100d1f
2020-01-20 19:22:53 +00:00
Jeff Vander Stoep
a1aa2210a9 untrusted_app_29: add new targetSdk domain
Enforce new requirements on app with targetSdkVersion=30 including:
- No bind() on netlink route sockets.
- No RTM_GETLINK on netlink route sockets.

Remove some of the repetitive descriptions in each untrusted_app_N.te
file, and instead refer to the description in
public/untrusted_app.te.

Bug: 141455849
Test: CtsSelinuxTargetSdkCurrentTestCases
Change-Id: Iad4d142c0c13615b4710d378bc1feca4d125b6cc
2020-01-20 15:31:52 +01:00
Kiyoung Kim
b55d444c40 Update linkerconfig to generate APEX binary config
Linkerconfig should generate multiple linker configurations for APEX
with binaries. To meet this requirement, linkerconfig should be able to
create sub-directories per APEX module with binary, and also
linkerconfig should be able to scan APEX directories.

Bug: 147987608
Test: m -j passed && No sepolicy error from cuttlefish
Change-Id: I804a8e6121f647dfb1778c564649a33e4547a24a
2020-01-20 13:40:08 +09:00
Automerger Merge Worker
e77bbe54cd Merge "Make the sepolicy for gsid cleaner" am: 6ec3b17b43 am: 24beb9b5c5 am: 54b47f91df
Change-Id: Ifc2e57ccf643131d2995193185cb42289986f27a
2020-01-20 03:12:21 +00:00
Howard Chen
6ec3b17b43 Merge "Make the sepolicy for gsid cleaner" 2020-01-20 02:47:39 +00:00
Automerger Merge Worker
3f9c826675 Merge "access_vectors: remove flow_in and flow_out permissions from packet class" am: 73ed785807 am: 1a5f34195b am: d2950af40a
Change-Id: I264ecd1391ddfa09dcf3e0bc838ef32d48504b55
2020-01-19 14:44:16 +00:00
Treehugger Robot
73ed785807 Merge "access_vectors: remove flow_in and flow_out permissions from packet class" 2020-01-19 14:17:58 +00:00
Mike Ma
08f494d200 Allow incidentd to parse persisted log
Allow incidentd to run incident-helper-cmd, a Java program spawn by
app_process.
Allow incidentd to read /data/misc/logd and its files on userdebug
and eng build.

Bug: 147924172
Test: Build, flash and verify "adb shell incident -p EXPLICIT 1116"
      can parse persisted logs.

Change-Id: Id0aa4286c304a336741ce8c0949b12ec559c2e16
2020-01-18 16:18:18 -08:00