Files
poky/meta/recipes-extended/tar/tar-1.17/avoid_heap_overflow.patch
Mariano Lopez e5c011b041 Add "CVE:" tag to current patches in OE-core
The currnet patches in OE-core doesn't have the "CVE:"
tag, now part of the policy of the patches.

This is patch add this tag to several patches. There might
be patches that I miss; the tag can be added in the future.

(From OE-Core rev: 065ebeb3e15311d0d45385e15bf557b1c95b1669)

Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-11 23:26:32 +00:00

24 lines
918 B
Diff

Upstream-Status: Inappropriate [bugfix: http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2010-0624]
CVE: CVE-2010-0624
This patch avoids heap overflow reported by :
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2010-0624
This is a clean patch for the GPLv2 tar recipe.
Nitin A Kamble <nitin.a.kamble@intel.com> 2011/04/25
Index: tar-1.17/lib/rtapelib.c
===================================================================
--- tar-1.17.orig/lib/rtapelib.c
+++ tar-1.17/lib/rtapelib.c
@@ -570,7 +570,7 @@ rmt_read__ (int handle, char *buffer, si
sprintf (command_buffer, "R%lu\n", (unsigned long) length);
if (do_command (handle, command_buffer) == -1
- || (status = get_status (handle)) == SAFE_READ_ERROR)
+ || ((status = get_status (handle)) == SAFE_READ_ERROR) || (status > length))
return SAFE_READ_ERROR;
for (counter = 0; counter < status; counter += rlen, buffer += rlen)