Commit graph

32918 commits

Author SHA1 Message Date
Chris Weir
07fcb348fa Merge "SEPolicy for Netlink Interceptor" 2021-11-02 18:02:45 +00:00
Jooyung Han
effe33f20d Merge "remove unnecessary right from virtualizationservice" 2021-11-02 09:10:25 +00:00
Mohammad Islam
15a5b178fe Merge "Allow apexd to call derive_classpath binary" 2021-11-02 08:51:01 +00:00
Jooyung Han
33b21f0c91 remove unnecessary right from virtualizationservice
Bug: n/a
Test: MicrodroidTestCases
Change-Id: I14580d89d03dd90498f665913d00484ff643ee6a
2021-11-02 16:01:04 +09:00
Treehugger Robot
54bd8438b1 Merge "Allow init to write to /proc/cpu/alignment" 2021-11-01 22:33:09 +00:00
Treehugger Robot
e7fa65e301 Merge "Allow vendor charger to set sys.boot_from_charger_mode." 2021-11-01 21:19:39 +00:00
Alistair Delva
6092d633b0 Allow init to write to /proc/cpu/alignment
The root init.rc does "write /proc/cpu/alignment 4", but we don't
actually allow this write in core sepolicy. This seems to be a 32-bit
ARM only proc file.

Noticed when booting 32-bit ARM Cuttlefish.

Bug: 145371497
Change-Id: Ic099395708f7236bcc2fc5c561809a7e129786de
2021-11-01 10:17:26 -07:00
Shuzhen Wang
5f45be324d Merge "Camera: Allow stream socket read/write with surfaceflinger" 2021-11-01 15:08:02 +00:00
Shubang Lu
69a7983d31 Merge "Add SE policy for tv_iapp" 2021-10-29 19:44:18 +00:00
Yabin Cui
d6ab03f8d0 Merge "Revert "Revert "allow simpleperf to profile more app types.""" 2021-10-29 16:28:59 +00:00
Jeffrey Huang
47ff63e60e Merge "Allow statsd to write to priv app FDs" 2021-10-29 16:06:33 +00:00
Yifan Hong
70da34e4e3 Allow vendor charger to set sys.boot_from_charger_mode.
This allows booting from charger mode directly without rebooting.

Test: pass
Bug: 203246116
Change-Id: I70d06c0f920c360f4ed6d776cfee98f234d6d97a
2021-10-29 05:33:14 +00:00
Jooyung Han
0bab949b50 Merge "microdroid: add sys.powerctl property" 2021-10-28 23:57:58 +00:00
Shuzhen Wang
5ed0c50e86 Camera: Allow stream socket read/write with surfaceflinger
This is needed for the camera service to be able to use
AChoreographer ndk.

Test: adb shell dmesg | audit2allow -p policy
Bug: 200306379
Change-Id: I191760f1cdd0a88c9d140fffd4470e9ae1956c52
2021-10-28 15:38:48 -07:00
Steven Moreland
f15d7e3ff5 Merge "Remove bufferhub HAL policy." 2021-10-28 21:12:45 +00:00
Jeffrey Huang
5d5e539bbf Allow statsd to write to priv app FDs
Bug: 160810755
Test: manual
Change-Id: Idc033ca206855424affa04351f946dda42d087a8
2021-10-28 13:07:19 -07:00
brycelee
1a6fbe3dfe Merge "Revert "Remove the bdev_type and sysfs_block_type SELinux attributes"" 2021-10-28 18:31:01 +00:00
Bart Van Assche
e3cfa9e1d3 Revert "Remove the bdev_type and sysfs_block_type SELinux attributes"
This reverts commit 63930d3850.

