summaryrefslogtreecommitdiffstats
path: root/lib/private/installer.php
diff options
context:
space:
mode:
authormichag86 <micha_g@arcor.de>2015-08-10 09:36:16 +0200
committermichag86 <micha_g@arcor.de>2015-08-10 09:36:16 +0200
commit1a236905223536cdb392484d1c2f520dc1897c84 (patch)
treea5a2ba113a1a16b69ce07e2d728eddf9b8849d61 /lib/private/installer.php
parent214729a5524e2c406415985717c174bedc810954 (diff)
downloadnextcloud-server-1a236905223536cdb392484d1c2f520dc1897c84.tar.gz
nextcloud-server-1a236905223536cdb392484d1c2f520dc1897c84.zip
Check if archive contains a directory named like appid
Diffstat (limited to 'lib/private/installer.php')
-rw-r--r--lib/private/installer.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/installer.php b/lib/private/installer.php
index 37af8d0edcb..328a4abcfd9 100644
--- a/lib/private/installer.php
+++ b/lib/private/installer.php
@@ -107,6 +107,9 @@ class OC_Installer{
}
$extractDir .= '/' . $info['id'];
+ if(!file_exists($extractDir)) {
+ throw new \Exception($l->t("Archive does not contain a directory named %s", $info['id']));
+ }
OC_Helper::copyr($extractDir, $basedir);
//remove temporary files