Commit graph

392 commits

Author SHA1 Message Date
Michael Ayoubi
6080fdc9ec Merge "Add DCK eligibility properties" am: 20af5f1e4e am: 64c125adc0
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1715931

Change-Id: I1765b987167e49e102f6725af797e2ce6e7857be
2021-05-25 01:48:39 +00:00
Michael Ayoubi
77c10eff1e Add DCK eligibility properties
Bug: 186488185
Test: Confirm GMSCore access
Change-Id: I20baf5c9ae9fbebc9e43d2798401ad49776fb74a
2021-05-21 23:31:09 +00:00
liuyg
87fc7e06db Revert "Allow the MediaProvider app to set FUSE passthrough property" am: 04c85dcfc4 am: 97e0c02e9e am: bdfad42b09
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1705066

Change-Id: I07875bd5e07c5b2b45fb5fdd064790b50ad7eeb7
2021-05-13 19:55:46 +00:00
Alessio Balsini
4e758d5a43 Allow the MediaProvider app to set FUSE passthrough property am: c1e2918fd9 am: bafbd5eeb0 am: 3c7f9b1c7a
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1693545

Change-Id: I4340d1aa457cf190eba110b74ef63f76abe6613d
2021-05-13 19:55:35 +00:00
liuyg
04c85dcfc4 Revert "Allow the MediaProvider app to set FUSE passthrough property"
This reverts commit c1e2918fd9.

Reason for revert: Build broke

Change-Id: I4b95e977cf66c586b0d0b465f1b3654c01074152
2021-05-13 18:18:28 +00:00
Alessio Balsini
c1e2918fd9 Allow the MediaProvider app to set FUSE passthrough property
Allow the MediaProvider app to write the system property
fuse.passthrough.enabled in case FUSE passthrough is enabled.
The need for this additional system property is due to the ScopedStorage
CTS tests that are assuming FUSE passtrhough is always on for devices
supporting it, but there may be some cases (e.g., GSI mixed builds)
where this is not possible true and the feature is disabled at runtime,
thus causing the tests to fail.
This additional system property is only set when FUSE passthrough is
actually being used by the system.

Bug: 186635810
Test: CtsScopedStorageDeviceOnlyTest
Signed-off-by: Alessio Balsini <balsini@google.com>
Change-Id: I623042d67399253a9167188c3748d93eb0f2d41f
2021-05-13 17:38:16 +00:00
Hridya Valsaraju
037300eb6b Merge changes If26ba23d,Ibea38822 am: f35c70b0dd am: 09665a69c3 am: 9413e4b62f
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1696318

Change-Id: Ia4af31c21970786ef65764e0d3c2af6fe72c5634
2021-05-05 18:41:01 +00:00
Hridya Valsaraju
f35c70b0dd Merge changes If26ba23d,Ibea38822
* changes:
  Revert "Revert "Exclude vendor_modprobe from debugfs neverallow restrictions""
  Revert "Revert "Add neverallows for debugfs access""
2021-05-05 17:31:35 +00:00
Songchun Fan
c201aff5a9 [sepolicy] allow system server to read incfs metrics from sysfs am: 633f7ca868 am: 5ba48ae269 am: 73793c2fcd
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1696320

Change-Id: I3f62c003ce2f3111f779617343f4ca0c7325a390
2021-05-05 15:55:45 +00:00
Songchun Fan
633f7ca868 [sepolicy] allow system server to read incfs metrics from sysfs
Address denial messages like:

05-05 05:02:21.480  1597  1597 W Binder:1597_12: type=1400 audit(0.0:140): avc: denied { read } for name="reads_delayed_min" dev="sysfs" ino=107358 scontext=u:r:system_server:s0 tcontext=u:object_r:sysfs:s0 tclass=file permissive=0

BUG: 184844615
Test: atest android.cts.statsdatom.incremental.AppErrorAtomTests#testAppCrashOnIncremental
Change-Id: I201e27e48a08f99f41a030e06c6f22518294e056
2021-05-04 22:56:41 -07:00
Hridya Valsaraju
498318cc65 Revert "Revert "Exclude vendor_modprobe from debugfs neverallow restrictions""
This reverts commit 231c04b2b9.

Now that b/186727553 is fixed, it should be safe to revert this revert.

Test: build
Bug: 184381659
Change-Id: If26ba23df19e9854a121bbcf10a027c738006515
2021-05-04 22:07:08 -07:00
Nicolas Geoffray
882537a989 Merge "Allow boot animation to update boot status." am: 82bf10a79c am: 75de97b2e4 am: 1f652713d1
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1687883

