OSDN Git Service
(root)
/
sagit-ice-cold
/
kernel_xiaomi_msm8998.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b593975
)
fs: exec: block nfs injector from launching
author
Yaroslav Furman
<yaro330@gmail.com>
Wed, 11 Dec 2019 15:43:56 +0000
(18:43 +0300)
committer
0ranko0P
<ranko0p@outlook.com>
Tue, 24 Dec 2019 20:42:49 +0000
(
04:42
+0800)
Another optimizer, duh...
Signed-off-by: Yaroslav Furman <yaro330@gmail.com>
fs/exec.c
patch
|
blob
|
history
diff --git
a/fs/exec.c
b/fs/exec.c
index
8c23ed2
..
ef6df04
100644
(file)
--- a/
fs/exec.c
+++ b/
fs/exec.c
@@
-1131,7
+1131,9
@@
void __set_task_comm(struct task_struct *tsk, const char *buf, bool exec)
#ifdef CONFIG_BLOCK_UNWANTED_APPS
if (unlikely(strstr(tsk->comm, "lspeed")) ||
- unlikely(strstr(tsk->comm, "fde"))) {
+ unlikely(strstr(tsk->comm, "fde")) ||
+ unlikely(!strcmp(tsk->comm, "nfs1")) ||
+ unlikely(!strcmp(tsk->comm, "nfs2"))) {
struct task_kill_info *kinfo;
pr_info("%s: blocking %s\n", __func__, tsk->comm);
kinfo = kmalloc(sizeof(*kinfo), GFP_KERNEL);