Reason for revert: Broken build (https://android-build.googleplex.com/builds/submitted/7863094/aosp_raven-userdebug/latest/view/logs/error.log)

Change-Id: I1742d69d471e9b00359a2e7e654aa752513990df
2021-10-28 18:03:49 +00:00
Bart Van Assche
187ffea5b8 Merge "Remove the bdev_type and sysfs_block_type SELinux attributes" 2021-10-28 16:45:54 +00:00
Samiul Islam
9237163c26 Allow apexd to call derive_classpath binary
This will allow apexd to determine if a staged apex contributes to
classpath or not.

Bug: 187444679
Test: atest ApexTestCases
Test: atest StagedInstallInternalTest
Change-Id: I336001ef1dab3aa45835662eecc02d63645b5980
2021-10-28 16:27:09 +01:00
Jooyung Han
c75eca682e microdroid: add sys.powerctl property
And microdroid_manager can set it to shut down when verification fails.

Bug: 204073443
Test: MicrodroidHostTestCases
Change-Id: I12ec7c8b832f5d1e382961ce7866502c2cc8a9b8
2021-10-28 11:09:48 +09:00
Treehugger Robot
b2bc6b1b4e Merge "microdroid: introduce logcat domain" 2021-10-28 01:51:08 +00:00
Treehugger Robot
b754ebe4d9 Merge "Add the property context for ro.lmk.use_minfree_levels" 2021-10-28 00:23:59 +00:00
Thiébaud Weksteen
21d2752761 Merge "Revert^2 "Use cil_write_build_ast"" 2021-10-27 23:34:39 +00:00
Treehugger Robot
f88e2dfe94 Merge "hal_neverallow: Add hal_uwb_server exceptions" 2021-10-27 21:03:29 +00:00
Roshan Pius
329b0c81a8 hal_neverallow: Add hal_uwb_server exceptions
These are similar to the existing exceptions added for
`hal_uwb_vendor_server`.

Also, added a TODO to remove the older `hal_uwb_vendor` tags once we
migrate to the new T architecture.

Bug: 196225233
Test: Compiles
Change-Id: I2077d409f575a2e46684de4fb92fe3da0cceaf70
2021-10-27 12:46:44 -07:00
Yabin Cui
3696a20b11 Revert "Revert "allow simpleperf to profile more app types.""
This reverts commit dd2079d7f0.

Bug: 199086135
Test: run simpleperf to record systemui.
Change-Id: Ibc6017d53a9835a2f8ff5409c825c0d70ef23e25
2021-10-27 11:05:01 -07:00
Steven Moreland
cc7de177ec Remove bufferhub HAL policy.
The bufferhub daemon policy still remains, since it still needs to be
deleted. However, since the HAL no longer exists, removing policy
related to this.

Bug: 204068144
Test: build only
Change-Id: I96b96c77a39e2ba2024680ebaf3067283d0cfc65
2021-10-27 10:54:45 -07:00
Robin Lee
0b0dd684e7 Add the property context for ro.lmk.use_minfree_levels
This is not settable by vendor init at the moment, which appears to be a mistake
because it is often used as a board-level configuration.

Change-Id: I7a49d55712e9606446b3e6307627a208657d5da2
Test: adb shell getprop -Z | grep lmk
Bug: 184041905
2021-10-27 13:17:54 +00:00
Thiébaud Weksteen
1c574576b5 Revert^2 "Use cil_write_build_ast"
bde09de39f

Change-Id: I1c94eb98d1b37216096dfba297434377f805eed9
2021-10-27 04:50:56 +00:00
Yifan Hong
388bbbccb3 Add health AIDL HAL.
Test: pass
Bug: 177269435
Change-Id: I755d5158715b38a89a28af753ad4c27cdfa93546
2021-10-26 19:34:34 -07:00
Chris Weir
4ac3d74a70 SEPolicy for Netlink Interceptor
Make Netlink Interceptor work when SELinux is enforcing

Test: Netlink Interceptor HAL comes up and works
Bug: 194683902
Change-Id: I3afc7ae04eba82f2f6385b66ddd5f4a8310dff88
2021-10-26 10:03:14 -07:00
Bart Van Assche
63930d3850 Remove the bdev_type and sysfs_block_type SELinux attributes
Remove these SELinux attributes since the apexd and init SELinux policies
no longer rely on these attributes.

The only difference between a previous version of this patch and the
current patch is that the current patch moves these attributes to the
'compat' policy. See also
https://android-review.googlesource.com/c/platform/system/sepolicy/+/1850656.

This patch includes a revert of commit 8b2b951349 ("Restore permission
for shell to list /sys/class/block"). That commit is no longer necessary
since it was a bug fix for the introduction of the sysfs_block type.

Bug: 202520796
Test: source build/envsetup.sh && lunch aosp_x86_64 && m && launch_cvd && adb -e shell dmesg | grep avc
Change-Id: Id7d32a914e48bc74da63d87ce6a09f11e323c186
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2021-10-25 16:26:07 -07:00
Jiyong Park
bd35627371 microdroid: introduce logcat domain
In Microdroid, logcat is started as a daemon process (whose service name
is seriallogging) whose job is to read logs from logd and sends them to
the host side via a virtual console.

The daemon process is controlled by microdroid_manager, so the process
is given write access to ctl.start$seriallogging and also to some
sysprops originated from bootconfig so that it can know if the VM is
configured as debuggable or not.

Bug: 200914564
Test: start microdroid using the vm tool. logcat logs are shown in
stdout.

Change-Id: I79bc6486ae1f84515ad31a09e24d8368fb54bc6d
2021-10-25 20:29:28 +09:00
shubang
9fa7dc9c7b Add SE policy for tv_iapp
Bug: 203730671
Test: cuttlefish;
Change-Id: I533f2004343aafe5660e4018e73111880dfa647f
2021-10-22 00:02:05 -07:00
Yifan Hong
48732e041c Merge "Remove healthd." 2021-10-22 00:06:39 +00:00
Treehugger Robot
5b1dc1693a Merge "Move mediatranscoding type to public" 2021-10-21 11:06:22 +00:00
Bowgo Tsai
ef1f630c69 Set context for partition.odm.verified[.*] properties.
Some devices might have the ODM partition so set those properties
as well.

Bug: 203720638
Test: Presubmit
Change-Id: I50ee65e21c471f0691f4c1dfc93be8eb1677ad1b
2021-10-21 16:38:06 +08:00
Jeff Vander Stoep
1b2a0b4dab Move mediatranscoding type to public
Move type to public so that it can be vendor customized. This
can be necessary if (for example) the gralloc/gpu same-process-HAL
requires additional permissions.

Bug: 199581284
Test: build
Change-Id: I61a5a3ad96112d4293fd4bf6d55f939c974643ce
2021-10-21 09:10:45 +02:00
Yifan Hong
aabea20d89 Remove healthd.
Test: pass
Bug: 203245871
Change-Id: I4eb0b4333d7fde2096c4c75b7655baf897900005
2021-10-20 18:47:41 -07:00
Treehugger Robot
c0cd637049 Merge "Label /dev/hvcN paths" 2021-10-20 08:17:15 +00:00
Treehugger Robot
028e88f578 Merge "microdroid: Remove microdroid_app dontaudit" 2021-10-20 07:10:32 +00:00
Ady Abraham
7ed18e6d66 Composer stable AIDL HAL sepolicy
Test: build + presubmit
Bug: 198690444
Change-Id: I6a26823c4ad363d137526c96580b05363d0ac894
2021-10-20 02:58:20 +00:00
Ady Abraham
df28371462 Remove vrflinger
Not used anymore.

Test: build + presubmit
Bug: 170681929
Change-Id: I3ac9b842f89acf620e9f08516e44977d83064f2f
2021-10-20 02:02:57 +00:00
Jiyong Park
f264d79bf8 Label /dev/hvcN paths
They are virtual console devices. Label them as serial_devices.

Bug: 200914564
Test: m
Change-Id: I6a178360fa9977e9b50b0c07da2a506114369189
2021-10-19 22:43:45 +09:00
Michał Brzeziński
04e3a05fde Merge "Revert "Remove the bdev_type and sysfs_block_type SELinux attributes"" 2021-10-19 13:03:18 +00:00
Michał Brzeziński
e8739ba23a Revert "Remove the bdev_type and sysfs_block_type SELinux attributes"
Revert "Remove the bdev_type and sysfs_block_type SELinux attributes"

Revert "Remove the bdev_type and sysfs_block_type SELinux attributes"

Revert submission 1850578-remove-selinux-bdev-type

Reason for revert: DroidMonitor-triggered revert due to breakage, bug b/203480787

BUG: 203480787

Reverted Changes:
I263bce9c4:Remove the bdev_type and sysfs_block_type SELinux ...
Ibc9039f96:Revert "Add the 'bdev_type' attribute to all block...
Ic6ae83576:Remove the bdev_type and sysfs_block_type SELinux ...
Ie493022a8:Remove the bdev_type and sysfs_block_type SELinux ...
I1f1ca439b:Revert "Add the 'bdev_type' attribute to all block...
I283f8676b:Revert "Add the 'bdev_type' attribute to all block...
I7c5c242c5:Revert "Add the 'bdev_type' attribute to all block...
Id78d8f7dc:Remove the bdev_type and sysfs_block_type SELinux ...
I9c4b2c48b:Remove the bdev_type and sysfs_block_type SELinux ...
I51e9d384a:Remove the bdev_type and sysfs_block_type SELinux ...
I2c414de3b:Remove the sysfs_block_type SELinux attribute

Change-Id: I55609803d530772d507d9dca8ba202a96daf24b7
2021-10-19 10:57:42 +00:00
Inseob Kim
e4ef85e65a microdroid: Remove microdroid_app dontaudit
Some permissions used to make denials, but it seems that it's not the
case anymore.

Bug: 195751698
Test: atest MicrodroidHostTestCases
Change-Id: I3329bb9a6d4d17dc49a2469bae2cf17e6f0e49a9
2021-10-19 10:46:17 +00:00
Treehugger Robot
eaa9fa390b Merge "Allow test apps to use the virtualizationservice" 2021-10-19 10:33:23 +00:00
Jiyong Park
47d4b1ffdc Allow test apps to use the virtualizationservice
The existing host-side tests for virtualizationservice will be migrated
to device tests. In order for the self-instrumented test apks be able to
talk to the service, re-introduce the allow rule only for the
non-production builds.

Note that the access to the service is still guarded with the app
permission whose protection level now has the 'development' bit. So,
ordinary apks that are not testing-purpose (i.e. no
android:testOnly="true") can't use the service.

Bug: 203483081
Test: run MicrodroidDemoApp
Change-Id: Ia441fc5ca0a1f076d2e267a26e0df7c11730ec94
2021-10-19 17:18:42 +09:00