Change-Id: I791ffa1d83a1bf9bbb5a15f69ffce6e7e86441ce
2021-04-29 09:32:32 +00:00
Nicolas Geoffray
82bf10a79c Merge "Allow boot animation to update boot status." 2021-04-29 07:53:05 +00:00
Christian Wailes
6de8e5debe Merge "Add SELinux properties for artd" am: 6553a8dbe6 am: b9502c818f am: b921e1dac4
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1663786

Change-Id: Ie4bd8ae58edc80993c56ba3cf806135c716526fc
2021-04-28 20:23:52 +00:00
Nicolas Geoffray
6a311471a6 Allow boot animation to update boot status.
This CL was missed from the topic:
https://android-review.googlesource.com/q/topic:bootanim-percent

Test: update ART module, see animation go to 100%
Bug: 184881321
Change-Id: I59706718af11751a7e1f4b5ab1ff2793f554fb19
2021-04-28 15:17:09 +01:00
Chris Wailes
467d8a80ea Add SELinux properties for artd
Test: boot device and check for artd process
Change-Id: I2a161701102ecbde3e293af0346d1db0b11d4aab
2021-04-27 14:49:13 -07:00
Treehugger Robot
88903b91a9 Merge "Fix permissions for vold.post_fs_data_done" am: 206d6d80a1 am: e85d0ef89c am: b99fe5711a
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1684054

Change-Id: I0921af74d1309fcaa3f36e53476090da085ab07f
2021-04-26 22:09:08 +00:00
Treehugger Robot
206d6d80a1 Merge "Fix permissions for vold.post_fs_data_done" 2021-04-26 20:36:34 +00:00
Eric Biggers
040ce199b2 Fix permissions for vold.post_fs_data_done
The system property "vold.post_fs_data_done" is used by init and vold to
communicate with each other in order to set up FDE on devices that use
FDE.  It needs to be gettable and settable by vold, and settable by init
and vendor_init.  This was the case in Android 11 and earlier; however,
the change
https://android-review.googlesource.com/c/platform/system/sepolicy/+/1277447
("Rename exported and exported2 vold prop") broke this by giving this
property the type "vold_config_prop", which made it no longer settable
by vold.

Since none of the existing property types appear to be appropriate for
this particular property, define a new type "vold_post_fs_data_prop" and
grant the needed domains permission to get/set it.

This is one of a set of changes that is needed to get FDE working again
so that devices that launched with FDE can be upgraded to Android 12.

Bug: 186165644
Test: Tested FDE on Cuttlefish
Change-Id: I2fd8af0091f8b921ec37381ad3b85a156d074566
2021-04-26 12:43:05 -07:00
Hridya Valsaraju
4d8e3b032b Merge changes from topic "revert-1668411-MWQWEZISXF" am: 7362f58895 am: b4fe53980f am: cb7c75c028
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1685768

Change-Id: I1cb8c339e1f75e3d9c0a8dc5d8c96c7b9ded79a6
2021-04-23 23:05:26 +00:00
Hridya Valsaraju
7362f58895 Merge changes from topic "revert-1668411-MWQWEZISXF"
* changes:
  Revert "Add a neverallow for debugfs mounting"
  Revert "Add neverallows for debugfs access"
  Revert "Exclude vendor_modprobe from debugfs neverallow restrictions"
  Revert "Check that tracefs files are labelled as tracefs_type"
2021-04-23 22:06:31 +00:00
Robert Horvath
f0989714ca Merge "Add bootanim property context, ro.bootanim.quiescent.enabled property" am: dbfe4809ba am: 03070a86ec am: 0b1d2a7385
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1676224

Change-Id: I6b7b8419e27ce03fae35451ba3e7cc842ee67335
2021-04-23 17:46:15 +00:00
Robert Horvath
dbfe4809ba Merge "Add bootanim property context, ro.bootanim.quiescent.enabled property" 2021-04-23 16:45:32 +00:00
Hridya Valsaraju
231c04b2b9 Revert "Exclude vendor_modprobe from debugfs neverallow restrictions"
Revert submission 1668411

Reason for revert: Suspect for b/186173384
Reverted Changes:
Iaa4fce9f0:Check that tracefs files are labelled as tracefs_t...
I743a81489:Exclude vendor_modprobe from debugfs neverallow re...
I63a22402c:Add neverallows for debugfs access
I289f2d256:Add a neverallow for debugfs mounting

