PTNews v1.7.7 - Access to administrator functions without authentification .oO Overview Oo. PTNews v1.7.7 - Access to administrator functions without authentification Discovered on 2003, April, 7th Vendor: PTNews - http://www.openbg.net/ptsite/ PT News is a simple news system. This is lite solution for sites without SQL database support. Whole system is written in PHP (PHP3 and PHP4 support). A vulnerability allows to access to the administrator functions, without authentification. .oO Details Oo. In PTNews v1.7.7, administrator functions are located in the file news.inc Here is the interesting piece of code : //handle administrator functions $files = getFileNames($newsdir); $context = ""; if ($HTTP_POST_VARS[submitButton] == $lang[frm_btn]) { createNewsEntry($newsdir); if ("replace" == $HTTP_POST_VARS[action] && in_array($HTTP_POST_VARS[file], $files)) { deleteNewsEntry($newsdir.$HTTP_POST_VARS[file]); } makeNewsRSS($newsdir); } elseif (isset($HTTP_GET_VARS[delete])) { if ("all" == $HTTP_GET_VARS[delete]) { $context = deleteAll($newsdir,$config[newssuff]); } else { if (in_array($HTTP_GET_VARS[delete], $files)) deleteNewsEntry ($newsdir.$HTTP_GET_VARS[delete]); } makeNewsRSS($newsdir); } elseif (isset($HTTP_GET_VARS[edit]) && in_array($HTTP_GET_VARS[edit], $files)) { $context = editNewsEntry($newsdir,$HTTP_GET_VARS[edit]); } As you can see, it can handle : - News creation - News replacement - News deletion - News editing Now, the file "news.inc" is included in the index.php file as followed :