apply patch for CVE-2017-0358. NOTE: Fedora does not setuid ntfs-3g, so it should not be vulnerable but some users might make this change so we applied the patch anyways
parent
ce71a3bde6
commit
41a3ae8f16
@ -0,0 +1,38 @@
|
||||
diff -up ntfs-3g_ntfsprogs-2016.2.22/src/lowntfs-3g.c.CVE20170358 ntfs-3g_ntfsprogs-2016.2.22/src/lowntfs-3g.c
|
||||
--- ntfs-3g_ntfsprogs-2016.2.22/src/lowntfs-3g.c.CVE20170358 2017-02-08 16:08:08.133934273 -0500
|
||||
+++ ntfs-3g_ntfsprogs-2016.2.22/src/lowntfs-3g.c 2017-02-08 16:08:42.652134630 -0500
|
||||
@@ -3827,13 +3827,14 @@ static fuse_fstype load_fuse_module(void
|
||||
struct stat st;
|
||||
pid_t pid;
|
||||
const char *cmd = "/sbin/modprobe";
|
||||
+ char *env = (char*)NULL;
|
||||
struct timespec req = { 0, 100000000 }; /* 100 msec */
|
||||
fuse_fstype fstype;
|
||||
|
||||
if (!stat(cmd, &st) && !geteuid()) {
|
||||
pid = fork();
|
||||
if (!pid) {
|
||||
- execl(cmd, cmd, "fuse", NULL);
|
||||
+ execle(cmd, cmd, "fuse", NULL, &env);
|
||||
_exit(1);
|
||||
} else if (pid != -1)
|
||||
waitpid(pid, NULL, 0);
|
||||
diff -up ntfs-3g_ntfsprogs-2016.2.22/src/ntfs-3g.c.CVE20170358 ntfs-3g_ntfsprogs-2016.2.22/src/ntfs-3g.c
|
||||
--- ntfs-3g_ntfsprogs-2016.2.22/src/ntfs-3g.c.CVE20170358 2017-02-08 16:09:05.923595527 -0500
|
||||
+++ ntfs-3g_ntfsprogs-2016.2.22/src/ntfs-3g.c 2017-02-08 16:09:42.448749391 -0500
|
||||
@@ -3612,13 +3612,14 @@ static fuse_fstype load_fuse_module(void
|
||||
struct stat st;
|
||||
pid_t pid;
|
||||
const char *cmd = "/sbin/modprobe";
|
||||
+ char *env = (char*)NULL;
|
||||
struct timespec req = { 0, 100000000 }; /* 100 msec */
|
||||
fuse_fstype fstype;
|
||||
|
||||
if (!stat(cmd, &st) && !geteuid()) {
|
||||
pid = fork();
|
||||
if (!pid) {
|
||||
- execl(cmd, cmd, "fuse", NULL);
|
||||
+ execle(cmd, cmd, "fuse", NULL, &env);
|
||||
_exit(1);
|
||||
} else if (pid != -1)
|
||||
waitpid(pid, NULL, 0);
|
Loading…
Reference in new issue