git: libc - Disallow an excessively large pattern space

Matthew Dillon dillon at crater.dragonflybsd.org
Fri Feb 6 22:19:58 PST 2015


commit 2841837793bd095a82f477e9c370cfe6cfb3862c
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Fri Feb 6 22:16:40 2015 -0800

    libc - Disallow an excessively large pattern space
    
    * Disallow pattern spaces which would cause intermediate calculations
      to overflow size_t.
    
    * Since the pattern length must be in the hundreds of megabytes to trigger
      the issue on a 32-bit machine (and something insane on a 64-bit machine),
      it is unlikely that any software is at risk.  But still a good idea to
      deal with the case.
    
    CERT: VU#695940

Summary of changes:
 lib/libc/regex/regcomp.c | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/2841837793bd095a82f477e9c370cfe6cfb3862c


-- 
DragonFly BSD source repository


More information about the Commits mailing list