Multiple integer overflows in GNU Grep before 2.11 might allow
context-dependent attackers to execute arbitrary code via vectors involving
a long input line that triggers a heap-based buffer overflow.
 sarnold> Upstream recommends upgrading to 2.11, but include fixes for two bugs
  introduced in 2.11, and reverting the -r change. See
  oss-security/2012/12/22/3 for details. Upgrading to latest release may also
  make sense.
 jdstrand> Reproducer for amd64 system (tested with 8G of RAM):
  perl -e 'print "x"x(2**31)' | grep x > /dev/null
 jdstrand> Ubuntu 8.04 LTS - 12.04 LTS confirmed to be affected. Each release
 jdstrand> Ubuntu 12.10+ does not segfault
 jdstrand> RedHat bug has a reduced proposed patch that simply performs
  boundary checking but it has not been commented on as of 2013/05/07
 jdstrand> This is arguably of low priority unless code-execution can be
Source: grep (LP Ubuntu Debian)
Upstream:released (2.11-1)
Ubuntu 12.04 ESM (Precise Pangolin):needed
Ubuntu 14.04 LTS (Trusty Tahr):not-affected
Ubuntu 16.04 LTS (Xenial Xerus):not-affected
Ubuntu 18.04 LTS (Bionic Beaver):not-affected
Ubuntu 18.10 (Cosmic Cuttlefish):not-affected
Ubuntu 19.04 (Disco Dingo):not-affected
More Information

Updated: 2019-01-14 21:14:43 UTC (commit 51f9b73af244ba86b9321e46e526586c25a8e060)