fix for iconv_mime_decode_headers function skipping headers
commitb6f35f2f07e801f87878b0d5eb98580dd79c451b
authorMatt Clarke-Lauer <mcl@fb.com>
Tue, 18 Nov 2014 19:27:09 +0000 (18 11:27 -0800)
committerhhvm-bot <hhvm-bot@fb.com>
Fri, 19 Dec 2014 19:00:35 +0000 (19 11:00 -0800)
tree9a76e79d3e0820153295a79f968c0dd695f59e76
parentfcadafc4d44e4031e8426aa8f8b23296f7da16c0
fix for iconv_mime_decode_headers function skipping headers

Summary: A malformed mime header causes hhvm to punt on the rest of the
decode. This diff is a port of the fix for https://bugs.php.net/bug.php?id=52941
since the code is almost identical and solves the problem with embedded '=' and
'?' in mime headers.

CVE-2010-4699

Reviewed By: @JoelMarcey

Differential Revision: D1689385
hphp/runtime/ext/iconv/ext_iconv.cpp