Full Disclosure mailing list archives
Re: {Java,PHP} Server Exploits
From: Valdis.Kletnieks () vt edu
Date: Wed, 09 Feb 2011 15:13:11 -0500
On Wed, 09 Feb 2011 20:54:41 +0100, Christian Sciberras said:
$f=floatval("2.2250738585072011e-308"); echo 'Try 2 => '.$f.'</br>';
Plus, I'm a bit amazed such a bug exists in PHP - since converting to floating point is a trivial operation, it should have been limited and safe-guarded from the start.
Take a careful gander at that number, then go look at the floating point spec - it's a specific corner case that isn't obviously trivial to get right (doing floating point *right* is a lot harder than it looks - take a class on numerical methods sometime, you spend 75% of your time dealing with rounding errors in the last bit). Having said that, anybody writing floating point support for a package should probably google 'floating point paranoia' and learn what sort of things to test for. :)
Attachment:
_bin
Description:
_______________________________________________ Full-Disclosure - We believe in it. Charter: http://lists.grok.org.uk/full-disclosure-charter.html Hosted and sponsored by Secunia - http://secunia.com/
Current thread:
- {Java,PHP} Server Exploits Leon Kaiser (Feb 09)
- Re: {Java,PHP} Server Exploits Christian Sciberras (Feb 09)
- Re: {Java,PHP} Server Exploits Christian Sciberras (Feb 09)
- Re: {Java,PHP} Server Exploits Cal Leeming [Simplicity Media Ltd] (Feb 09)
- Re: {Java,PHP} Server Exploits Valdis . Kletnieks (Feb 09)
- Re: {Java,PHP} Server Exploits Christian Sciberras (Feb 09)
- Re: {Java,PHP} Server Exploits Christian Sciberras (Feb 09)
- Re: {Java,PHP} Server Exploits DiKKy Heartiez (Feb 09)
- Re: {Java,PHP} Server Exploits Troy Aerojam (Feb 09)
- Re: {Java,PHP} Server Exploits Yorian Wiltjer (Feb 10)
- Re: {Java,PHP} Server Exploits Christian Sciberras (Feb 09)