118 Commits

Author SHA1 Message Date
Aayush Gupta
8d01032f5f Label vtservice binary, hidl, and service and grant required permissions
Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
Change-Id: I2bc48a03416807b9d0403a3a25bd9f7fd5952389
2021-01-19 17:00:18 +05:30
Aayush Gupta
9029a49cc4 plat_private: Use newline at the end of service_contexts
Missing newline causes compile-time error when sepolicy squashes all given
service-contexts into single file to pack into the build. This change
fixes that issue.

Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
2020-12-21 22:01:18 +05:30
Shanshan Guo
5da546820c [ALPS04968083] SEPolicy: Modify sepolicy files mode and type
[Detail]
The mode of sepolicy files should be -rw-r--r--,
and the type should be ASCII text with Unix/Linux format.

[Solution]
1.Use chmod 0644 to change sepolicy files mode.
2.Use iconv -t ASCII and dos2unix to change sepolicy files
  type and format.

MTK-Commit-Id: ee386fd7ca89105f70b96f6b58c5f0e372fe9a4b

Change-Id: Iac13b1ea8a4546168f68a7918acdcdb0588f6630
CR-Id: ALPS04968083
Feature: [Android Default] SELinux, SEAndroid, and SE-MTK
2020-12-21 22:01:08 +05:30
Huaiming Li
2341e2e16c [ALPS04849010] move plat_private add_aedv contexts
1. move plat_private aee_aedv contexts to non_plat/file_contexts
2. move plat_private aee_aedv contexts to r_non_plat/file_contexts

MTK-Commit-Id: 8b60b4707b32707c8ada4ebc5effdb47627d00df

Change-Id: Ie307e1938dd9afbf0f87b166f91397fd5431f9fb
CR-Id: ALPS04849010
Feature: Android Exception Engine(AEE)
2020-01-18 10:21:46 +08:00
Huaiming Li
cd6459c6ee [ALPS04758557] fix aee high risk rules
1. fix some aee high risk rules

MTK-Commit-Id: 4031a4610757debf0aa0de48408c72517fd61bcb

Change-Id: I637d723cba54ba7119d15617bd2935a4b00dd6c5
CR-Id: ALPS04758557
Feature: Android Exception Engine(AEE)
2020-01-18 10:21:37 +08:00
Juju Sung
939dbae537 [ALPS04823486] selinux: export fingerprint property
coredump tool needs to expose system and vendor image
fingerprint to know the relative version info.

MTK-Commit-Id: e8794c35f056dfeb20c0dff8b8aa506bd938fbd6

Change-Id: I009e10ccc8838b032d2192055fe1defcf81cebee
CR-Id: ALPS04823486
Feature: Android Exception Engine(AEE)
2020-01-18 10:21:25 +08:00
mtk07742
4971775314 [ALPS04811125] Add getattr rule in system_server
Add getattr rule for mddb_filter_data_file in system_server.

MTK-Commit-Id: 839f2b7648dbd15dcabd9bf2c4021d57867b2649

Change-Id: I05012778bcb29ea2ecbafd0ea946d8a7c7605bae
CR-Id: ALPS04811125
Feature: [Module]SystemServer
2020-01-18 10:21:17 +08:00
bo.shang
34e4338c7e [ALPS04760404] Remove SElinux code
1. Dont create folder in data by process self

MTK-Commit-Id: 137bc58be1b0069794c7b52db91f8532e406bf31

Change-Id: I20c0ca16c66490b81a03192eb642131b50933933
CR-Id: ALPS04760404
Feature: Modem Log Tool
2020-01-18 10:20:51 +08:00
Guoyi Qu
cf0ffa1738 [ALPS04760297] SEPolicy Optimize
Revise high risk SEPolicies.

MTK-Commit-Id: 54290cb8aeb0fbb67310ed0cffe826684158effe

