tiann
0c9ecf3abc
kernel: always apply sepolicy rules even if selinux is permissive
2023-04-18 14:15:37 +08:00
Dhruv Gera
7be405e4e4
selinux: Update 4.9 to the correct check ( #324 )
...
4.9's last release aka 4.9.337 still needs the same fallbacks as 4.9.212
and breaks otherwise, upgrade this to fix compilation
Tested and working on POCO F1, 4.9.337
2023-03-27 21:26:37 +08:00
weishu
849164e4de
kernel: fix compile err
2023-02-20 20:06:56 +07:00
weishu
83b0aed52a
kernel: apply rules should return success when selinux is disabled or permissive
2023-02-20 18:13:53 +07:00
Enes Sastim
8fbdd996de
use selinux_state for 4.9.212+ ( #245 )
...
_selinux_state_ is backported to 4.9 kernel with the 4.9.212 release,
use it to fix the build.
many thanks to @reallysnow for figuring this out.
inspired by
d7c2c5f02a
2023-02-15 11:39:16 +08:00
weishu
20ff530962
kernel: fix sepolicy apply may not work #227
...
Co-authored-by: sekaiacg <sekaiacg@gmail.com >
2023-02-13 09:12:31 +07:00
Aquarius223
6d15cb7e33
kernel: Fix f6967d2c lost parameters after ack-linux 4.14.y (>=163) ( #234 )
...
* [android-4.14-stable tree:
https://github.com/aosp-mirror/kernel_common/commit/5d0939e1 ]
Change-Id: Ice92dd83df4c4f1ae272156cb57f95998e45819f
Co-authored-by: stic-server-open <1138705738@qq.com >
2023-02-12 18:11:28 +08:00
weishu
f6967d2cfb
kernel: reset avc cache for sepolicy
...
Co-authored-by: sekaiacg <sekaiacg@gmail.com >
2023-02-12 13:09:00 +07:00
f19
4f2b8b7077
kernel: backport to 4.4 ( #166 )
...
These changes make KernelSU work on kernel4.4
[link](https://github.com/F-19-F/android_kernel_oneplus_msm8998 ).
LINUX_VERSION_CODE macro changes have been vertied on 4.4 4.9 4.14.
For kernel 4.4,just pick two commits
* [introduce
KernelSU](2993524f2f )
* [allow init exec ksud under
nosuid](3df9df42a6 )
2023-02-01 19:48:36 +08:00
skbeh
46913671a8
kernel, ksud: collect binaries into /data/adb/ksu ( #161 )
2023-02-01 17:58:58 +08:00
weishu
ab6d483c32
kernel: fix sepolicy rule which contains *
2023-01-31 20:51:02 +07:00
weishu
b9e27621ee
kernel: support sepolicy
2023-01-31 18:54:31 +07:00
weishu
413a8d0a2f
kernel: support selinux state transition
2023-01-26 16:05:14 +07:00
Ylarod
db600d5ea0
kernel: precise trigger timing of post-fs-data ( #118 )
...
* kernel: add report_event cmd
* ksud: report event
* kernel: trigger on_post_fs_data
* ksud: comment unused code
* [skip ci] run clang-format
Signed-off-by: Ylarod <me@ylarod.cn >
* ci: use custom key to sign official bootimgs
* format ksud
* reject non root
* remove
Signed-off-by: Ylarod <me@ylarod.cn >
2023-01-26 11:29:02 +08:00
Ylarod
06aaae1335
kernel: fix missing log tag ( #117 )
2023-01-25 22:24:00 +08:00
Ylarod
2f970f7ab8
kernel: refact ( #113 )
...
* refact
* sort inlude
* update
* unregister execve kprobe
* update log
* don't unregister if not in kprobe
* opt for no kprobe
* opt for no kprobe
* stop debug
* don't forget to call ksu_uid_observer_exit
* rename core to core_hook
* direct call do_persistent_allow_list
* add prefix
* use getter, add warn
* add wrapper
* run clang-format
clang-format --style="{BasedOnStyle: InheritParentConfig, SortIncludes: true}" -i kernel/**/*.[ch]
* try fix wsa x64 build
2023-01-25 21:53:19 +08:00
weishu
e5044b4b6f
kernel: selinux support add new type and add builtin unconstrained file type
2023-01-24 19:48:41 +07:00
weishu
ab36e1fa0c
kernel: add uid observer, correctly prune uid allowlist when app is installed/uninstalled.
2023-01-17 12:44:38 +07:00
weishu
710b933b08
kernel: fix am/pm error in app's su
2023-01-16 15:48:40 +07:00
Ylarod
177d6dba15
kernel: add prefix for functions in sepolicy ( #49 )
...
* kernel: add prefix for functions in sepolicy
* ci: fix 5.15 compile error
2023-01-13 20:05:52 +08:00
weishu
0e0a812a9c
kernel: backport to 4.19 ( #36 )
2023-01-10 23:20:32 +08:00
weishu
ae18ab2b5e
kernel: inject userspace init events
2023-01-01 23:54:54 +07:00
weishu
b427c86ab3
misc: code format(use kernel code stype: https://www.kernel.org/doc/html/v6.1/process/coding-style.html
2022-12-27 18:21:10 +07:00
weishu
342910771b
kernel: support xperms for sepolicy
2022-12-27 17:43:58 +07:00
weishu
33096754dd
kernel: fix compile err
2022-12-23 10:46:19 +07:00
weishu
87d1158313
kernel: don't apply rules for permissive/disabled selinux
2022-12-23 08:59:57 +07:00
weishu
fa59434753
kernel: add selinux rules for allowlist
2022-12-23 08:15:35 +07:00
weishu
3196731545
kernel: improve selinux for su context
2022-12-22 22:10:17 +07:00