--- a/components/rsync/Makefile Thu May 05 07:38:15 2016 -0700
+++ b/components/rsync/Makefile Mon May 16 17:05:06 2016 -0700
@@ -26,13 +26,13 @@
include ../../make-rules/shared-macros.mk
COMPONENT_NAME= rsync
-COMPONENT_VERSION= 3.1.1
+COMPONENT_VERSION= 3.1.2
COMPONENT_PROJECT_URL= http://rsync.samba.org/
COMPONENT_ARCHIVE_HASH= \
- sha256:7de4364fcf5fe42f3bdb514417f1c40d10bbca896abe7e7f2c581c6ea08a2621
+ sha256:ecfa62a7fa3c4c18b9eccd8c16eaddee4bd308a76ea50b5c02a5840f09c0a1c2
COMPONENT_ARCHIVE_URL= http://rsync.samba.org/ftp/rsync/src/$(COMPONENT_ARCHIVE)
-TPNO= 21574
+TPNO= 28346
include $(WS_MAKE_RULES)/common.mk
--- a/components/rsync/patches/15730984.patch Thu May 05 07:38:15 2016 -0700
+++ b/components/rsync/patches/15730984.patch Mon May 16 17:05:06 2016 -0700
@@ -39,15 +39,19 @@
}
/* FALLTHROUGH */
-@@ -233,7 +234,7 @@
+
+--- Originals/cleanup.c 2016-05-09 14:57:04.922251814 -0700
++++ rsync-3.1.2/cleanup.c 2016-05-09 14:58:25.902915968 -0700
+@@ -235,7 +235,7 @@
rprintf(FINFO,
"[%s] _exit_cleanup(code=%d, file=%s, line=%d): "
- "about to call exit(%d)\n",
-- who_am_i(), first_code, exit_file, exit_line, exit_code);
-+ who_am_i(), first_code, basename((char *)exit_file), exit_line, exit_code);
+ "about to call exit(%d)%s\n",
+- who_am_i(), first_code, exit_file, exit_line, exit_code,
++ who_am_i(), first_code, basename((char *)exit_file), exit_line, exit_code,
+ dry_run ? " (DRY RUN)" : "");
}
-
- /* FALLTHROUGH */
+
+ /* FALLTHROUGH */
--- rsync-3.1.0/t_stub.c.orig Tue Jun 11 18:06:53 2013
+++ rsync-3.1.0/t_stub.c Mon Mar 17 14:58:24 2014
@@ -20,6 +20,7 @@
--- a/components/rsync/patches/rsync.1.patch Thu May 05 07:38:15 2016 -0700
+++ b/components/rsync/patches/rsync.1.patch Mon May 16 17:05:06 2016 -0700
@@ -626,6 +626,17 @@
.IP
.IP "\fB\-\-append\-verify\fP"
This works just like the \fB\-\-append\fP option, but
+--- Originals/rsync.1 2016-05-16 11:43:51.047122549 -0700
++++ rsync-3.1.2/rsync.1 2016-05-16 16:45:27.881443220 -0700
+@@ -999,7 +999,7 @@
+ but does not conflict with \fB\-\-sparse\fP (since it is always extending a
+ file's length).
+ .IP
+-The use of \fB\-\-append\fP can be dangerous if you aren\(cq\&t 100% sure that the files
++The use of \fB\-\-append\fP can be dangerous if you aren't 100% sure that the files
+ that are longer have only grown by the appending of data onto the end. You
+ should thus use include/exclude/filter rules to ensure that such a transfer is
+ only affecting files that you know to be growing via appended data.
@@ -1007,21 +1011,21 @@
.IP
.IP "\fB\-d, \-\-dirs\fP"
@@ -2629,4 +2640,3 @@
+and David Bell. I've probably missed some people, my apologies if I have.
.PP
.SH "AUTHOR"
-
--- a/components/rsync/patches/rsyncd.conf.5.patch Thu May 05 07:38:15 2016 -0700
+++ b/components/rsync/patches/rsyncd.conf.5.patch Mon May 16 17:05:06 2016 -0700
@@ -125,11 +125,11 @@
if the module is not read\-only).
.IP
When this parameter is enabled, rsync will not attempt to map users and groups
-@@ -231,12 +231,12 @@
- used by these library functions (traditionally /etc/passwd and
- /etc/group, but perhaps additional dynamic libraries as well).
+@@ -222,12 +222,12 @@
+ being enabled (disabling name lookups). See below for what a chroot needs in
+ order for name lookups to succeed.
.IP
--If you copy the necessary resources into the module\(cq\&s chroot area, you
+-If you copy library resources into the module\(cq\&s chroot area, you
-should protect them through your OS\(cq\&s normal user/group or ACL settings (to
-prevent the rsync module\(cq\&s user from being able to change them), and then
-hide them from the user\(cq\&s view via \(dq\&exclude\(dq\& (see how in the discussion of
@@ -138,7 +138,7 @@
+prevent the rsync module's user from being able to change them), and then
+hide them from the user's view via "exclude" (see how in the discussion of
that parameter). At that point it will be safe to enable the mapping of users
--and groups by name using the \(dq\&numeric ids\(dq\& daemon parameter (see below).
+-and groups by name using this \(dq\&numeric ids\(dq\& daemon parameter.
+and groups by name using the "numeric ids" daemon parameter (see below).
.IP
Note also that you are free to setup custom user/group information in the
@@ -798,3 +798,41 @@
.PP
.nf
&include /path/rsyncd.d
+--- Originals/rsyncd.conf.5 2016-05-12 14:15:47.486937445 -0700
++++ rsync-3.1.2/rsyncd.conf.5 2016-05-12 14:24:16.445410448 -0700
+@@ -85,7 +85,7 @@
+ .PP
+ The first parameters in the file (before a [module] header) are the
+ global parameters.
+-Rsync also allows for the use of a \(dq\&[global]\(dq\& module name to indicate the
++Rsync also allows for the use of a "global" module name to indicate the
+ start of one or more global\-parameter sections (the name must be lower case).
+ .PP
+ You may also include any module parameters in the global part of the
+@@ -155,7 +155,7 @@
+ name contains whitespace, each internal sequence of whitespace will be
+ changed into a single space, while leading or trailing whitespace will be
+ discarded.
+-Also, the name cannot be \(dq\&global\(dq\& as that exact name indicates that
++Also, the name cannot be "global" as that exact name indicates that
+ global parameters follow (see above).
+ .PP
+ As with GLOBAL PARAMETERS, you may use references to environment variables in
+@@ -218,7 +218,7 @@
+ The default for "use chroot" is true, and is the safer choice (especially
+ if the module is not read\-only).
+ .IP
+-When this parameter is enabled, the \(dq\&numeric\-ids\(dq\& option will also default to
++When this parameter is enabled, the "numeric ids" option will also default to
+ being enabled (disabling name lookups). See below for what a chroot needs in
+ order for name lookups to succeed.
+ .IP
+@@ -241,7 +241,7 @@
+ the \fB\-\-numeric\-ids\fP command\-line option. By default, this parameter is
+ enabled for chroot modules and disabled for non\-chroot modules.
+ Also keep in mind that uid/gid preservation requires the module to be
+-running as root (see \(dq\&uid\(dq\&) or for \(dq\&fake super\(dq\& to be configured.
++running as root (see "uid") or for "fake super" to be configured.
+ .IP
+ A chroot\-enabled module should not have this parameter enabled unless you've
+ taken steps to ensure that the module has the necessary resources it needs
--- a/components/rsync/patches/z21762187.patch Thu May 05 07:38:15 2016 -0700
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,101 +0,0 @@
-Fix for CVE-2014-9512 from upstream at https://rsync.samba.org
-
---- rsync-3.1.1/flist.c.old 2015-09-04 14:58:04.610748249 -0700
-+++ rsync-3.1.1/flist.c 2015-09-04 15:02:22.838695225 -0700
-@@ -2435,8 +2435,9 @@
- return flist;
- }
-
--struct file_list *recv_file_list(int f)
-+struct file_list *recv_file_list(int f, int dir_ndx)
- {
-+ const char *good_dirname = NULL;
- struct file_list *flist;
- int dstart, flags;
- int64 start_read;
-@@ -2491,6 +2492,23 @@
-
- flist_expand(flist, 1);
- file = recv_file_entry(f, flist, flags);
-+ if (inc_recurse) {
-+ static const char empty_dir[] = "\0";
-+ const char *cur_dir = file->dirname ? file->dirname : empty_dir;
-+ if (relative_paths && *cur_dir == '/')
-+ cur_dir++;
-+ if (cur_dir != good_dirname) {
-+ const char *d = dir_ndx >= 0 ? f_name(dir_flist->files[dir_ndx], NULL) : empty_dir;
-+ if (strcmp(cur_dir, d) != 0) {
-+ rprintf(FERROR,
-+ "ABORTING due to invalid dir prefix from sender: %s (should be: %s)\n",
-+ cur_dir, d);
-+ exit_cleanup(RERR_PROTOCOL);
-+ }
-+ good_dirname = cur_dir;
-+ }
-+ }
-+
-
- if (S_ISREG(file->mode)) {
- /* Already counted */
-@@ -2615,7 +2633,7 @@
- rprintf(FINFO, "[%s] receiving flist for dir %d\n",
- who_am_i(), ndx);
- }
-- flist = recv_file_list(f);
-+ flist = recv_file_list(f, ndx);
- flist->parent_ndx = ndx;
- }
- }
---- rsync-3.1.1/io.c.old 2015-09-04 14:58:15.706192874 -0700
-+++ rsync-3.1.1/io.c 2015-09-04 15:05:23.471180002 -0700
-@@ -1685,7 +1685,7 @@
- rprintf(FINFO, "[%s] receiving flist for dir %d\n",
- who_am_i(), ndx);
- }
-- flist = recv_file_list(iobuf.in_fd);
-+ flist = recv_file_list(iobuf.in_fd, ndx);
- flist->parent_ndx = ndx;
- #ifdef SUPPORT_HARD_LINKS
- if (preserve_hard_links)
---- rsync-3.1.1/main.c.old 2015-09-04 14:58:24.905761717 -0700
-+++ rsync-3.1.1/main.c 2015-09-04 15:07:00.835145092 -0700
-@@ -1010,7 +1010,7 @@
- filesfrom_fd = -1;
- }
-
-- flist = recv_file_list(f_in);
-+ flist = recv_file_list(f_in, -1);
- if (!flist) {
- rprintf(FERROR,"server_recv: recv_file_list error\n");
- exit_cleanup(RERR_FILESELECT);
-@@ -1184,7 +1184,7 @@
-
- if (write_batch && !am_server)
- start_write_batch(f_in);
-- flist = recv_file_list(f_in);
-+ flist = recv_file_list(f_in, -1);
- if (inc_recurse && file_total == 1)
- recv_additional_file_list(f_in);
-
---- rsync-3.1.1/rsync.c.old 2015-09-04 14:58:51.928552530 -0700
-+++ rsync-3.1.1/rsync.c 2015-09-04 15:07:59.696578389 -0700
-@@ -364,7 +364,7 @@
- }
- /* Send all the data we read for this flist to the generator. */
- start_flist_forward(ndx);
-- flist = recv_file_list(f_in);
-+ flist = recv_file_list(f_in, ndx);
- flist->parent_ndx = ndx;
- stop_flist_forward();
- }
---- rsync-3.1.1/proto.h.old 2015-09-04 17:46:09.133140046 -0700
-+++ rsync-3.1.1/proto.h 2015-09-04 17:45:12.510951663 -0700
-@@ -89,7 +89,7 @@
- void unmake_file(struct file_struct *file);
- void send_extra_file_list(int f, int at_least);
- struct file_list *send_file_list(int f, int argc, char *argv[]);
--struct file_list *recv_file_list(int f);
-+struct file_list *recv_file_list(int f, int dir_ndx);
- void recv_additional_file_list(int f);
- int flist_find(struct file_list *flist, struct file_struct *f);
- int flist_find_ignore_dirness(struct file_list *flist, struct file_struct *f);