WordPress Plugin Vulnerabilities

Mobile App Native <= 3.0 - Remote File Upload

Description

The code in file ./zen-mobile-app-native/server/images.php doesn't require authentication or check that the user is allowed to upload content.
It also doesn't sanitize the file upload against executable code.

<?php
//header('content-type: text/html; charset=iso-8859-2');
header('Content-Type: text/html; charset=utf-8');
header('Access-Control-Allow-Origin: *');
require_once('function.php');

if ($_FILES['file']['name']) {
if (!$_FILES['file']['error']) {
$name = md5(rand(100, 200));
$ext = explode('.', $_FILES['file']['name']);
$filename = $name . '.' . $ext[1];
$destination = 'images/' . $filename;
$location = $_FILES["file"]["tmp_name"];
move_uploaded_file($location, $destination);
echo $plugin_url.'/server/images/' . $filename;
}
else {
echo $message = 'Ooops! Your upload triggered the following error: '.$_FILES['file']['error'];
}
}

Proof of Concept

Affects Plugins

References

Miscellaneous

Submitter
Larry W. Cashdollar
Submitter website
Submitter twitter
Verified
No

Timeline

Publicly Published
2017-02-28 (about 9 years ago)
Added
2017-03-01 (about 9 years ago)
Last Updated
2020-09-22 (about 5 years ago)

Other