CR-Id: ALPS04760297
Feature: Connsys Log Tool
Change-Id: I369c7a917f8ee9cc95e0db14e552ce9195583a14
2020-01-18 10:20:40 +08:00
mtk81216
f2c63662c0 [ALPS04763235] remove pppoe related
in ppp.te, some property is set for pppoe, since pppoe feature
is phased out, just remove related sepolicy rules

MTK-Commit-Id: 0c0b761b1dc65ddf5375d62ff5ed13d9df6a0e4c

Change-Id: I063224db045b9e57e2b2ad8e8f36ff1ff2b46f18
CR-Id: ALPS04763235
Feature: [Module]IP Networking
2020-01-18 10:20:29 +08:00
bo.shang
53a2892e48 [ALPS04788229] Add selinux permssion
could read persist.sys. property

MTK-Commit-Id: 266f05feffaee309566f7d7410f7a00463457ff6

Change-Id: I380ef42f2549eca315fb9c69bf03bee097a18f08
CR-Id: ALPS04788229
Feature: Modem Log Tool
2020-01-18 10:20:25 +08:00
Guoyi Qu
dab7fbe9a1 [ALPS04727197] Add permission
Add permission to save logs to special folder

MTK-Commit-Id: 51c58a7b5b66247b1ab454f71e6cc721ff83f61f

Change-Id: I00b58af1ae46842c84f183c2154583e59e98199b
CR-Id: ALPS04727197
Feature: Modem Log Tool
2020-01-18 10:20:16 +08:00
Nancy Huang
9e238bfba9 [ALPS04760196] audioserver: fix high risk sepolicy
[Detail]
1. Remove system_data_file access rule
2. Remove socket access in audioserver

MTK-Commit-Id: 53231b8b52745a21cc302833524911c55bab4960

Change-Id: I661f78bfbe0377bf88445494af0f33edb5f4fef7
CR-Id: ALPS04760196
Feature: [Module]Proprietary Audio Utility
2020-01-18 10:20:04 +08:00
bo.shang
6eceb7c147 [ALPS04761154] Remove risk selinux permission
Remove create folder in data selinux permission

MTK-Commit-Id: d6a218ddee9f5bcde67381631e400a8c3d5a4497

Change-Id: I031aa0ba9463796a11e6ba68774595ad2ff40ce4
CR-Id: ALPS04761154
Feature: Network Log Tool
2020-01-18 10:19:53 +08:00
mtk10871
6d71aabb69 [ALPS04690934] BT feature: log in data area
[Detail]
Log is available to store in data area.
Change api for setting corresponding permission.

MTK-Commit-Id: 00be41e217b22f187a664d5d51cb18d52bc63635

Change-Id: I69c0869067e8f815c0f41930248b1c0e2c7f6358
CR-Id: ALPS04690934
Feature: BT AOSP
(cherry picked from commit e7396905545c154bc2ff6e76b4fa117ddbca0bb9)
2020-01-18 10:19:50 +08:00
Caroline Yang
61181c335d [ALPS04763248] Remove unused sepolicies
[Detail]
Remove unused sepolicies of thermalindicator.

MTK-Commit-Id: 3a0b1cc66e7e651ee0f0307654389e25c4e721d9

Change-Id: I535e42ae60b0170f621452aca19419283a7fa3fe
CR-Id: ALPS04763248
Feature: [Android Default] SELinux, SEAndroid, and SE-MTK
2020-01-18 10:19:24 +08:00
zhuoliang zhang
35c1be8aab [ALPS04760322] high risk sepolicies of dhcp
delete the legacy selinux file :dhcp.te

MTK-Commit-Id: b963a9f2c64ece1174cd78d6602cd7ddc768e347

Change-Id: I8a2a10f3c1f2626836abc3b514c97df43a1795de
CR-Id: ALPS04760322
Feature: [Module]IP Networking
2020-01-18 10:19:23 +08:00
hua.tian
482be9e9f2 [ALPS04746763] Remove unsafe rules
Remove the rules to create folder under /data in own process.

MTK-Commit-Id: 7bda57233e721387cb85dc246253a66de9e1ee46

Change-Id: I904278893497cd1270840b7e2bd4d20e3bc9dde9
CR-Id: ALPS04746763
Feature: Mobile Log Tool
2020-01-18 10:19:04 +08:00
yuru.zhu
4f38a2249a [ALPS04742139] Support save log to data partition
[Solution] Add se-linux permission for delete & taglog

MTK-Commit-Id: e6e9a17da095f4f4e9d7c2c62eb5aa32b65a7bd9

Change-Id: I2c9d255ec0a8629dfb9f9b57cdc0ea8a25c8d852
CR-Id: ALPS04742139
Feature: MTKLogger
(cherry picked from commit a0eb93aae4b3fef928490e78dad057a1a315593a)
2020-01-18 10:18:50 +08:00
xin xu
9a17313658 [ALPS04329540] ccci: add sepolicy rule for ccci_mdinit
add a init.svc.aee_aedv sepolicy rule.

MTK-Commit-Id: 6777d53c3d3fa914fbf1aefe999eb90db6300e45

Change-Id: I7acfe0fe761b63c6560dffc083162157832aa6a7
CR-Id: ALPS04329540
Feature: Modem Interface Driver
(cherry picked from commit 1e62fd097cee1270807f1e807feecbf313dac750)
2020-01-18 10:18:29 +08:00
mtk06389
f697fb2b40 [ALPS04723934] SEPolicy: Remove phased-out guiext rules
Remove guiext rules because guiext has been phased out

MTK-Commit-Id: 0684124257af5ca2c55c48473e1568710ce098d4

Change-Id: I8aae89d8dd2388fb9f13a55331de46284e9b97ee
CR-Id: ALPS04723934
Feature: [Android Default] SELinux, SEAndroid, and SE-MTK
(cherry picked from commit c8b973fb79f79bff081dae58d665d235bfffc23a)
2020-01-18 10:18:20 +08:00
bo.shang
c6f62897b6 [ALPS04721702] Save log into data partition
1. Add SELinux permission

MTK-Commit-Id: 49d711749e59016b1e46233c4569c9d22d957f3d

Change-Id: If172698697fa5005f4548328665ea6c4739315c8
CR-Id: ALPS04721702
Feature: Modem Log Tool
2020-01-18 10:18:19 +08:00
Jonas Lai
8d8e513025 [ALPS04314391] sepolicy: aee_aedv/dumpstate access to camerahalserver
Allow aee_aedv/dumpstate to dump debug info from camerahalserver.

- SELinux : avc:  denied  { find } for
  interface=android.hardware.camera.provider::ICameraProvider
  sid=u:r:aee_aedv:s0 pid=23819 scontext=u:r:aee_aedv:s0
  tcontext=u:object_r:hal_camera_hwservice:s0
  tclass=hwservice_manager permissive=0

MTK-Commit-Id: 18210cf3984bd62caa334f28e45bb0f99500bac8

Change-Id: I291450101bd0ea94fca47b592cb1ef7ffb7f1ae4
CR-Id: ALPS04314391
Feature: [Android Default] Camera Application Basic Functions
2020-01-18 10:18:07 +08:00
Hua Tian (田华)
753142662c Merge "[ALPS04709387] Support to catch MCUPM log" into alps-trunk-q0.basic
Change-Id: I9d160429e50304a82ec83b4c7133126d52ea8eb4
MTK-Commit-Id: 4b4e661646a1ff87863669fd53af94707835bc3c
2020-01-18 10:17:53 +08:00
hua.tian
608a6fd139 [ALPS04709387] Support to catch MCUPM log
Add SELINUX rule for MCUPM log.

MTK-Commit-Id: 9fb8d206f37f0fb00581f4417473974c014ff0dd

Change-Id: I7a935534d4975e444b556d133ff222a4c144b5ca
CR-Id: ALPS04709387
Feature: Mobile Log Tool
2020-01-18 10:17:51 +08:00
bo.shang
5eaf34477d [ALPS04710092] Save network log save log in data
1. Add SElinux permission to save log in data

