Check RAW data

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm getting from an external source a PNG image in raw format (encoded in base64).

And with this code I'll echo on the screen.

------
$img=base64_decode($_POST['img']);

header("Content-type: image/png");
echo $img;
------

How can I check if the data received is a real PNG raw (and not malicious code) ?

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux