From:             gphemsley at users dot sourceforge dot net
Operating system: Windows XP Professional SP1
PHP version:      5.0.0RC3
PHP Bug Type:     CGI related
Bug description:  convert_uudecode() crashes CGI version

Description:
------------
convert_uudecode() crashes the CGI version of PHP 5.0.0RC3, seemingly
trying to parse its contents as PHP code.

Reproduce code:
---------------
<?php

// Temporary
$_REQUEST['file'] = 'C:\\Documents and Settings\\Gordon Hemsley\\Local
Settings\\Temp\\3nCryPt\\3nCryPt.enc';

if( isset( $_REQUEST['file'] ) )
{
        print "<pre>\n";

        foreach( file( $_REQUEST['file'] ) as $line )
        {
                print htmlentities( convert_uudecode( $line ) );
        }

        print "</pre>\n";
}

?>


Expected result:
----------------
A decoded version of the file that I provided it.

Actual result:
--------------
It spits out these lines and then dies (causing the Windows Error
Reporting window to pop up):
PHP Notice:  Undefined variable:  /a&#9792;&#9578;&#8597;* in D:\Program
Files\Apache Group\Apache
\htdocs\uudecode.php5 on line 13
PHP Notice:  Undefined variable:  /a&#9792;&#9578;&#8597;* in D:\Program
Files\Apache Group\Apache
\htdocs\uudecode.php5 on line 13

The error reporting data included this:
szAppName : php-cgi.exe     szAppVer : 5.0.0.0     szModName : ntdll.dll  
  
szModVer : 5.1.2600.1217     offset : 00033aed 

And 2 files.

-- 
Edit bug report at http://bugs.php.net/?id=28808&edit=1
-- 
Try a CVS snapshot (php4):  http://bugs.php.net/fix.php?id=28808&r=trysnapshot4
Try a CVS snapshot (php5):  http://bugs.php.net/fix.php?id=28808&r=trysnapshot5
Fixed in CVS:               http://bugs.php.net/fix.php?id=28808&r=fixedcvs
Fixed in release:           http://bugs.php.net/fix.php?id=28808&r=alreadyfixed
Need backtrace:             http://bugs.php.net/fix.php?id=28808&r=needtrace
Need Reproduce Script:      http://bugs.php.net/fix.php?id=28808&r=needscript
Try newer version:          http://bugs.php.net/fix.php?id=28808&r=oldversion
Not developer issue:        http://bugs.php.net/fix.php?id=28808&r=support
Expected behavior:          http://bugs.php.net/fix.php?id=28808&r=notwrong
Not enough info:            http://bugs.php.net/fix.php?id=28808&r=notenoughinfo
Submitted twice:            http://bugs.php.net/fix.php?id=28808&r=submittedtwice
register_globals:           http://bugs.php.net/fix.php?id=28808&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=28808&r=php3
Daylight Savings:           http://bugs.php.net/fix.php?id=28808&r=dst
IIS Stability:              http://bugs.php.net/fix.php?id=28808&r=isapi
Install GNU Sed:            http://bugs.php.net/fix.php?id=28808&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=28808&r=float

Reply via email to