weishu
849164e4de
kernel: fix compile err
2023-02-20 20:06:56 +07:00
weishu
683ba112aa
kernel: add prefix to avoid symbol confliction
2023-02-20 18:51:59 +07:00
weishu
e743722449
kernel: make some compiler happy
2023-02-20 18:51:59 +07:00
weishu
83b0aed52a
kernel: apply rules should return success when selinux is disabled or permissive
2023-02-20 18:13:53 +07:00
Nullptr
a161c318a1
kernel: allow root processes to get allow/deny list ( #256 )
2023-02-19 16:09:21 +08: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
b024b5d006
kernel: support add_type for 4.x kernel
...
Co-authored-by: Ookiineko <chiisaineko@protonmail.com >
2023-02-14 19:08:18 +07:00
weishu
d5bab2317e
kernel: correctly handle add attr
2023-02-14 18:52:48 +07:00
weishu
f9b3218ded
kernel: fix policydb length
2023-02-14 14:41:00 +07:00
weishu
051fc53a4f
kernel: count time of volumedown to enter safemode
2023-02-13 22:01:59 +07:00
weishu
ca950d909b
kernel: press KEY_VOLUMEDOWN over 2 seconds will enter safemode and disable all modules
...
Co-authored-by: Ylarod <me@ylarod.cn >
2023-02-13 21:23:28 +07: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
weishu
388d2b0b59
kernel: disable inofity for fd opened for manager
2023-02-12 12:15:58 +07:00
f19
89394245b1
fix KSU_GIT_VERSION is not defined while importing KSU by 'git submodule add' ( #224 )
...
.git is a text file while the module is imported by 'git submodule add'.
2023-02-10 16:34:47 +08:00
Aquarius223
66284bfbe3
kernel: Correctly judge the version of selinux_state ( #214 )
...
* Merged related changes in android-common-kernel-4.14.163 [1] Handle
correct checks for older versions (below 4.14.163, 4.9, 4.4)
* fixes 14be7562 , it is required in 4.14.163 kernel, it is not needed in
4.14.163 and later
[1]: https://github.com/MiCode/Xiaomi_Kernel_OpenSource/commits/1cfd8419
Change-Id: Iade104312d058a249667ca836259d5608418bb55
Co-authored-by: admin <paper@localhost>
2023-02-07 15:02:48 +08:00
初羽
14be75629b
kernel: selinux: Fix build error ( #213 )
...
* d77ab8d although fixed some typo, but since there is no include avc.h,
this will cause the build to fail
* Error:
/mnt/HDD/fish/aospa/kernel/msm-4.9/drivers/staging/ksu/selinux/selinux.c:60:2:
error: use of undeclared identifier 'selinux_enforcing'
selinux_enforcing = enforce;
^
/mnt/HDD/fish/aospa/kernel/msm-4.9/drivers/staging/ksu/selinux/selinux.c:81:9:
error: use of undeclared identifier 'selinux_enforcing'
return selinux_enforcing;
^
2 errors generated.
Change-Id: I4cc8917b2b73ca467873222e02d498da8718988e
2023-02-07 09:50:55 +08:00
小さい猫
d77ab8dbff
kernel: selinux: fix more typos introduced in #166 ( #212 )
...
i didn't realize these typos in #181
Signed-off-by: Ookiineko <chiisaineko@protonmail.com >
2023-02-06 16:31:26 +08:00
weishu
c2ac548ac7
kernel: allow use without git submodule
2023-02-06 15:30:58 +07:00
weishu
0a12d0139d
kernel: make sure KernelSU is a submodule to avoding incorrect git version
2023-02-05 16:31:50 +07:00
f19
0c322a33bc
kernel: fix filp_open on older kernel's kworker ( #205 )
...
On older kernel, kworker missing keyring from init process , and this
keyring is related to FBE , which causes filp_open return ENOKEY or
other errors.To fix this,just install init's keyring to per
kworkers.This works on Kernel 4.4 and 4.9.
2023-02-05 07:14:59 +08:00
skbeh
9f4a8d3dfc
ksud, kernel: update explanation and fix some issues ( #194 )
2023-02-04 13:16:51 +08:00
weishu
4da829792f
kernel: unify version
2023-02-03 23:01:02 +07:00
小さい猫
199f5cc223
fix some typos introduced in #166 ( #181 )
...
Signed-off-by: Ookiineko <chiisaineko@protonmail.com >
Co-authored-by: f19 <58457605+F-19-F@users.noreply.github.com >
Co-authored-by: Scirese <nuclearlight91@gmail.com >
2023-02-02 23:38:04 +08:00
weishu
d1e7bad18f
kernel: version 15
2023-02-02 09:05:37 +07:00
tiann
a969af8159
relicense kernel source code to GPL-v2
2023-02-02 09:04:07 +08: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
62be9eb589
kernel: version 14
2023-01-31 20:55:25 +07:00
weishu
ab6d483c32
kernel: fix sepolicy rule which contains *
2023-01-31 20:51:02 +07:00
weishu
2d77f84736
kernel: bump version 13
2023-01-31 19:21:21 +07:00
weishu
b9e27621ee
kernel: support sepolicy
2023-01-31 18:54:31 +07:00
Ylarod
905c041a76
ci: common kernel build and embed ksud ( #127 )
2023-01-28 12:24:43 +08:00
weishu
cf5bcc09e8
kernel: version 12
2023-01-26 16:16:00 +07:00
weishu
413a8d0a2f
kernel: support selinux state transition
2023-01-26 16:05:14 +07:00
weishu
1852652029
kernel: add sepolicy calls
2023-01-26 16:05:14 +07:00
Ylarod
ee7065bc12
kernel: minor fix ( #122 )
2023-01-26 14:55:41 +08:00
Ylarod
8446f07a91
kernel: update debug warning ( #121 )
2023-01-26 14:32:52 +08: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
22b66b6672
kernel: opt allowlist persist and log ( #119 )
...
* kernel: persist on need
* kernel: opt log for ksu_allow_uid
2023-01-26 08:55:27 +08:00
Ylarod
06aaae1335
kernel: fix missing log tag ( #117 )
2023-01-25 22:24:00 +08:00
Ylarod
810087b2a7
kernel: bump version to 11
2023-01-25 21:55:47 +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
Ylarod
47a736f567
kernel: allow to change manager in debug mode ( #111 )
2023-01-25 14:50:44 +08:00
Ylarod
423f4aaf1f
kernel: add missing header ( #110 )
2023-01-24 22:32:16 +08:00
weishu
1d55c987a6
kernel: bump version to 10
2023-01-24 19:49:08 +07:00
weishu
e5044b4b6f
kernel: selinux support add new type and add builtin unconstrained file type
2023-01-24 19:48:41 +07:00
weishu
fbd7d0f90d
kernel: enable sucompat iff KPROBES enabled, close #100
2023-01-24 14:38:33 +07:00
Ylarod
4c28932c4c
kernel: run ksu_kprobe_init if build as module ( #109 )
2023-01-24 08:42:25 +08:00