File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / ext / standard / tests / strings / bug38322.phpt
Revision 1.1.1.2 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Mon Oct 14 08:02:41 2013 UTC (10 years, 9 months ago) by misho
Branches: php, MAIN
CVS tags: v5_4_29p0, v5_4_29, v5_4_20p0, v5_4_20, HEAD
v 5.4.20

--TEST--
Bug #38322 (reading past array in sscanf() leads to segfault/arbitrary code execution)
--FILE--
<?php

$str = "a b c d e";
var_dump(sscanf("a ",'%1$s',$str));

echo "Done\n";
?>
--EXPECTF--	
int(1)
Done

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>