Ben Hutchings
6b17faf3d5
pipe: iovec: Fix memory corruption when retrying atomic copy as non-atomic
...
pipe_iov_copy_{from,to}_user() may be tried twice with the same iovec,
the first time atomically and the second time not. The second attempt
needs to continue from the iovec position, pipe buffer offset and
remaining length where the first attempt failed, but currently the
pipe buffer offset and remaining length are reset. This will corrupt
the piped data (possibly also leading to an information leak between
processes) and may also corrupt kernel memory.
This was fixed upstream by commits f0d1bec9d5 ("new helper:
copy_page_from_iter()") and 637b58c288 ("switch pipe_read() to
copy_page_to_iter()"), but those aren't suitable for stable. This fix
for older kernel versions was made by Seth Jennings for RHEL and I
have extracted it from their update.
CVE-2015-1805
References: https://bugzilla.redhat.com/show_bug.cgi?id=1202855
Signed-off-by: Ben Hutchings <ben@decadent.org.uk >
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org >
2015-06-29 12:25:37 -07:00
..
2014-01-28 08:38:04 -08:00
2013-10-24 23:43:27 -04:00
2015-04-29 10:31:54 +02:00
2014-02-01 10:59:39 -08:00
2015-04-29 10:31:54 +02:00
2014-01-25 03:14:38 -05:00
2013-09-12 15:38:02 -07:00
2015-06-22 17:01:24 -07:00
2013-11-13 15:34:18 +09:00
2015-04-29 10:31:54 +02:00
2015-04-29 10:31:54 +02:00
2015-04-29 10:31:54 +02:00
2013-11-21 16:42:27 -08:00
2014-11-21 09:23:06 -08:00
2015-04-29 10:31:54 +02:00
2013-11-13 12:09:36 +09:00
2014-01-25 11:17:34 -08:00
2015-01-08 10:00:51 -08:00
2013-11-15 22:04:17 -05:00
2014-01-25 03:13:02 -05:00
2014-01-23 18:54:14 +02:00
2015-04-29 10:31:54 +02:00
2014-01-25 23:58:19 -05:00
2014-11-14 09:00:09 -08:00
2015-06-06 08:19:36 -07:00
2015-01-29 17:40:52 -08:00
2013-10-24 23:43:28 -04:00
2013-06-29 12:56:53 +04:00
2014-02-17 13:47:35 -08:00
2015-03-26 15:06:53 +01:00
2015-01-29 17:40:52 -08:00
2013-11-13 12:09:32 +09:00
2015-04-13 14:03:03 +02:00
2014-01-26 11:51:09 +01:00
2014-02-02 16:24:07 -08:00
2013-07-03 16:07:41 -07:00
2014-10-09 12:21:27 -07:00
2015-01-08 10:00:49 -08:00
2013-12-04 12:27:46 +01:00
2015-06-06 08:19:36 -07:00
2015-03-06 14:43:32 -08:00
2014-02-13 15:56:05 -06:00
2014-06-07 10:28:08 -07:00
2015-01-27 08:18:58 -08:00
2014-01-30 11:19:05 -08:00
2013-09-16 18:20:25 -07:00
2015-04-29 10:31:54 +02:00
2015-04-29 10:31:54 +02:00
2013-02-13 06:15:14 -08:00
2015-01-16 06:59:33 -08:00
2015-05-17 09:53:49 -07:00
2014-01-25 03:14:05 -05:00
2015-04-29 10:31:54 +02:00
2015-01-29 17:40:52 -08:00
2015-05-17 09:53:49 -07:00
2015-06-06 08:19:31 -07:00
2013-06-29 12:56:32 +04:00
2015-04-29 10:31:56 +02:00
2015-02-05 22:35:52 -08:00
2014-01-25 03:13:03 -05:00
2013-06-29 12:56:39 +04:00
2014-11-14 09:00:09 -08:00
2014-01-23 16:36:58 -08:00
2014-07-06 18:57:29 -07:00
2014-01-23 16:37:04 -08:00
2013-11-24 01:02:50 +00:00
2014-06-07 10:28:24 -07:00
2013-09-29 22:02:02 -04:00
2014-11-14 08:59:46 -08:00
2015-01-08 10:00:50 -08:00
2013-09-12 15:38:02 -07:00
2015-03-06 14:43:31 -08:00
2015-04-19 10:11:09 +02:00
2014-03-27 09:52:54 -07:00
2014-06-16 13:40:32 -07:00
2013-06-29 12:57:04 +04:00
2013-11-09 00:16:26 -05:00
2013-11-09 00:16:30 -05:00
2015-06-06 08:19:40 -07:00
2013-10-24 23:34:54 -04:00
2013-04-29 15:40:23 -04:00
2013-04-30 17:04:03 -07:00
2012-12-20 17:40:19 -08:00
2014-02-21 15:56:36 -08:00
2014-02-11 08:40:45 -07:00
2013-09-13 23:06:40 -04:00
2015-01-29 17:40:52 -08:00
2013-11-14 12:08:14 +09:00
2014-01-21 16:19:42 -08:00
2013-06-29 12:57:05 +04:00
2014-07-31 12:52:56 -07:00
2015-06-06 08:19:32 -07:00
2014-01-29 16:22:40 -08:00
2013-11-23 22:33:47 -08:00
2013-09-10 18:56:31 -04:00
2014-01-25 03:13:04 -05:00
2014-10-05 14:52:20 -07:00
2015-05-06 21:59:21 +02:00
2013-10-24 23:34:54 -04:00
2015-06-06 08:19:40 -07:00
2014-05-31 13:20:29 -07:00
2014-03-23 00:03:12 -04:00
2013-03-03 19:36:31 -08:00
2013-11-06 12:40:26 +01:00
2015-01-16 06:59:32 -08:00
2014-06-16 13:40:32 -07:00
2013-11-09 00:16:20 -05:00
2013-10-24 23:34:54 -04:00
2014-11-21 09:23:03 -08:00
2014-01-26 08:26:40 -05:00
2013-04-30 17:04:04 -07:00
2015-04-29 10:31:54 +02:00
2014-12-06 15:55:39 -08:00
2014-01-28 08:38:04 -08:00
2013-09-10 18:56:31 -04:00
2014-03-30 19:18:51 -04:00
2013-11-23 22:33:47 -08:00
2015-05-06 21:59:20 +02:00
2015-05-17 09:53:49 -07:00
2015-05-06 21:59:11 +02:00
2015-06-29 12:25:37 -07:00
2014-09-17 09:19:22 -07:00
2014-05-06 07:59:36 -07:00
2014-06-07 10:28:16 -07:00
2014-01-23 16:37:02 -08:00
2014-03-23 00:03:12 -04:00
2013-10-24 23:34:54 -04:00
2013-11-13 15:34:18 +09:00
2013-11-18 19:07:53 -08:00
2013-03-03 22:58:46 -05:00
2014-01-22 19:36:57 +01:00
2013-11-09 00:16:31 -05:00
2013-10-12 13:12:31 -07:00
2014-11-21 09:23:07 -08:00
2014-02-22 02:02:28 +01:00
2013-05-29 12:57:34 -07:00
2013-11-09 00:16:44 -05:00
2012-12-20 18:50:11 -05:00