Browse code

Update curl to version 7.56.1 and update sysdig to version 0.19.1

Change-Id: Ia781986de97a1d6f4e153833ca4f237ecda71af0
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/4518
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Anish Swaminathan <anishs@vmware.com>

xiaolin-vmware authored on 2017/12/14 14:40:54
Showing 7 changed files
1 1
deleted file mode 100644
... ...
@@ -1,36 +0,0 @@
1
-From c9332fa5e84f24da300b42b1a931ade929d3e27d Mon Sep 17 00:00:00 2001
2
-From: Even Rouault <even.rouault@spatialys.com>
3
-Date: Tue, 1 Aug 2017 17:17:06 +0200
4
-Subject: [PATCH] file: output the correct buffer to the user
5
-
6
-Regression brought by 7c312f84ea930d8 (April 2017)
7
-
8
-CVE-2017-1000099
9
-
10
-Bug: https://curl.haxx.se/docs/adv_20170809C.html
11
-
12
-Credit to OSS-Fuzz for the discovery
13
- lib/file.c | 2 +-
14
- 1 file changed, 1 insertion(+), 1 deletion(-)
15
-
16
-diff --git a/lib/file.c b/lib/file.c
17
-index bd426eac2..666cbe75b 100644
18
-+++ b/lib/file.c
19
-@@ -499,11 +499,11 @@ static CURLcode file_do(struct connectdata *conn, bool *done)
20
-              Curl_month[tm->tm_mon],
21
-              tm->tm_year + 1900,
22
-              tm->tm_hour,
23
-              tm->tm_min,
24
-              tm->tm_sec);
25
--    result = Curl_client_write(conn, CLIENTWRITE_BOTH, buf, 0);
26
-+    result = Curl_client_write(conn, CLIENTWRITE_BOTH, header, 0);
27
-     if(!result)
28
-       /* set the file size to make it available post transfer */
29
-       Curl_pgrsSetDownloadSize(data, expected_size);
30
-     return result;
31
-   }
32
-2.13.3
33
-
34 1
deleted file mode 100644
... ...
@@ -1,54 +0,0 @@
1
-From 358b2b131ad6c095696f20dcfa62b8305263f898 Mon Sep 17 00:00:00 2001
2
-From: Daniel Stenberg <daniel@haxx.se>
3
-Date: Tue, 1 Aug 2017 17:16:46 +0200
4
-Subject: [PATCH] tftp: reject file name lengths that don't fit
5
-
6
-... and thereby avoid telling send() to send off more bytes than the
7
-size of the buffer!
8
-
9
-CVE-2017-1000100
10
-
11
-Bug: https://curl.haxx.se/docs/adv_20170809B.html
12
-Reported-by: Even Rouault
13
-
14
-Credit to OSS-Fuzz for the discovery
15
- lib/tftp.c | 7 ++++++-
16
- 1 file changed, 6 insertions(+), 1 deletion(-)
17
-
18
-diff --git a/lib/tftp.c b/lib/tftp.c
19
-index 02bd84242..f6f4bce5b 100644
20
-+++ b/lib/tftp.c
21
-@@ -3,11 +3,11 @@
22
-  *  Project                     ___| | | |  _ \| |
23
-  *                             / __| | | | |_) | |
24
-  *                            | (__| |_| |  _ <| |___
25
-  *                             \___|\___/|_| \_\_____|
26
-  *
27
-- * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al.
28
-+ * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
29
-  *
30
-  * This software is licensed as described in the file COPYING, which
31
-  * you should have received as part of this distribution. The terms
32
-  * are also available at https://curl.haxx.se/docs/copyright.html.
33
-  *
34
-@@ -489,10 +489,15 @@ static CURLcode tftp_send_first(tftp_state_data_t *state, tftp_event_t event)
35
-     result = Curl_urldecode(data, &state->conn->data->state.path[1], 0,
36
-                             &filename, NULL, FALSE);
37
-     if(result)
38
-       return result;
39
- 
40
-+    if(strlen(filename) > (state->blksize - strlen(mode) - 4)) {
41
-+      failf(data, "TFTP file name too long\n");
42
-+      return CURLE_TFTP_ILLEGAL; /* too long file name field */
43
-+    }
44
-+
45
-     snprintf((char *)state->spacket.data+2,
46
-              state->blksize,
47
-              "%s%c%s%c", filename, '\0',  mode, '\0');
48
-     sbytes = 4 + strlen(filename) + strlen(mode);
49
- 
50
-2.13.3
51
-
52 1
deleted file mode 100644
... ...
@@ -1,96 +0,0 @@
1
-From 453e7a7a03a2cec749abd3878a48e728c515cca7 Mon Sep 17 00:00:00 2001
2
-From: Daniel Stenberg <daniel@haxx.se>
3
-Date: Tue, 1 Aug 2017 17:16:07 +0200
4
-Subject: [PATCH] glob: do not continue parsing after a strtoul() overflow
5
- range
6
-
7
-Added test 1289 to verify.
8
-
9
-CVE-2017-1000101
10
-
11
-Bug: https://curl.haxx.se/docs/adv_20170809A.html
12
-Reported-by: Brian Carpenter
13
- src/tool_urlglob.c      |  5 ++++-
14
- tests/data/Makefile.inc |  2 +-
15
- tests/data/test1289     | 35 +++++++++++++++++++++++++++++++++++
16
- 3 files changed, 40 insertions(+), 2 deletions(-)
17
- create mode 100644 tests/data/test1289
18
-
19
-diff --git a/src/tool_urlglob.c b/src/tool_urlglob.c
20
-index 6b1ece008..d56dcd912 100644
21
-+++ b/src/tool_urlglob.c
22
-@@ -271,11 +271,14 @@ static CURLcode glob_range(URLGlob *glob, char **patternp,
23
-           endp = NULL;
24
-           goto fail;
25
-         }
26
-         errno = 0;
27
-         max_n = strtoul(pattern, &endp, 10);
28
--        if(errno || (*endp == ':')) {
29
-+        if(errno)
30
-+          /* overflow */
31
-+          endp = NULL;
32
-+        else if(*endp == ':') {
33
-           pattern = endp+1;
34
-           errno = 0;
35
-           step_n = strtoul(pattern, &endp, 10);
36
-           if(errno)
37
-             /* over/underflow situation */
38
-diff --git a/tests/data/Makefile.inc b/tests/data/Makefile.inc
39
-index 35446cf71..59f692e8f 100644
40
-+++ b/tests/data/Makefile.inc
41
-@@ -132,7 +132,7 @@ test1252 test1253 test1254 test1255 test1256 test1257 test1258 test1259 \
42
- test1260 test1261 test1262 \
43
- \
44
- test1280 test1281 test1282 test1283 test1284 test1285 test1286 test1287 \
45
--test1288 \
46
-+test1288 test1289 \
47
- \
48
- test1300 test1301 test1302 test1303 test1304 test1305 test1306 test1307 \
49
- test1308 test1309 test1310 test1311 test1312 test1313 test1314 test1315 \
50
-diff --git a/tests/data/test1289 b/tests/data/test1289
51
-new file mode 100644
52
-index 000000000..d679cc0bc
53
-+++ b/tests/data/test1289
54
-@@ -0,0 +1,35 @@
55
-+<testcase>
56
-+<info>
57
-+<keywords>
58
-+HTTP
59
-+HTTP GET
60
-+globbing
61
-+</keywords>
62
-+</info>
63
-+
64
-+#
65
-+# Server-side
66
-+<reply>
67
-+</reply>
68
-+
69
-+# Client-side
70
-+<client>
71
-+<server>
72
-+http
73
-+</server>
74
-+<name>
75
-+globbing with overflow and bad syntxx
76
-+</name>
77
-+<command>
78
-+http://ur%20[0-60000000000000000000
79
-+</command>
80
-+</client>
81
-+
82
-+# Verify data after the test has been "shot"
83
-+<verify>
84
-+# curl: (3) [globbing] bad range in column 
85
-+<errorcode>
86
-+3
87
-+</errorcode>
88
-+</verify>
89
-+</testcase>
90
-2.13.3
91
-
92 1
deleted file mode 100644
... ...
@@ -1,133 +0,0 @@
1
-From 9d9157bb0c230c769fdf902ed3a62edf642d424b Mon Sep 17 00:00:00 2001
2
-From: Daniel Stenberg <daniel@haxx.se>
3
-Date: Mon, 25 Sep 2017 00:35:22 +0200
4
-Subject: [PATCH v2] FTP: zero terminate the entry path even on bad input
5
-
6
-... a single double quote could leave the entry path buffer without a zero
7
-terminating byte.
8
-
9
-Test 1152 added to verify.
10
-
11
-Reported-by: Max Dymond
12
- lib/ftp.c               |  7 ++++--
13
- tests/data/Makefile.inc |  1 +
14
- tests/data/test1152     | 61 +++++++++++++++++++++++++++++++++++++++++++++++++
15
- 3 files changed, 67 insertions(+), 2 deletions(-)
16
- create mode 100644 tests/data/test1152
17
-
18
-diff --git a/lib/ftp.c b/lib/ftp.c
19
-index 4860509f3..54ba4057f 100644
20
-+++ b/lib/ftp.c
21
-@@ -2826,7 +2826,7 @@ static CURLcode ftp_statemach_act(struct connectdata *conn)
22
-         const size_t buf_size = data->set.buffer_size;
23
-         char *dir;
24
-         char *store;
25
--
26
-+        bool entry_extracted = FALSE;
27
-         dir = malloc(nread + 1);
28
-         if(!dir)
29
-           return CURLE_OUT_OF_MEMORY;
30
-@@ -2857,7 +2857,7 @@ static CURLcode ftp_statemach_act(struct connectdata *conn)
31
-               }
32
-               else {
33
-                 /* end of path */
34
--                *store = '\0'; /* zero terminate */
35
-+                entry_extracted = TRUE;
36
-                 break; /* get out of this loop */
37
-               }
38
-             }
39
-@@ -2866,7 +2866,9 @@ static CURLcode ftp_statemach_act(struct connectdata *conn)
40
-             store++;
41
-             ptr++;
42
-           }
43
--
44
-+          *store = '\0'; /* zero terminate */
45
-+        }
46
-+        if(entry_extracted) {
47
-           /* If the path name does not look like an absolute path (i.e.: it
48
-              does not start with a '/'), we probably need some server-dependent
49
-              adjustments. For example, this is the case when connecting to
50
-diff --git a/tests/data/Makefile.inc b/tests/data/Makefile.inc
51
-index 1bfd75eca..268f5e29e 100644
52
-+++ b/tests/data/Makefile.inc
53
-@@ -121,6 +121,7 @@ test1120 test1121 test1122 test1123 test1124 test1125 test1126 test1127 \
54
- test1128 test1129 test1130 test1131 test1132 test1133 test1134 test1135 \
55
- test1136 test1137 test1138 test1139 test1140 test1141 test1142 test1143 \
56
- test1144 test1145 test1146 \
57
-+test1152 \
58
- test1200 test1201 test1202 test1203 test1204 test1205 test1206 test1207 \
59
- test1208 test1209 test1210 test1211 test1212 test1213 test1214 test1215 \
60
- test1216 test1217 test1218 test1219 \
61
-diff --git a/tests/data/test1152 b/tests/data/test1152
62
-new file mode 100644
63
-index 000000000..aa8c0a7e4
64
-+++ b/tests/data/test1152
65
-@@ -0,0 +1,61 @@
66
-+<testcase>
67
-+<info>
68
-+<keywords>
69
-+FTP
70
-+PASV
71
-+LIST
72
-+</keywords>
73
-+</info>
74
-+#
75
-+# Server-side
76
-+<reply>
77
-+<servercmd>
78
-+REPLY PWD 257 "just one
79
-+</servercmd>
80
-+
81
-+# When doing LIST, we get the default list output hard-coded in the test
82
-+# FTP server
83
-+<data mode="text">
84
-+total 20
85
-+drwxr-xr-x   8 98       98           512 Oct 22 13:06 .
86
-+drwxr-xr-x   8 98       98           512 Oct 22 13:06 ..
87
-+drwxr-xr-x   2 98       98           512 May  2  1996 curl-releases
88
-+-r--r--r--   1 0        1             35 Jul 16  1996 README
89
-+lrwxrwxrwx   1 0        1              7 Dec  9  1999 bin -> usr/bin
90
-+dr-xr-xr-x   2 0        1            512 Oct  1  1997 dev
91
-+drwxrwxrwx   2 98       98           512 May 29 16:04 download.html
92
-+dr-xr-xr-x   2 0        1            512 Nov 30  1995 etc
93
-+drwxrwxrwx   2 98       1            512 Oct 30 14:33 pub
94
-+dr-xr-xr-x   5 0        1            512 Oct  1  1997 usr
95
-+</data>
96
-+</reply>
97
-+
98
-+#
99
-+# Client-side
100
-+<client>
101
-+<server>
102
-+ftp
103
-+</server>
104
-+ <name>
105
-+FTP with uneven quote in PWD response
106
-+ </name>
107
-+ <command>
108
-+ftp://%HOSTIP:%FTPPORT/test-1152/
109
-+</command>
110
-+</client>
111
-+
112
-+#
113
-+# Verify data after the test has been "shot"
114
-+<verify>
115
-+<protocol>
116
-+USER anonymous
117
-+PASS ftp@example.com
118
-+PWD
119
-+CWD test-1152
120
-+EPSV
121
-+TYPE A
122
-+LIST
123
-+QUIT
124
-+</protocol>
125
-+</verify>
126
-+</testcase>
127
-2.14.1
128
-
129 1
deleted file mode 100644
... ...
@@ -1,37 +0,0 @@
1
-From 13c9a9ded3ae744a1e11cbc14e9146d9fa427040 Mon Sep 17 00:00:00 2001
2
-From: Daniel Stenberg <daniel@haxx.se>
3
-Date: Sat, 7 Oct 2017 00:11:31 +0200
4
-Subject: [PATCH] imap: if a FETCH response has no size, don't call write
5
- callback
6
-
7
-CVE-2017-1000257
8
-
9
-Reported-by: Brian Carpenter and 0xd34db347
10
-Also detected by OSS-Fuzz: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3586
11
- lib/imap.c | 5 +++++
12
- 1 file changed, 5 insertions(+)
13
-
14
-diff --git a/lib/imap.c b/lib/imap.c
15
-index 954d18f37..baa31a2f8 100644
16
-+++ b/lib/imap.c
17
-@@ -1124,10 +1124,15 @@ static CURLcode imap_state_fetch_resp(struct connectdata *conn, int imapcode,
18
- 
19
-       if(chunk > (size_t)size)
20
-         /* The conversion from curl_off_t to size_t is always fine here */
21
-         chunk = (size_t)size;
22
- 
23
-+      if(!chunk) {
24
-+        /* no size, we're done with the data */
25
-+        state(conn, IMAP_STOP);
26
-+        return CURLE_OK;
27
-+      }
28
-       result = Curl_client_write(conn, CLIENTWRITE_BODY, pp->cache, chunk);
29
-       if(result)
30
-         return result;
31
- 
32
-       data->req.bytecount += chunk;
33
-2.15.0.rc1
34
-
... ...
@@ -1,19 +1,14 @@
1 1
 Summary:        An URL retrieval utility and library
2 2
 Name:           curl
3
-Version:        7.54.1
4
-Release:        4%{?dist}
3
+Version:        7.56.1
4
+Release:        1%{?dist}
5 5
 License:        MIT
6 6
 URL:            http://curl.haxx.se
7 7
 Group:          System Environment/NetworkingLibraries
8 8
 Vendor:         VMware, Inc.
9 9
 Distribution:   Photon
10
-Source0:        http://curl.haxx.se/download/%{name}-%{version}.tar.lzma
11
-%define sha1    curl=5e549585a3e9746bd672f52cea2a7ea4936021ef
12
-Patch0:         curl-CVE-2017-1000099.patch
13
-Patch1:         curl-CVE-2017-1000100.patch
14
-Patch2:         curl-CVE-2017-1000101.patch
15
-Patch3:         curl-CVE-2017-1000254.patch
16
-Patch4:         curl-CVE-2017-1000257.patch
10
+Source0:        http://curl.haxx.se/download/%{name}-%{version}.tar.xz
11
+%define sha1    curl=c26bd88fdd5fe5d31a3b9e7a0a6b3dffff3168df
17 12
 BuildRequires:  ca-certificates
18 13
 BuildRequires:  openssl-devel
19 14
 BuildRequires:  krb5-devel
... ...
@@ -46,11 +41,6 @@ This package contains minimal set of shared curl libraries.
46 46
 
47 47
 %prep
48 48
 %setup -q
49
-%patch0 -p1
50
-%patch1 -p1
51
-%patch2 -p1
52
-%patch3 -p1
53
-%patch4 -p1
54 49
 %build
55 50
 ./configure \
56 51
     CFLAGS="%{optflags}" \
... ...
@@ -98,6 +88,8 @@ rm -rf %{buildroot}/*
98 98
 %{_libdir}/libcurl.so.*
99 99
 
100 100
 %changelog
101
+*   Wed Dec 13 2017 Xiaolin Li <xiaolinl@vmware.com> 7.56.1-1
102
+-   Update to version 7.56.1
101 103
 *   Mon Nov 27 2017 Xiaolin Li <xiaolinl@vmware.com> 7.54.1-4
102 104
 -   Fix CVE-2017-1000257
103 105
 *   Mon Nov 06 2017 Xiaolin Li <xiaolinl@vmware.com> 7.54.1-3
... ...
@@ -1,7 +1,7 @@
1 1
 %global security_hardening none
2 2
 Summary:        Sysdig is a universal system visibility tool with native support for containers.
3 3
 Name:           sysdig
4
-Version:        0.15.1
4
+Version:        0.19.1
5 5
 Release:        1%{?kernelsubrelease}%{?dist}
6 6
 License:        GPLv2
7 7
 URL:            http://www.sysdig.org/
... ...
@@ -9,7 +9,7 @@ Group:          Applications/System
9 9
 Vendor:         VMware, Inc.
10 10
 Distribution:   Photon
11 11
 Source0:        https://github.com/draios/sysdig/archive/%{name}-%{version}.tar.gz
12
-%define sha1    sysdig=5b1a7a4978315176412989b5400572d849691917
12
+%define sha1    sysdig=425ea9fab8e831274626a9c9e65f0dfb4f9bc019
13 13
 BuildRequires:  cmake 
14 14
 BuildRequires:  linux-devel = %{KERNEL_VERSION}-%{KERNEL_RELEASE}
15 15
 BuildRequires:  openssl-devel
... ...
@@ -74,6 +74,8 @@ rm -rf %{buildroot}/*
74 74
 /lib/modules/%{KERNEL_VERSION}-%{KERNEL_RELEASE}/extra/sysdig-probe.ko
75 75
 
76 76
 %changelog
77
+*   Wed Dec 13 2017 Xiaolin Li <xiaolinl@vmware.com> 0.19.1-1
78
+-   Update to version 0.19.1
77 79
 *   Wed Apr 12 2017 Vinay Kulkarni <kulkarniv@vmware.com> 0.15.1-1
78 80
 -   Update to version 0.15.1
79 81
 *   Wed Jan 11 2017 Alexey Makhalov <amakhalov@vmware.com> 0.10.1-6