{"action":"opened","issue":{"url":"https://api.github.com/repos/FiyoCMS/FiyoCMS/issues/3","repository_url":"https://api.github.com/repos/FiyoCMS/FiyoCMS","labels_url":"https://api.github.com/repos/FiyoCMS/FiyoCMS/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/FiyoCMS/FiyoCMS/issues/3/comments","events_url":"https://api.github.com/repos/FiyoCMS/FiyoCMS/issues/3/events","html_url":"https://github.com/FiyoCMS/FiyoCMS/issues/3","id":243190165,"number":3,"title":"An any file read in change_logo.php","user":{"login":"iflody","id":14952798,"avatar_url":"https://avatars6.githubusercontent.com/u/14952798?v=4","gravatar_id":"","url":"https://api.github.com/users/iflody","html_url":"https://github.com/iflody","followers_url":"https://api.github.com/users/iflody/followers","following_url":"https://api.github.com/users/iflody/following{/other_user}","gists_url":"https://api.github.com/users/iflody/gists{/gist_id}","starred_url":"https://api.github.com/users/iflody/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iflody/subscriptions","organizations_url":"https://api.github.com/users/iflody/orgs","repos_url":"https://api.github.com/users/iflody/repos","events_url":"https://api.github.com/users/iflody/events{/privacy}","received_events_url":"https://api.github.com/users/iflody/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-07-15T17:57:24Z","updated_at":"2017-07-15T17:57:24Z","closed_at":null,"body":"In /dapur/apps/app_theme/controller/change_logo.php \r\n\r\nThere is not any filter on $_GET['file'] and $_GET['ori'], which may make a illegal file read or file delete.\r\n```\r\nif(isset($_GET['file']))\r\n$file\t= '../../../../../'.$_GET['file'];\r\n$ori\t= '../../../'.$_GET['ori'];\r\n\r\nif(isset($_GET['delete']) AND $_GET['delete'] == 'true' AND file_exists($ori.\".ori\")) {\r\n\tunlink($ori);\r\n\trename($ori.\".ori\",$ori);\r\n\talert('success','Logo Successfuly Restore',1);\t\r\n}\r\nelse if(isset($_GET['file']) AND !empty($_GET['file']) AND file_exists($file) AND file_exists($ori.\".ori\")) {\r\n\tcopy($file,$ori);\r\n\talert('success','Logo Successfuly Updated',1);\r\n\t\r\n}\r\nelse if(isset($_GET['file']) AND !empty($_GET['file']) AND file_exists($file)){\r\n\tcopy($ori,$ori.\".ori\");\r\n\tcopy($file,$ori);\r\n\talert('success','Logo Successfuly Updated',1);\r\n}\r\n```\r\n\r\nDiscover: Chaitin Technology\r\n\r\n![image](https://user-images.githubusercontent.com/14952798/28241540-29a5cb12-69c9-11e7-9505-36ba8c2a8387.png)\r\n"}}
{"actor":{"display_login":"iflody"}}