Change-Id: I04f8bfdc0e5fe8d2f7d6596ed7b840332d611485
2021-04-23 16:38:20 +00:00
Treehugger Robot
d21e4d0980 Merge changes from topic "debugfs_neverallow" am: 005ae599cd am: 95fef2b070 am: cf2b67a243
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1668411

Change-Id: I1fe5c7c31f12e0a68c76dde8810aba465d499922
2021-04-22 17:30:53 +00:00
Treehugger Robot
005ae599cd Merge changes from topic "debugfs_neverallow"
* changes:
  Check that tracefs files are labelled as tracefs_type
  Exclude vendor_modprobe from debugfs neverallow restrictions
  Add neverallows for debugfs access
  Add a neverallow for debugfs mounting
2021-04-22 16:41:06 +00:00
Treehugger Robot
6298a5c3df Merge "sepolicy: Give access to ahal to flinger standby prop" am: e0646ba15b am: eba4818e88 am: b8d397db9b
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1658623

Change-Id: Idbd91f061c7cd74c8943774493c05b8e32dc3e37
2021-04-22 03:47:11 +00:00
Treehugger Robot
e0646ba15b Merge "sepolicy: Give access to ahal to flinger standby prop" 2021-04-22 02:36:46 +00:00
David Massoud
d84abac63b Merge "Allow traced_probes to read devfreq" am: 47b6227134 am: eeb537fcb8 am: 418070b5ac
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1676945

Change-Id: Ibe3c1ff8ed58ec1dc514802ca5c82bf9f14f2c67
2021-04-22 01:35:16 +00:00
David Massoud
47b6227134 Merge "Allow traced_probes to read devfreq" 2021-04-22 00:18:35 +00:00
Hridya Valsaraju
4b6d50dcb4 Exclude vendor_modprobe from debugfs neverallow restrictions
vendor_modprobe loads kernel modules which may create files in
debugfs during module_init().

Bug: 179760914
Test: build
Change-Id: I743a81489f469d52f94a88166f8583a7d797db16
2021-04-21 14:13:41 -07:00
Treehugger Robot
588c0f11d9 Merge "Add a property to enable runtime debugfs restrictions in non-user builds" am: f5ec134342 am: b9f8fd42d5 am: efb6c0b1b6
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1663701

Change-Id: I3a8ea3bf524dd26e9bd1804898c7f4ca3c3a61be
2021-04-20 07:29:53 +00:00
Treehugger Robot
f5ec134342 Merge "Add a property to enable runtime debugfs restrictions in non-user builds" 2021-04-20 06:07:53 +00:00
Treehugger Robot
f4014837fa Merge "Add permission checker service" am: 644639584b am: e8a381e3e4 am: 82d927bad8
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1678585

Change-Id: I85473ed47a9ad47ba1356149644464821bd84a25
2021-04-19 19:35:30 +00:00
Svet Ganov
214a65213a Add permission checker service
bug: 158792096

Test: atest CtsPermission5TestCases

Change-Id: I9dbbf2fe84131ba38ac70e7171e3bd826c150640
2021-04-17 23:41:50 +00:00
David Massoud
c50fecd8ef Allow traced_probes to read devfreq
- Add dir read access to /sys/class/devfreq/
- Add file read access to /sys/class/devfreq/$DEVICE/cur_freq

Resolves the following denials:
W traced_probes: type=1400 audit(0.0:8):
avc: denied { read } for name="devfreq" dev="sysfs"
ino=28076 scontext=u:r:traced_probes:s0
tcontext=u:object_r:sysfs:s0 tclass=dir permissive=0

W traced_probes: type=1400 audit(0.0:226):
avc: denied { read } for name="cur_freq" dev="sysfs"
ino=54729 scontext=u:r:traced_probes:s0
tcontext=u:object_r:sysfs:s0 tclass=file permissive=0

See ag/14187061 for device specific sysfs_devfreq_cur labels

Bug: 181850306
Test: ls -Z, record perfetto trace
Change-Id: I23cebb16505313160e14b49e82e24da9b81cad70
2021-04-16 20:02:06 +08:00
Joanne Chung
ece98d7cf7 Merge "[Sepolicy] Change sepolicy name back to formal name." into sc-dev 2021-04-16 07:16:26 +00:00
Hridya Valsaraju
8403ed70de Add a property to enable runtime debugfs restrictions in non-user builds
This patch adds ro.product.enforce_debugfs_restrictions to
property_contexts. When the property is set to true in non-user builds,
init mounts debugfs in early-init to enable boot-time debugfs
initializations and unmounts it on boot complete. Similarly dumpstate
will mount debugfs to collect information from debugfs during bugreport
collection via the dumpstate HAL and unmount debugfs once done. Doing
so will allow non-user builds to keep debugfs disabled during runtime.

