Commit Graph

457 Commits

Author SHA1 Message Date
Rifat Azad
c1d4f38c19 kernel: added SuSFS version 2024-12-13 06:21:38 +06:00
Rifat Azad
e15516040d Revert "kernel: susfs: CONFIG_KSU_SUSFS_INFO syscall to get susfs version & variant"
This reverts commit b78c9adf49.
2024-12-13 06:21:38 +06:00
Rifat Azad
b78c9adf49 kernel: susfs: CONFIG_KSU_SUSFS_INFO syscall to get susfs version & variant 2024-12-06 22:48:14 +06:00
Rifat Azad
68c9317885 kernel: additional custom v2_signature size/hash 2024-12-04 16:52:55 +06:00
Rifat Azad
a84b3af65d kernel: setup next branch 2024-12-04 16:47:58 +06:00
Rifat Azad
e1d30d55af kernel: implement SuSFS v1.5.2 2024-12-04 16:30:28 +06:00
Huy Minh
3acb13df65 kernel: Relax dentry_path_raw compare in core_hook (#2041)
On Android-x86 (or BlissOS) it initialize Android by using switch_root
or chroot, when checking a path with dentry_path_raw() it will show the
whole real path instead of the path that we want.

Relax the checking requirement by using strstr to look for
"/system/packages.list" in the string instead of requiring the path to
be "/system/packages.list"

This fixes #1783

Signed-off-by: hmtheboy154 <buingoc67@gmail.com>
2024-09-07 10:59:06 +08:00
LoveSy
d9fda971cd Revert "ksud: [Fix] grant root to the shell in debug mode" (#1860)
Reverts tiann/KernelSU#1853
2024-07-06 19:36:37 +08:00
RobinChen
894115e49d ksud: [Fix] grant root to the shell in debug mode (#1853)
Failed to check app_profile version
2024-07-06 13:37:00 +08:00
5ec1cff
77b252a487 throne_tracker: skip iterate if failed to open dir (#1832)
fix https://github.com/tiann/KernelSU/issues/1800
2024-06-19 09:19:04 +08:00
Wang Han
f881eca862 Convert devpts domain to ksu_file (#1801)
AOSP sepolicy does not allow appdomain to open pts. Hence, convert
devpts domain to ksu_file to allow any access.
2024-06-03 21:21:39 +08:00
Ylarod
97d70b40fc [1.0] Drop Non-GKI Support (#1483)
Co-authored-by: weishu <twsxtd@gmail.com>
2024-06-01 14:50:46 +08:00
Rissu
9fc68e2de6 kernel: fix throne_tracker uncompile-able on 4.4 kernel (issue #1771) (#1773)
in kernel v4.7.10:
extern unsigned int __pure full_name_hash(const char *, unsigned int);

in kernel v4.8.0:
extern unsigned int __pure full_name_hash(const void *salt, const char
*, unsigned int);
2024-05-27 10:35:08 +08:00
Juhyung Park
fb1965ea09 Deadlock fixes (#1758)
Hi,

This PR fixes deadlocks that I've noticed within my kernel, with some
minor optimizations around it.

Thanks.

---------

Signed-off-by: Juhyung Park <qkrwngud825@gmail.com>
2024-05-26 17:03:33 +08:00
weishu
8e973bcbd5 kernel: replace devpts kprobe 2024-05-16 17:16:00 +08:00
weishu
5d6ef355ae kernel: Allow to use in Private Space 2024-05-16 12:03:58 +08:00
weishu
81033bcc48 kernel: fix devpts permission. close #1727 2024-05-16 10:32:48 +08:00
weishu
0e656dd339 kernel: Fix compile error on 4.4. close #1720 2024-05-10 15:01:05 +08:00
weishu
1bec08eacf docs: Add devpts description for non gki 2024-05-09 12:05:10 +08:00
weishu
89818cf85f kernel: transition devpts in kernel 2024-05-08 21:15:49 +08:00
5ec1cff
e4109455b9 su: allocate new pty (#1693) 2024-05-07 19:02:59 +08:00
weishu
7e1889c2ec kernel: close fd early 2024-04-29 15:53:12 +08:00
weishu
2efefcea72 kernel: use library import 2024-04-27 09:55:24 +08:00
weishu
cd73307cd4 kernel: refactor PR_REAL_REGS 2024-04-26 13:25:29 +08:00
weishu
425c326cb5 kernel: fix setup script. close #1625, close #1647 2024-04-26 13:12:57 +08:00
buildbot
714990b7c6 kernel: no need to hook 2024-04-26 12:10:58 +08:00
buildbot
2dc2dbfd45 kernel: use syscall hook for all version, remove code next version if works well 2024-04-26 11:42:24 +08:00
Another Guy
e2b0721af5 Hook syscalls and stable symbols (#1657)
1. Replace `do_execveat_common` with `sys_execve` and `sys_execveat`
2. Replace `input_handle_event` with `input_event` and
`input_inject_event`

Tested on android12-5.10-2024-04, android13-5.15-2024-04.
android14-6.1-2024-04
2024-04-26 11:27:48 +08:00
Heiler Bemerguy
e0c684c5ab throne_tracker: Fix Manager sometimes not detecting KSU and optimize it (#1586)
The original logic was wrong and used 3 strlen()s for every file found,
wasting cpu.

Optimize it by first comparing only the filename length, given we
already know it,
and then strncmp() to compare with "base.apk"

Tested successfully on my Bandido Kernel (4.19)
2024-04-03 14:33:10 +08:00
P. Thịnh
68622eb79f Fixed link typo in kernel/Makefile (#1564)
I spotted this typo when building the Kernel.
2024-03-30 22:16:46 +08:00
weishu
5dd356d8b0 kernel: fix potential dead loop
Co-Authored-by: qwerty472123
2024-03-30 16:13:11 +08:00
weishu
e8f633c003 Revert "kernel: deny all unexpected signature block"
This reverts commit 89eaf009c8.
2024-03-30 16:05:31 +08:00
weishu
c0270b52c6 Revert "kernel: deny unexpected offset value for signing check"
This reverts commit d5cd579b60.
2024-03-30 16:05:31 +08:00
weishu
d5cd579b60 kernel: deny unexpected offset value for signing check 2024-03-29 14:28:51 +08:00
weishu
89eaf009c8 kernel: deny all unexpected signature block 2024-03-29 14:14:17 +08:00
5ec1cff
a93a35668b kernel: no need to umount and mark as root for manager uid (#1549)
Co-authored-by: LoveSy <shana@zju.edu.cn>
2024-03-29 09:15:18 +08:00
D8G Official
ae8ffe2c10 Fix missing semicolon (#1551)
Fix build non gki kernel
2024-03-28 20:22:00 +08:00
Coconut
4584aa7f4e kernel:Add Huawei hisi check (#1545)
Use huawei_hisi_check.h to determine whether it is an old Huawei
HiSilicon device.
Solve:  
1. Compatible with non-GKI Huawei HiSilicon devices
2. Solve different bugs in EMUI of different system versions
3. Does not affect other devices
2024-03-28 14:20:00 +08:00
weishu
ba9580e4d0 kernel: fix debug set manager 2024-03-27 17:58:47 +08:00
weishu
ea0ee0563a kernel: Fix misleading log 2024-03-27 17:29:03 +08:00
CallMESuper
2cc2312409 kernel: fix issue with dfd parameter retrieval (#1543)
Although in most cases, this system call might not be used, or when
called, AT_FDCWD(-100) is passed in.
2024-03-27 16:29:53 +08:00
weishu
1b71aa2c78 kernel: Fix wrong kfree 2024-03-27 13:49:09 +08:00
weishu
4841c2123a kernel: alloc path on stack; don't follow symlink 2024-03-27 11:51:41 +08:00
weishu
d87bbfa652 kernel: continue search when open some dir failed 2024-03-26 22:56:59 +08:00
Jprimero15
37410f85a4 kernel: guard "umount for uid" logprint with CONFIG_KSU_DEBUG (#1519)
Its too spammy to be on non-debug mode.
2024-03-24 21:42:23 +08:00
weishu
d8671b14d1 kernel: clean memory when exit 2024-03-24 16:41:53 +08:00
Jprimero15
0710032928 kernel: make for loop compatible (#1517) 2024-03-24 15:04:57 +08:00
weishu
478fda6712 kernel: remove become_manager and minor refactors 2024-03-24 11:20:43 +08:00
weishu
ba66c10ec5 kernel: Fix format error 2024-03-24 00:03:59 +08:00
weishu
a91690eabe kernel: simplify prctl 2024-03-23 23:11:47 +08:00