@@ -146,8 +146,7 @@ static inline bool is_zygote_normal_app_uid(uid_t uid)
|
||||
|
||||
#endif // #ifdef CONFIG_KSU_SUSFS
|
||||
|
||||
bool ksu_module_mounted = false;
|
||||
extern bool ksu_su_compat_enabled;
|
||||
bool ksu_module_mounted __read_mostly = false;
|
||||
|
||||
#ifdef CONFIG_COMPAT
|
||||
bool ksu_is_compat __read_mostly = false;
|
||||
|
||||
@@ -7,4 +7,10 @@
|
||||
void __init ksu_core_init(void);
|
||||
void ksu_core_exit(void);
|
||||
|
||||
void escape_to_root(void);
|
||||
|
||||
void nuke_ext4_sysfs(void);
|
||||
|
||||
extern bool ksu_module_mounted;
|
||||
|
||||
#endif
|
||||
|
||||
@@ -12,17 +12,14 @@
|
||||
#include "klog.h" // IWYU pragma: keep
|
||||
#include "ksu.h"
|
||||
#include "throne_tracker.h"
|
||||
#include "sucompat.h"
|
||||
#include "ksud.h"
|
||||
#include "supercalls.h"
|
||||
|
||||
#ifdef CONFIG_KSU_SUSFS
|
||||
#include <linux/susfs.h>
|
||||
#endif
|
||||
|
||||
extern void ksu_sucompat_init();
|
||||
extern void ksu_sucompat_exit();
|
||||
extern void ksu_ksud_init();
|
||||
extern void ksu_ksud_exit();
|
||||
extern void ksu_supercalls_init();
|
||||
|
||||
int __init kernelsu_init(void)
|
||||
{
|
||||
pr_info("kernelsu.enabled=%d\n",
|
||||
|
||||
@@ -5,6 +5,9 @@
|
||||
|
||||
#define KSUD_PATH "/data/adb/ksud"
|
||||
|
||||
void ksu_ksud_init();
|
||||
void ksu_ksud_exit();
|
||||
|
||||
void on_post_fs_data(void);
|
||||
|
||||
bool ksu_is_safe_mode(void);
|
||||
|
||||
@@ -37,4 +37,6 @@ bool susfs_is_current_init_domain(void);
|
||||
|
||||
u32 ksu_get_devpts_sid(void);
|
||||
|
||||
int handle_sepolicy(unsigned long arg3, void __user *arg4);
|
||||
|
||||
#endif
|
||||
|
||||
@@ -31,17 +31,13 @@
|
||||
#include "ksud.h"
|
||||
#include "kernel_compat.h"
|
||||
#include "sucompat.h"
|
||||
#include "core_hook.h"
|
||||
#include "sulog.h"
|
||||
|
||||
#define SU_PATH "/system/bin/su"
|
||||
#define SH_PATH "/system/bin/sh"
|
||||
|
||||
extern void escape_to_root(void);
|
||||
|
||||
void ksu_sucompat_enable();
|
||||
void ksu_sucompat_disable();
|
||||
|
||||
bool ksu_su_compat_enabled = true;
|
||||
bool ksu_su_compat_enabled __read_mostly = true;
|
||||
|
||||
static int su_compat_feature_get(u64 *value)
|
||||
{
|
||||
|
||||
@@ -4,6 +4,14 @@
|
||||
#include <linux/thread_info.h>
|
||||
#include <linux/version.h>
|
||||
|
||||
extern bool ksu_su_compat_enabled;
|
||||
|
||||
void ksu_sucompat_init(void);
|
||||
void ksu_sucompat_exit(void);
|
||||
|
||||
void ksu_sucompat_enable(void);
|
||||
void ksu_sucompat_disable(void);
|
||||
|
||||
void ksu_mark_running_process(void);
|
||||
|
||||
static inline void ksu_set_task_tracepoint_flag(struct task_struct *t)
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
#include "manager.h"
|
||||
#include "sulog.h"
|
||||
#include "selinux/selinux.h"
|
||||
#include "core_hook.h"
|
||||
#include "kernel_compat.h"
|
||||
#include "throne_comm.h"
|
||||
#include "dynamic_manager.h"
|
||||
@@ -25,14 +26,6 @@
|
||||
#include "manual_su.h"
|
||||
#endif
|
||||
|
||||
// Forward declarations from core_hook.c
|
||||
extern void escape_to_root(void);
|
||||
extern void nuke_ext4_sysfs(void);
|
||||
extern bool ksu_module_mounted;
|
||||
extern int handle_sepolicy(unsigned long arg3, void __user *arg4);
|
||||
extern void ksu_sucompat_init(void);
|
||||
extern void ksu_sucompat_exit(void);
|
||||
|
||||
bool ksu_uid_scanner_enabled = false;
|
||||
|
||||
// Permission check functions
|
||||
|
||||
@@ -154,4 +154,6 @@ struct ksu_ioctl_cmd_map {
|
||||
// Install KSU fd to current process
|
||||
int ksu_install_fd(void);
|
||||
|
||||
void ksu_supercalls_init();
|
||||
|
||||
#endif // __KSU_H_SUPERCALLS
|
||||
Reference in New Issue
Block a user