admin/gallery_admin.php in planetGallery before 14.07.2006 allows remote attackers to execute arbitrary PHP code by uploading files with a double extension and directly accessing the file in the images directory, which bypasses a regular expression check for safe file types.
https://exchange.xforce.ibmcloud.com/vulnerabilities/27858
http://www.securityfocus.com/archive/1/440643/100/0/threaded
http://securityreason.com/securityalert/1268
http://archives.neohapsis.com/archives/fulldisclosure/2006-07/0434.html