+ Reply to Thread
Results 1 to 1 of 1

Thread: PHP floating point bug and you - You might DoS yourself from the inside out

  1. #1
    Qombat's Avatar
    Qombat is offline x10Hosting Member Qombat is an unknown quantity at this point
    Join Date
    Aug 2010
    Posts
    25

    PHP floating point bug and you - You might DoS yourself from the inside out

    Original post is located here.

    A vulnerability has been found in most 32-bit versions of PHP which causes the interpreter to hang when parsing a specific floating point number.

    As a result, any script taking user input and treating it as a number is vulnerable to a DoS attack.

    It takes next to no effort to initiate, and PHP on your machine will enter an infinite loop.

    Fixes are being worked on but for now, if you don't need to work with floating point numbers, don't.

    Vulnerable:
    Code:
    $id = (int)$_GET['x'];
    Safe:
    Code:
    $id = (int)substr($_GET['x'], 0, strpos($_GET['x'], "."));
    For reference, this is safe because it ignores everything past the decimal place.

    -For user safety, I have been asked to remove the specific floating point number, along with the cause behind the action PHP takes.-

    Trust me, if your site is public in any way shape or form, you'll thank me later.

    ---------- Post added at 10:08 AM ---------- Previous post was at 10:02 AM ----------

    Update:

    The PHP team has released two new versions as of today: PHP versions 5.3.5 and 5.2.17. These versions contain the fix for the bug. If you are unable to update, I highly recommend continuing with the fix in the original post.
    Last edited by Qombat; 01-06-2011 at 06:03 PM.
    Elliot Speck | Unofficial Technical and Systems Support
    Filemaw - Free file sharing for the masses!

+ Reply to Thread

Similar Threads

  1. Replies: 4
    Last Post: 01-07-2011, 11:21 AM
  2. What do we point our domains to, so they point to this website?
    By randall-chris76 in forum Free Hosting
    Replies: 1
    Last Post: 12-21-2010, 02:21 PM
  3. Was 9-11 an inside job?
    By allofus in forum Crossfire
    Replies: 14
    Last Post: 09-18-2009, 11:54 PM
  4. just look inside please?
    By swirly in forum Off Topic
    Replies: 2
    Last Post: 04-19-2006, 08:31 PM
  5. DIV inside a DIV
    By Conor in forum Scripts & 3rd Party Apps
    Replies: 4
    Last Post: 04-09-2005, 12:55 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers