Commit graph

30 commits

Author SHA1 Message Date
Adam Shih
07a5f33a8d move brcm gps solution to gs-common
Bug: 254758553
Test: google map can locate on pixel
Change-Id: Iaf954f3af043dc5080b0be473ed8b78b1c6d0e22
2022-10-27 09:37:46 +08:00
Adam Shih
72aa5a98fc move aoc settings to gs-common
Bug: 248426917
Test: boot with aoc launched
Change-Id: I891767f10dfac7528b76e27fd2756b77ed46e45c
2022-10-20 11:41:19 +08:00
Denny cy Lee
ea1580002f HwInfo: Move hardware info sepolicy to pixel common
Bug: 215271971
Test: no sepolicy for hardware info

Signed-off-by: Denny cy Lee <dennycylee@google.com>
Change-Id: Ia7bfd171fe724848e9a6f0c1adab59402d2788a9
2022-08-02 07:43:56 +00:00
Adam Shih
d50db9e2e7 Merge "move bluetooth related types to bluetooth" 2021-10-19 01:07:50 +00:00
Adam Shih
5c28519e40 move bluetooth related types to bluetooth
Bug: 202790744
Test: boot with bluetooth hal started
Change-Id: I615d4b13262af2bc2c044914e595a7c2085999d2
2021-10-18 11:43:15 +08:00
Bart Van Assche
3a1c10bb76 Stop using the bdev_type and sysfs_block_type SELinux attributes
Stop using these attributes since these will be removed soon. This
commit reverts 37b5741301 ("Add the 'bdev_type' attribute to all block
device types").

Bug: 202520796
Test: Untested.
Change-Id: I00f10d1fd164b6ca01ecd5cffd2012acfc05eeca
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2021-10-15 14:20:18 -07:00
Philip Quinn
ac931238bf Merge "Move twoshay definitions to hardware/google/pixel-sepolicy/input." 2021-09-30 17:23:42 +00:00
George Chang
8f3fb5c47f Update SecureElement Sepolicy
Add rules for sysfs_st33spi
Separate hal_secure_element_st54spi and st33spi form default

Bug: 193417907
Test: VtsHalSecureElementV1_2TargetTest,
      VtsHalSecureElementV1_1TargetTest,
      VtsHalSecureElementV1_0TargetTest,
      CtsOmapiTestCases
Change-Id: I444af2e38fc120d173445bce48b7e4d381201a91
2021-09-30 17:41:32 +08:00
Philip Quinn
d5ac0ac3ce Move twoshay definitions to hardware/google/pixel-sepolicy/input.
Bug: 187654303
Test: twoshay works on R4, B3, P7
Change-Id: I2cada463fcbfd3b52230430b12b091a655e2abbb
2021-09-28 20:11:33 +00:00
Erik Staats
c57b0bdb55 Allow the sensor HAL to access raw HID devices. am: d60ebc5327 am: 35b6d77e0c
Original change: https://googleplex-android-review.googlesource.com/c/device/google/gs101-sepolicy/+/15847652

Change-Id: I9bb49fa27647423d27a4d8cb5444412b5220930c
2021-09-27 19:06:50 +00:00
Erik Staats
d60ebc5327 Allow the sensor HAL to access raw HID devices.
Bug: 195964858
Test: Paired a Sony PS4 controller and verified that it's discovered by
 the dynamic sensor HAL.
Test: See details in testing done comment in
 https://googleplex-android-review.git.corp.google.com/15847652 .
Change-Id: Ic0bdd711d066a9793eba305102e9a850e3973856
2021-09-27 18:34:30 +00:00
Jonglin Lee
af3a79ed68 Merge "Revert "Move twoshay definitions to hardware/google/pixel-sepoli..."" 2021-09-10 21:31:23 +00:00
Jonglin Lee
7254de258a Revert "Move twoshay definitions to hardware/google/pixel-sepoli..."
Revert "Move twoshay definitions to hardware/google/pixel-sepoli..."

Revert "Move twoshay definitions to hardware/google/pixel-sepoli..."

Revert "Move twoshay definitions to hardware/google/pixel-sepoli..."

Revert "Move sepolicy for _touchflow targets."

Revert submission 15676823-reflector-sepolicy

Reason for revert: breaking several builds in git_master-without-vendor
Reverted Changes:
Ifecfc81f0:Move twoshay definitions to hardware/google/pixel-...
Idfd81131c:Move twoshay definitions to hardware/google/pixel-...
Id2b0e1db3:Move twoshay definitions to hardware/google/pixel-...
I43ac6337f:Move twoshay definitions to hardware/google/pixel-...
If95e6e788:Move twoshay definitions to hardware/google/pixel-...
I07ab95780:Move sepolicy for _touchflow targets.
I01f378b51:Move sepolicy for _touchflow targets.

Bug: 199548147
Change-Id: I84f106c24bd47fd171788301415c0eabafe9254f
2021-09-10 21:23:57 +00:00
Philip Quinn
5c58949ac6 Merge "Move twoshay definitions to hardware/google/pixel-sepolicy/input." 2021-09-10 17:15:05 +00:00
Philip Quinn
d1dd6bac2a Move twoshay definitions to hardware/google/pixel-sepolicy/input.
Bug: 187654303
Test: twoshay works on r4
Change-Id: Id2b0e1db3e1cb9ddf579ea7ed74493464d13fc84
2021-09-08 13:22:24 -07:00
Adam Shih
82db60c2d4 remove obsolete devices
Bug: 196916111
Test: No file on the path
Change-Id: If8e54bd161bc955424b40023d94f15bf6b82cc8f
2021-09-08 13:15:44 +08:00
Bart Van Assche
37b5741301 Add the 'bdev_type' attribute to all block device types
The following patch introduces code that iterates over all block
devices:
https://android-review.googlesource.com/c/platform/system/core/+/1783847/9

The following patch grants 'init' and 'apexd' permission to iterate over
all block devices:
https://android-review.googlesource.com/c/platform/system/sepolicy/+/1783947

The above SELinux policy change requires to add the 'bdev_type'
attribute to all block devices. Hence this patch.

Bug: 194450129
Bug: 196982345
Test: Built Android images that include this change and verified that neither init nor apexd triggers any SELinux access denied errors.
Change-Id: I6ce1127f199c5b33812f15fe280d86594d7d7ebf
Signed-off-by: Bart Van Assche <bvanassche@google.com>
2021-08-17 15:23:23 -07:00
Andrew LeCain
d8d8580281 sepolicy allow fingerprint hal to read mfg_data
declares new device context for mfg_data_block_device
give fp HAL permission to read/write/open
give fp HAL permission to search block_device dir

Bug: 189135413
Test: sideload calibration in enforcing mode.
Change-Id: I19e0cd13fc452b42c3f35772c4bafd433dbcc8b1
2021-07-15 10:58:53 -07:00
Adam Shih
9b0b96b907 Merge "modularize pktrouter" into sc-dev 2021-06-24 07:24:45 +00:00
Denny cy Lee
0b21a2d44a Pixelstat: battery history access premission
Test: manually, relate seploicy not show; battery history log printed
      05-24 13:29:19.637  2829  2829 D pixelstats_BatteryEEPROM:
      checkAndReport: 0940 0a80 0500 0200 0200 0000
Bug: 189050725
Change-Id: I20567e168db43fe2168a9a30ac7a4b0cec65a665
Signed-off-by: Denny cy Lee <dennycylee@google.com>
2021-06-23 13:50:32 +08:00
Adam Shih
a70819d2f0 modularize pktrouter
Bug: 190331212
Test: make sure pktrouter gets initialized
06-23 13:21:19.372  1 1 I init : Parsing file /vendor/etc/init/pktrouter.rc...
06-23 13:21:23.510     1     1 I init    : processing action (vendor.pktrouter=1) from (/vendor/etc/init/pktrouter.rc:7)
06-23 13:21:23.510     1     1 I init    : starting service 'pktrouter'...
Change-Id: Icc7ab88505aea47cfed5ffc5182d0625b7a7609d
2021-06-23 05:24:01 +00:00
Adam Shih
d77bc5a970 organize confirmationui settings
Bug: 190331547
Bug: 190331370
Test: build ROM and make sure file and sepolicy is still there
Change-Id: I4cabf9280ab5e21038bcb72615799b7ed0fb1670
2021-06-18 12:56:05 +08:00
Adam Shih
e7ed46c52c organize EdgeTPU modules and sepolicy
Bug: 190331327
Bug: 190331548
Bug: 189895600
Bug: 190331108
Bug: 182524105
Bug: 183935302
Test: build ROM and check if the modules and sepolicy are still there
Change-Id: I40391a239a16c4fe79d58fab209dcbd1a8f25ede
2021-06-09 10:39:04 +08:00
Sean Callanan
77432c5015 whitechapel: make vframe-secure a system heap
The GPU driver uses vframe-secure for secure allocations, so the
corresponding DMA heap file should be visible to all processes so
use the dmabuf_system_secure_heap_device type instead.

In order for this type to be used, we need to ensure that the HAL
Allocator has access to it, so update hal_graphics_allocator_default.te

Finally, since there are no longer any buffer types associated with the
vframe_heap_device type, remove it.

Bug: 182090311
Test: run cts-dev -m CtsDeqpTestCases --module-arg CtsDeqpTestCases:include-filter:dEQP-VK.protected_memory.stack.stacksize_64 and ensure secure allocations succeed
Test: Play DRM-protected video in ExoPlayer and ensure videos render correctly via MFC->DPU.
Change-Id: Id341e52322a438974d4634a4274a7be2ddb4c9fe
2021-06-04 18:01:34 +00:00
Roger Fang
66634d4d20 sepolicy: gs101: allows pixelstat to access audio metrics nodes
audio.service: type=1400 audit(0.0:30): avc: denied { read write } for name="amcs" dev="tmpfs" ino=739 scontext=u:r:hal_audio_default:s0 tcontext=u:object_r:amcs_device:s0 tclass=chr_file permissive=0

pixelstats-vend: type=1400 audit(0.0:9): avc: denied { read } for name="speaker_impedance" dev="sysfs" ino=67611 scontext=u:r:pixelstats_vendor:s0 tcontext=u:object_r:sysfs:s0 tclass=file permissive=0

HwBinder:696_2: type=1400 audit(0.0:8): avc: denied { open } for path="/dev/amcs" dev="tmpfs" ino=766 scontext=u:r:hal_audio_default:s0 tcontext=u:object_r:amcs_device:s0 tclass=chr_file permissive=0

Bug: 171854614
Test: manually test, no avc: denied.
Change-Id: I82ebd22f167200ab3cf59e6525ef43c0be8f722a
2021-04-28 10:52:06 +08:00
Cheng Gu
72011a8a87 gs101-sepolicy: Allow rlsservice to access range sensor
Fix: 184295618
Test: rlsservice_test
Change-Id: Iee4cc5376e0eb67e75ae94cd15b5211a7ec819ef
2021-04-02 22:27:48 +00:00
Oleg Matcovschi
6862b8e239 vendor: remove sscoredump policies
Bug: 180760068
Signed-off-by: Oleg Matcovschi <omatcovschi@google.com>
Change-Id: Ib8d360b227286bdea7de00125ef2ed6ad7978e67
2021-03-28 21:26:34 -07:00
Kris Chen
10fda56cd1 Allow fingerprint hal to access fingerprint device
Fixes the following avc denials:
03-18 10:57:10.612   947   947 I android.hardwar: type=1400 audit(0.0:8): avc: denied { open } for path="/dev/goodix_fp" dev="tmpfs" ino=482 scontext=u:r:hal_fingerprint_default:s0 tcontext=u:object_r:device:s0 tclass=chr_file permissive=1
03-18 10:57:10.632   947   947 I android.hardwar: type=1400 audit(0.0:9): avc: denied { ioctl } for path="/dev/goodix_fp" dev="tmpfs" ino=482 ioctlcmd=0x6707 scontext=u:r:hal_fingerprint_default:s0 tcontext=u:object_r:device:s0 tclass=chr_file permissive=1
03-18 10:57:13.672   947   947 I android.hardwar: type=1400 audit(0.0:14): avc: denied { ioctl } for path="/dev/goodix_fp" dev="tmpfs" ino=482 ioctlcmd=0x6706 scontext=u:r:hal_fingerprint_default:s0 tcontext=u:object_r:device:s0 tclass=chr_file permissive=1
03-18 10:57:32.704   947   947 I HwBinder:947_1: type=1400 audit(0.0:26): avc: denied { ioctl } for path="/dev/goodix_fp" dev="tmpfs" ino=482 ioctlcmd=0x6705 scontext=u:r:hal_fingerprint_default:s0 tcontext=u:object_r:device:s0 tclass=chr_file permissive=1

Bug: 171943101
Test: No above avc denials in logcat.
Change-Id: I254a01a2c11fcaba9ad3f387862a8d0ddafffd38
2021-03-18 19:23:54 +08:00
Tai Kuo
8cac55487b gs101-sepolicy: Add twoshay permissions
Add twoshay and touch input context library permissions

Bug: 173330899
Bug: 173330981
Test: check boot-time twoshay startup and no denials.
Signed-off-by: Steve Pfetsch <spfetsch@google.com>
Change-Id: I68aace66f49c2af1ebfd4bde7082039f9caf3f64
Signed-off-by: Tai Kuo <taikuo@google.com>
2021-03-10 22:23:49 +08:00
Robin Peng
5009efa776 Move slider-sepolicy into gs101-sepolicy
from: 71e609c24c97fc8d44843af30527cbeb90d5dcdf

Bug: 167996145
Change-Id: Ie00e7e0983a3ca695bbd5140c929d07a80144301
2021-03-06 16:15:39 +08:00