MTK-Commit-Id: 80d74125ac0c04cb560b2b71bafe89e0d9d7441f

Change-Id: I6f17f70e3530257331331b92bdf095749d64283f
CR-Id: ALPS04710092
Feature: Network Log Tool
2020-01-18 10:17:49 +08:00
Guoyi Qu
b4c0ed52b3 Merge "[ALPS04707995] CTS fail fix" into alps-trunk-q0.basic
Change-Id: I9041039776d47e42e064ac126e154b24492c6769
MTK-Commit-Id: 88ff0b09dbbcc96c825f95a69d2172193ca856c4
2020-01-18 10:17:45 +08:00
Guoyi Qu
e1861f520b [ALPS04707995] CTS fail fix
Move defination to private folder

MTK-Commit-Id: e9fcc4d4a929c928dd475887e6a100a85d641815

Change-Id: I34fc6d2f3c96f8ab9d53f840da53465f7b79e9cf
CR-Id: ALPS04707995
Feature: Connsys Log Tool
2020-01-18 10:17:40 +08:00
Yifei Qiao
9708912e27 [ALPS04700799] Align keymanager sepolicy with p0.mp6
Align keymanager sepolicy with p0.mp6

MTK-Commit-Id: 24a187bc32e2be7663abb880c07659834d71f4b0

Change-Id: Ia98525be2155dcf3261633d1e6c25a775426068d
CR-Id: ALPS04700799
Feature: [Android Default] SELinux, SEAndroid, and SE-MTK
2020-01-18 10:17:31 +08:00
Jiaqin Wang
18cc043b42 [ALPS04689352] ADB:add allow priority
move persist.adb.nonblocking_ffs from
PRODUCT_SYSTEM_DEFAULT_PROPERTIES to
PRODUCT_PROPERTY_OVERRIDES, need add
allow priority to let adb daemon to
get/read it

MTK-Commit-Id: 0489198430c2ac2412ebebdc6e24bf8fd0797bf1

Change-Id: I9f69bddfdd307a3d13a8516076b4106f4b0bdf82
CR-Id: ALPS04689352
Feature: [Android Default] ADB (Android Debug Bridge)
2020-01-18 10:17:05 +08:00
hua.tian
7574cf2c9c [ALPS04649268] Move SELINUX policies to plat_private
These policies are for system process, as a result,
move it to plat_private folder.

MTK-Commit-Id: 46e87002024d5675d566dd59f77cbde9c69bdd37

Change-Id: I9c2b72136d1f1c3062f0ac6b174c8334b1965e80
CR-Id: ALPS04649268
Feature: Mobile Log Tool
2020-01-18 10:16:47 +08:00
Jianping Jiang
109462e1f2 [ALPS04674290] Correct mnld_device type
1. Remove mnld_device from lbs_dbg.te;
2. move mnld_device type to non_plat folder

MTK-Commit-Id: f575807c7ac6d6a30595479ae03339b5765ff884

Change-Id: I8ba23283a103f52c045ae6c69ec7fc4eca06df84
CR-Id: ALPS04674290
Feature: Location Chipset Capability
2020-01-18 10:16:26 +08:00
Bo Shang
0e2cfc1985 Merge "[ALPS04669246] add sepolicy for dump proc/net" into alps-trunk-q0.basic
Change-Id: Icbee725aa67aa16d2fc36bb9fe9c71d055ac375b
MTK-Commit-Id: 7e29142f0ed4964fd2aeaf64b9143a8383d8930f
2020-01-18 10:15:56 +08:00
mtk11515
8f52102087 [ALPS04669246] add sepolicy for dump proc/net
[Solution] add sepolicy for dump proc/net

MTK-Commit-Id: 676c040c07303066916c4f1ca1d3f4d410b6735d

Change-Id: I4e3924a4b5ac611c2cce7b071935fed2b71c3398
CR-Id: ALPS04669246
Feature: Network Log Tool
2020-01-18 10:15:50 +08:00
bo.shang
5068833fef [ALPS04532537] Copy vendor modem db and filter
New feature:

