#45431 [NEW]: getimagesize() can't handle a colon in filename parameter
| From: | hundrambit at gmail dot com | Date: | Fri, 04 Jul 2008 13:38:37 +0000 |
| Subject: | #45431 [NEW]: getimagesize() can't handle a colon in filename parameter | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-126280@lists.php.net to get a copy of this message | ||
From: hundrambit at gmail dot com
Operating system: Windows XP Professional + SP3
PHP version: 5.2.6
PHP Bug Type: GetImageSize related
Bug description: getimagesize() can't handle a colon in filename parameter
Description:
------------
getimagesize() function will return FALSE when a remote file containing a
colon (:) in filename is specified. It can't be handled / opened.
This image is used as example:
http://inattack.ru/bar/inattack_bar_2012_2:10_FFFFFF_5_0.jpg
PHP configuration allows remote files.
Reproduce code:
---------------
$res =
@getimagesize("http://inattack.ru/bar/inattack_bar_2012_2:10_FFFFFF_5_0.jpg");
if ($res === false) {
echo "Failed to open target image.";
} else {
echo "WxH: ".$res[0]."x".$res[1];
}
Expected result:
----------------
$res should return array with 5 elements, as it does when same image
without a colon in filename is specified.
Actual result:
--------------
A FALSE is returned.
--
Edit bug report at http://bugs.php.net/?id=45431&edit=1
--
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=45431&r=trysnapshot52
Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=45431&r=trysnapshot53
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=45431&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=45431&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=45431&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=45431&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=45431&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=45431&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=45431&r=support
Expected behavior: http://bugs.php.net/fix.php?id=45431&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=45431&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=45431&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=45431&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=45431&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=45431&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=45431&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=45431&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=45431&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=45431&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=45431&r=mysqlcfg