Change-Id: Ic9c8e6196249cd3bd9272b64d83ece753e0b6271
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/4403
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Xiaolin Li <xiaolinl@vmware.com>
| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,28 @@ |
| 0 |
+From 47a63d90e71d3e19e0e96052bb8c6b9cb140ecc1 Mon Sep 17 00:00:00 2001 |
|
| 1 |
+From: Wayne Davison <wayned@samba.org> |
|
| 2 |
+Date: Sun, 5 Nov 2017 11:33:15 -0800 |
|
| 3 |
+Subject: [PATCH] Enforce trailing \0 when receiving xattr name values. Fixes |
|
| 4 |
+ bug 13112. |
|
| 5 |
+ |
|
| 6 |
+--- |
|
| 7 |
+ xattrs.c | 4 ++++ |
|
| 8 |
+ 1 file changed, 4 insertions(+) |
|
| 9 |
+ |
|
| 10 |
+diff --git a/xattrs.c b/xattrs.c |
|
| 11 |
+index 68305d7..4867e6f 100644 |
|
| 12 |
+--- a/xattrs.c |
|
| 13 |
+@@ -824,6 +824,10 @@ void receive_xattr(int f, struct file_struct *file) |
|
| 14 |
+ out_of_memory("receive_xattr");
|
|
| 15 |
+ name = ptr + dget_len + extra_len; |
|
| 16 |
+ read_buf(f, name, name_len); |
|
| 17 |
++ if (name_len < 1 || name[name_len-1] != '\0') {
|
|
| 18 |
++ rprintf(FERROR, "Invalid xattr name received (missing trailing \\0).\n"); |
|
| 19 |
++ exit_cleanup(RERR_FILEIO); |
|
| 20 |
++ } |
|
| 21 |
+ if (dget_len == datum_len) |
|
| 22 |
+ read_buf(f, ptr, dget_len); |
|
| 23 |
+ else {
|
|
| 24 |
+-- |
|
| 25 |
+1.9.1 |
|
| 26 |
+ |
| ... | ... |
@@ -1,20 +1,22 @@ |
| 1 |
-Summary: Fast incremental file transfer. |
|
| 2 |
-Name: rsync |
|
| 3 |
-Version: 3.1.2 |
|
| 4 |
-Release: 3%{?dist}
|
|
| 5 |
-License: GPLv3+ |
|
| 6 |
-URL: https://rsync.samba.org/ |
|
| 7 |
-Source0: https://download.samba.org/pub/rsync/src/%{name}-%{version}.tar.gz
|
|
| 8 |
-%define sha1 rsync=0d4c7fb7fe3fc80eeff922a7c1d81df11dbb8a1a |
|
| 9 |
-Group: Appication/Internet |
|
| 10 |
-Vendor: VMware, Inc. |
|
| 11 |
-Distribution: Photon |
|
| 12 |
-BuildRequires: systemd |
|
| 13 |
-Requires: systemd |
|
| 1 |
+Summary: Fast incremental file transfer. |
|
| 2 |
+Name: rsync |
|
| 3 |
+Version: 3.1.2 |
|
| 4 |
+Release: 4%{?dist}
|
|
| 5 |
+License: GPLv3+ |
|
| 6 |
+URL: https://rsync.samba.org/ |
|
| 7 |
+Source0: https://download.samba.org/pub/rsync/src/%{name}-%{version}.tar.gz
|
|
| 8 |
+%define sha1 rsync=0d4c7fb7fe3fc80eeff922a7c1d81df11dbb8a1a |
|
| 9 |
+Patch0: rsync-CVE-2017-16548.patch |
|
| 10 |
+Group: Appication/Internet |
|
| 11 |
+Vendor: VMware, Inc. |
|
| 12 |
+Distribution: Photon |
|
| 13 |
+BuildRequires: systemd |
|
| 14 |
+Requires: systemd |
|
| 14 | 15 |
%description |
| 15 | 16 |
Rsync is a fast and extraordinarily versatile file copying tool. It can copy locally, to/from another host over any remote shell, or to/from a remote rsync daemon. It offers a large number of options that control every aspect of its behavior and permit very flexible specification of the set of files to be copied. It is famous for its delta-transfer algorithm, which reduces the amount of data sent over the network by sending only the differences between the source files and the existing files in the destination. Rsync is widely used for backups and mirroring and as an improved copy command for everyday use. |
| 16 | 17 |
%prep |
| 17 | 18 |
%setup -q |
| 19 |
+%patch0 -p1 |
|
| 18 | 20 |
%build |
| 19 | 21 |
%configure --prefix=/usr |
| 20 | 22 |
make %{?_smp_mflags}
|
| ... | ... |
@@ -43,7 +45,7 @@ make %{?_smp_mflags} check
|
| 43 | 43 |
|
| 44 | 44 |
%post |
| 45 | 45 |
/sbin/ldconfig |
| 46 |
-%postun -p /sbin/ldconfig |
|
| 46 |
+%postun -p /sbin/ldconfig |
|
| 47 | 47 |
%files |
| 48 | 48 |
%defattr(-,root,root) |
| 49 | 49 |
%exclude %{_libdir}/debug
|
| ... | ... |
@@ -54,12 +56,14 @@ make %{?_smp_mflags} check
|
| 54 | 54 |
%{_libdir}/systemd/system/rsyncd.service
|
| 55 | 55 |
%{_sysconfdir}/rsyncd.conf
|
| 56 | 56 |
%changelog |
| 57 |
-* Wed Oct 05 2016 ChangLee <changlee@vmware.com> 3.1.2-3 |
|
| 58 |
-- Modified %check |
|
| 59 |
-* Tue May 24 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 3.1.2-2 |
|
| 60 |
-- GA - Bump release of all rpms |
|
| 57 |
+* Wed Nov 29 2017 Xiaolin Li <xiaolinl@vmware.com> 3.1.2-4 |
|
| 58 |
+- Fix CVE-2017-16548 |
|
| 59 |
+* Wed Oct 05 2016 ChangLee <changlee@vmware.com> 3.1.2-3 |
|
| 60 |
+- Modified %check |
|
| 61 |
+* Tue May 24 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 3.1.2-2 |
|
| 62 |
+- GA - Bump release of all rpms |
|
| 61 | 63 |
* Thu Jan 21 2016 Xiaolin Li <xiaolinl@vmware.com> 3.1.2-1 |
| 62 | 64 |
- Updated to version 3.1.2 |
| 63 |
-* Mon Dec 14 2015 Xiaolin Li < xiaolinl@vmware.com> 3.1.1-1 |
|
| 64 |
-- Initial build. First version |
|
| 65 |
+* Mon Dec 14 2015 Xiaolin Li < xiaolinl@vmware.com> 3.1.1-1 |
|
| 66 |
+- Initial build. First version |
|
| 65 | 67 |
|