aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/patches/rsync-CVE-2017-17433.patch
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2017-12-18 22:37:41 +0200
committerEfraim Flashner <efraim@flashner.co.il>2017-12-18 22:53:46 +0200
commit91675d50824065cc03304d5bdef5212ceb1ce92d (patch)
treee339302547ea0a326c07ef607f71a5f13c3ef9e4 /gnu/packages/patches/rsync-CVE-2017-17433.patch
parentb50a9cc0088c2bf58a3576734afc614f458fa931 (diff)
downloadguix-91675d50824065cc03304d5bdef5212ceb1ce92d.tar
guix-91675d50824065cc03304d5bdef5212ceb1ce92d.tar.gz
gnu: rsync: Patch CVE-2017-{16548,17433,17434}.
* gnu/packages/rsync.scm (rsync)[source]: Add patches. [properties]: Mark CVE-2017-15994 as not relevant. * gnu/packages/patches/rsync-CVE-2017-16548.patch, gnu/packages/patches/rsync-CVE-2017-17433.patch, gnu/packages/patches/rsync-CVE-2017-17433-fix-tests.patch, gnu/packages/patches/rsync-CVE-2017-17434-pt1.patch, gnu/packages/patches/rsync-CVE-2017-17434-pt2.patch: New files. * gnu/local.mk (dist_patch_DATA): Register them.
Diffstat (limited to 'gnu/packages/patches/rsync-CVE-2017-17433.patch')
-rw-r--r--gnu/packages/patches/rsync-CVE-2017-17433.patch45
1 files changed, 45 insertions, 0 deletions
diff --git a/gnu/packages/patches/rsync-CVE-2017-17433.patch b/gnu/packages/patches/rsync-CVE-2017-17433.patch
new file mode 100644
index 0000000000..84e4067509
--- /dev/null
+++ b/gnu/packages/patches/rsync-CVE-2017-17433.patch
@@ -0,0 +1,45 @@
+https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2017-17433
+https://git.samba.org/?p=rsync.git;a=patch;h=3e06d40029cfdce9d0f73d87cfd4edaf54be9c51
+
+From 3e06d40029cfdce9d0f73d87cfd4edaf54be9c51 Mon Sep 17 00:00:00 2001
+From: Jeriko One <jeriko.one@gmx.us>
+Date: Thu, 2 Nov 2017 23:44:19 -0700
+Subject: [PATCH] Check fname in recv_files sooner.
+
+---
+ receiver.c | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/receiver.c b/receiver.c
+index baae3a9..9fdafa1 100644
+--- a/receiver.c
++++ b/receiver.c
+@@ -574,6 +574,12 @@ int recv_files(int f_in, int f_out, char *local_name)
+ file = dir_flist->files[cur_flist->parent_ndx];
+ fname = local_name ? local_name : f_name(file, fbuf);
+
++ if (daemon_filter_list.head
++ && check_filter(&daemon_filter_list, FLOG, fname, 0) < 0) {
++ rprintf(FERROR, "attempt to hack rsync failed.\n");
++ exit_cleanup(RERR_PROTOCOL);
++ }
++
+ if (DEBUG_GTE(RECV, 1))
+ rprintf(FINFO, "recv_files(%s)\n", fname);
+
+@@ -645,12 +651,6 @@ int recv_files(int f_in, int f_out, char *local_name)
+
+ cleanup_got_literal = 0;
+
+- if (daemon_filter_list.head
+- && check_filter(&daemon_filter_list, FLOG, fname, 0) < 0) {
+- rprintf(FERROR, "attempt to hack rsync failed.\n");
+- exit_cleanup(RERR_PROTOCOL);
+- }
+-
+ if (read_batch) {
+ int wanted = redoing
+ ? we_want_redo(ndx)
+--
+1.9.1
+