mirror of https://github.com/Qortal/Brooklyn
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
428 B
18 lines
428 B
#include <linux/kernel.h> |
|
#include <linux/sched.h> |
|
#include <linux/grsecurity.h> |
|
#include <linux/grinternal.h> |
|
#include <linux/capability.h> |
|
#include <linux/tty.h> |
|
|
|
int gr_handle_tiocsti(struct tty_struct *tty) |
|
{ |
|
#ifdef CONFIG_GRKERNSEC_HARDEN_TTY |
|
if (grsec_enable_harden_tty && (current->signal->tty == tty) && |
|
!capable(CAP_SYS_ADMIN)) { |
|
gr_log_noargs(GR_DONT_AUDIT, GR_TIOCSTI_MSG); |
|
return 1; |
|
} |
|
#endif |
|
return 0; |
|
}
|
|
|