Skip to content

Commit

Permalink
Added some verification to avoid exploits.
Browse files Browse the repository at this point in the history
  • Loading branch information
jrbasso committed Jan 3, 2010
1 parent b7bdee1 commit 6ec1ef4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions models/behaviors/meio_upload.php
Expand Up @@ -1055,6 +1055,9 @@ function _createFolders($dir, $thumbsizes) {
**/
function _copyFileFromTemp($tmpName, $saveAs) {
$results = true;
if (!is_uploaded_file($tmpName)) {
return false;
}
$file = new File($tmpName, $saveAs);
$temp = new File($saveAs, true);
if (!$temp->write($file->read())) {
Expand Down

0 comments on commit 6ec1ef4

Please sign in to comment.