Jilles Tjoelker c8a3d81f34 sh: Fix heap-based buffer overflow in pathname generation.
The buffer for generated pathnames could be too small in some cases. It
happened to be always at least PATH_MAX long, so there was never an overflow
if the resulting pathnames would be usable.

This bug may be abused if a script subjects input from an untrusted source
to pathname generation, which a bad idea anyhow. Most shell scripts do not
work on untrusted data. secteam@ says no advisory is necessary.

PR:		bin/148733
Reported by:	Changming Sun snnn119 at gmail com
MFC after:	10 days
2010-08-10 22:45:59 +00:00
..
2009-10-15 18:17:29 +00:00
2009-06-23 23:30:56 +00:00
2010-06-02 09:34:41 +00:00
2010-01-13 17:49:35 +00:00
2009-01-30 16:23:57 +00:00
2009-06-23 23:30:56 +00:00
2006-12-18 15:45:01 +00:00
2010-03-04 16:08:01 +00:00
2007-03-04 19:52:07 +00:00
2009-06-23 23:30:56 +00:00
2010-07-31 21:09:49 +00:00
2006-12-27 11:28:00 +00:00
2009-09-04 21:49:37 +00:00
2010-07-12 01:58:46 +00:00
2010-02-15 14:07:40 +00:00
2006-12-27 12:14:56 +00:00
2010-07-27 17:33:02 +00:00
2009-10-15 18:17:29 +00:00