kernel: Remove prctl; use netlink communication to control manual_su
This commit is contained in:
23
kernel/ksu_netlink.h
Normal file
23
kernel/ksu_netlink.h
Normal file
@@ -0,0 +1,23 @@
|
||||
#ifndef __KSU_NETLINK_H
|
||||
#define __KSU_NETLINK_H
|
||||
|
||||
#include <linux/netlink.h>
|
||||
#include <linux/skbuff.h>
|
||||
#include <net/sock.h>
|
||||
|
||||
#define KSU_NETLINK_PROTOCOL 2
|
||||
#define KSU_NETLINK_CMD_MANUAL_SU 50
|
||||
|
||||
struct ksu_netlink_msg {
|
||||
int cmd;
|
||||
int option;
|
||||
uid_t target_uid;
|
||||
pid_t target_pid;
|
||||
char token_buffer[33];
|
||||
int result;
|
||||
};
|
||||
|
||||
int ksu_netlink_init(void);
|
||||
void ksu_netlink_exit(void);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user