diff options
author | William A. Kennington III <william@wkennington.com> | 2015-03-30 02:36:34 -0700 |
---|---|---|
committer | William A. Kennington III <william@wkennington.com> | 2015-03-30 02:36:34 -0700 |
commit | c9bbf2228f7a71f6bdec51a0c7bbb9ba7206c1ff (patch) | |
tree | ff80d1b12b779dc063e1c5f7891149068eaf02e3 /pkgs/os-specific | |
parent | 7ed5918b6c75a90e9f5f44ed7be982bdd2b04bd8 (diff) | |
parent | d567e12eb772e389d8a0f31b1b7b6e5bc93eb20d (diff) |
Merge pull request #7069 from taktoa/master
Fixed grsecurity path patch for testing (3.19)
Diffstat (limited to 'pkgs/os-specific')
-rw-r--r-- | pkgs/os-specific/linux/kernel/grsec-path.patch | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/pkgs/os-specific/linux/kernel/grsec-path.patch b/pkgs/os-specific/linux/kernel/grsec-path.patch index 6f59cf8d80bd7..aaf7d80dc9194 100644 --- a/pkgs/os-specific/linux/kernel/grsec-path.patch +++ b/pkgs/os-specific/linux/kernel/grsec-path.patch @@ -1,17 +1,18 @@ diff --git a/kernel/kmod.c b/kernel/kmod.c -index 67f7981..03f127d 100644 +index a26e825..29baec1 100644 --- a/kernel/kmod.c +++ b/kernel/kmod.c -@@ -246,9 +246,9 @@ static int ____call_usermodehelper(void *data) +@@ -294,10 +294,9 @@ static int ____call_usermodehelper(void *data) out the path to be used prior to this point and are now operating on that copy */ - if ((strncmp(sub_info->path, "/sbin/", 6) && strncmp(sub_info->path, "/usr/lib/", 9) && - strncmp(sub_info->path, "/lib/", 5) && strncmp(sub_info->path, "/lib64/", 7) && +- strncmp(sub_info->path, "/usr/libexec/", 13) && - strcmp(sub_info->path, "/usr/share/apport/apport")) || strstr(sub_info->path, "..")) { -+ if ((strncmp(sub_info->path, "/sbin/", 6) && strncmp(sub_info->path, "/nix/store/", 11) && -+ strncmp(sub_info->path, "/run/current-system/systemd/lib/", 32)) || -+ strstr(sub_info->path, "..")) { ++ if ((strncmp(sub_info->path, "/sbin/", 6) && strncmp(sub_info->path, "/nix/store/", 11) && ++ strncmp(sub_info->path, "/run/current-system/systemd/lib/", 32)) || ++ strstr(sub_info->path, "..")) { printk(KERN_ALERT "grsec: denied exec of usermode helper binary %.950s located outside of /sbin and system library paths\n", sub_info->path); retval = -EPERM; - goto fail; + goto out; |