Test: make with/without PRODUCT_SET_DEBUGFS_RESTRICTIONS, adb shell am
bugreport
Bug: 184381659

Change-Id: Ib720523c7f94a4f9ce944d46977a3c01ed829414
2021-04-15 22:38:23 -07:00
Treehugger Robot
cdd84f56e6 Merge "Allow apexd to access a new dev_type: virtual disk" am: 1c996021a5 am: 76fc5c9fa5 am: b8561bf122
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1673185

Change-Id: Ia8b48874bdba28757a38c7633f6e6c362888de93
2021-04-16 02:26:05 +00:00
Treehugger Robot
1c996021a5 Merge "Allow apexd to access a new dev_type: virtual disk" 2021-04-16 00:54:40 +00:00
Robert Horvath
8504938690 Add bootanim property context, ro.bootanim.quiescent.enabled property
Add property & property context to configure whether the bootanimation
should be played in a quiescent boot.

Bug: 185118020
Test: Set property through PRODUCT_PRODUCT_PROPERTIES
Test: Read property from bootanimation process
Change-Id: Ib9e88444da7f5e8000d7367199f5230f1e4d26d9
2021-04-15 14:56:17 +00:00
Emilian Peev
d7106d9711 Merge "Define vendor side property "ro.camerax.extensions.enabled"" am: 87a3f24857 am: 1d1e424ac6 am: 565ebf6315
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1504131

Change-Id: I95eb3b22c851396fd9751b598fbbcde825d087b9
2021-04-14 17:47:24 +00:00
Emilian Peev
87a3f24857 Merge "Define vendor side property "ro.camerax.extensions.enabled"" 2021-04-14 16:20:16 +00:00
Joanne Chung
685748706d [Sepolicy] Change sepolicy name back to formal name.
We use a fake name to prevent feature leak, we should change it back
before API freeze.

We will update the AOSP when our feature is public released.

Bug: 181179744
Test: build pass and can run service correctly
Ignore-AOSP-First: to prevent new feature leak.
Test: atest CtsTranslationTestCases

Change-Id: I956d916077f9a71cdf1df2f0be6f83e6f1f30a98
2021-04-14 14:48:28 +00:00
Roshan Pius
34f5268532 Merge "Uwb: Create a new Uwb system service" am: 0b8eafb54b am: 4b47c80944 am: f5a723a306
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1673587

Change-Id: Iae266dda5077f501918f61d2ea7da7cd23f8ae9f
2021-04-14 03:00:57 +00:00
Emilian Peev
a974640390 Define vendor side property "ro.camerax.extensions.enabled"
Add "ro.camerax.extensions.enabled" vendor-specific property.
Allow public apps to read this property.

Bug: 171572972
Test: Camera CTS
Change-Id: Id5fadedff6baaaebe5306100c2a054e537aa61ed
2021-04-13 16:42:10 -07:00
Jooyung Han
b62be12176 Allow apexd to access a new dev_type: virtual disk
In microdroid, apexd activates apexes which are passed as a virtual disk
to share apexes with host Android.

Bug: 184605708
Test: apexd running in microdroid can read /dev/block/vdb2
  when a disk image is passed to crosvm via --disk= option.
Change-Id: Ie27774868a0e0befb4c42cff795d1531b042654c
2021-04-13 15:46:16 +09:00
Roshan Pius
2a1610b4e0 Uwb: Create a new Uwb system service
This service will intercept all UwbManager API calls and then perform
necessary permission checks before forwarding the call to the vendor
UWB service. Adding sepolicy permissions for exposing the service that
handles all public API's.

Bug: 183904955
Test: atest android.uwb.cts.UwbManagerTest
Change-Id: Icce4d2f586926421c06e8902a91533002c380b8d
2021-04-12 10:26:24 -07:00
Yabin Cui
49806a1067 Merge "Add vendor_kernel_modules type to public." 2021-04-08 17:49:16 +00:00
Kalesh Singh
0a0233c868 Merge "Sepolicy for mm_events" am: df4b04571b am: abdb06eec4 am: 6c267ff23b
Original change: https://android-review.googlesource.com/c/platform/system/sepolicy/+/1662143

Change-Id: I669e997d3df52eed895a592c5c983af6feca12fc
2021-04-07 17:03:28 +00:00