Add selinux of HIDL service and client.

Use HIDL copy modem db and filter from vendor image

to data partition for modem log tool.

MTK-Commit-Id: 7fadaf0f2a60d05d7464264ef9e23a75ca27bb66

Change-Id: I12cc8614537f30e90a1717f9838c52283342eb55
CR-Id: ALPS04532537
Feature: Modem Log Tool
2020-01-18 10:15:08 +08:00
Jianping Jiang
11f88203b8 [ALPS04255502] lbs_dbg: move lbs_dbg sepolicy to system
Move lbs_dbg sepolicy to system for System/vendor Layer decouple

MTK-Commit-Id: a4638ef15ca2020d8f7eba6ab2d053d7716d0ad4

Change-Id: I4ecfb1276b47ec75bab4c72ff04ebeb035d757b3
CR-Id: ALPS04255502
Feature: Location Aiding
2020-01-18 10:14:12 +08:00
dengwei.xu
c6ed642277 [ALPS04285435] EM hidl server sepolicy
Fix the EM hidl server sepllicy build errro

MTK-Commit-Id: 8b95a2baf6f04fd1c8ec5fa6548f78203a581e3d

Change-Id: Iac820d493352c5d37991c23cb10c01f9615ed888
CR-Id: ALPS04285435
Feature: Engineering Mode
2020-01-18 10:13:51 +08:00
mtk11285
a250fc423c [ALPS03806577] catch manual coredump fail
add some rules for aee_aedv/aee_aed to read /proc/*/exe

MTK-Commit-Id: a1ee357e85a32beded54046bb1b638eb8fe4b3c9

Change-Id: Ideeb8002a9d1b9b166709442195124cce8e4e427
CR-Id: ALPS03806577
Feature: Android Exception Engine(AEE)
2020-01-18 10:13:24 +08:00
mtk11285
0b7ed7df47 [ALPS03806577] add DropBoxReceiver feature
1. allow dropboxreceiver to receive dropbox message
2. allow aee_aed to read packages.list

MTK-Commit-Id: 03d7fff0159d697f13fd574b132503ba6063cfab

Change-Id: Id717233c2ade4b0b8c3d6a8319647ff6e783a60a
CR-Id: ALPS03806577
Feature: Android Exception Engine(AEE)
2020-01-18 10:13:14 +08:00
bo.shang
1aa4b07238 [ALPS04382560] Add selinux permission
Add map permission for kernel API dump error

MTK-Commit-Id: 07c68bea7a790c49b3870393bf046688a19b2e58

Change-Id: I01b3f39bcc365ccedb1fc029b92307e91bece05a
CR-Id: ALPS04382560
Feature: Network Log Tool
2020-01-18 10:11:31 +08:00
yuhui.zhang
03dda6b5df [ALPS04316338] EM: battery temperature settings
[Detail]
Add sepolicy rule to set battery temperature

MTK-Commit-Id: 9fcd042bd04632fa952af7ac51833695b8a50f7c

Change-Id: I82b8b6649849403a1b1cd8a2e5093a3664719bc2
CR-Id: ALPS04316338
Feature: Engineering Mode
2020-01-18 10:09:55 +08:00
Larry Liang
10cad58309 Merge "[ALPS04325589] AEE: remove unuse rules" into alps-trunk-q0.basic
Change-Id: Ia92a7b6be46762af09a64e2c7e92607a1c734858
MTK-Commit-Id: e98481807b7d50c68a8e5bd8926df0dcf4398017
2020-01-18 10:09:48 +08:00
mtk11285
85b3620577 [ALPS04325589] AEE: remove unuse rules
1. remove unuse rules
2. allow dumpstate to r/w /proc/msdc_debug
3. allow aee_core_forwarder to access hwservicemanager_prop
4. allow aee_core_forwarder to connect aee_aed socket

MTK-Commit-Id: a43676c734f74636df65e59cdcace017eca79706

Change-Id: I3c45ed83499c0079b38af34cf462dcd80fec501d
CR-Id: ALPS04325589
Feature: Android Exception Engine(AEE)
2020-01-18 10:09:44 +08:00
Shanshan Guo
427c135bd6 [ALPS04340791] SEPOLICY: workaround fix BASIC build error
[Detail]
Only BASIC Sepolicy need to be applyed for BASIC,
we separate basic/bsp sepolicy for BASIC.
This workaround is for fixing the build errors that
cause by the declarations were defined in bsp/ dir
and neverallow rules.

MTK-Commit-Id: f1ed54e84b85f73e20dcc8c2ac5f0c42fddedc77

Change-Id: I568873fcc272d04b018efc4be00924b751bb3775
CR-Id: ALPS04340791
Feature: [Android Default] SELinux, SEAndroid, and SE-MTK
2020-01-18 10:09:28 +08:00
bo.shang
aa52b35cf1 [ALPS04365111] Fix selinux error
Add socket map permission

MTK-Commit-Id: 5a8050e1faffde6adc067eea37fe99434a2f88a5

Change-Id: Ie3009b81bdae187422fb26644834bec2d145d491
CR-Id: ALPS04365111
Feature: Network Log Tool
2020-01-18 10:09:15 +08:00
Elvin Lin
9f2e49db1c [ALPS04324880] em_svr: add map permission for shell_exec
[Detail]
Add map permission for shell_exec to let Batterylog.java
can set command from shell.
Modify the permission list to rx_file_perms.

MTK-Commit-Id: d8f72393dddc2787c88bb2141594319bfe473e9a

Change-Id: I04b1b5c056223e30d5d8b6f8fe7a503afc28b521
CR-Id: ALPS04324880
Feature: Power Delivery
(cherry picked from commit 63fd26ecb2014b5a03db649b332858943a6893a9)
2020-01-18 10:08:19 +08:00
Po Hu
4f97064d35 [ALPS04209994] Android Q migration prepare
[Detail]
Fix build warning like:
WARNING unrecognized character at token ^M on line XXX:

[Solution]
Use dos2unix to update files

MTK-Commit-Id: 8285bcfe7a30349f3188c9b29e4b8da9ee2c1280

Change-Id: I7773e243028a2275d11782885b4bc299d5c5d043
CR-Id: ALPS04209994
Feature: build process
2020-01-18 10:08:11 +08:00
Juju Sung
12bc2025e2 [ALPS04239425] Sepolicy: fix undefined type declration
[Detail]
Unknown type:untrusted_v2_app,alarm_device,qtaguid_proc,mtd_device
Duplicated type:proc_slabinfo

MTK-Commit-Id: 11ccfcffb994452eb58a697e94a8da748ac73933

Change-Id: I2e847041d14d6b6613044cfaa98f242b7fd9381a
CR-Id: ALPS04239425
Feature: Build System
2020-01-18 10:08:05 +08:00
mtk16229
0016bf873f [ALPS04112420] add mota selinux limited
[Detail]add mota selinux linited

MTK-Commit-Id: 7762b88c2e81f42f95232f00c1c2cf0e81d47421

Change-Id: I5071ca451510cd14a8ccf53e8e77c3e77f50816b
Signed-off-by: mtk16229 <Heaven.Zhang@mediatek.com>
CR-Id: ALPS04112420
Feature: MOTA (Mediatek Over The Air)
2020-01-18 10:07:40 +08:00
mtk11515
4990fac4dd [ALPS04085854] make service auto run
[Solution] Make service auto run.

MTK-Commit-Id: 5e7859bac9dd91730634cfa9623936ee8f630fef

Change-Id: I6ae5c40a6d12d077bfe8093cdf7f4d9b32698a82
CR-Id: ALPS04085854
Feature: MTKLogger
(cherry picked from commit a8d2a91b7b056b3825e55dbbad4045dff361d08e)
2020-01-18 10:06:54 +08:00