From d0315b7ed3d2dfc8731ec3604b3d7450e683c348 Mon Sep 17 00:00:00 2001 From: Andreas Grundler Date: Mon, 21 Oct 2013 17:36:44 +0200 Subject: [PATCH] RealPath nicht DomainPath --- lib/classes/aps/class.ApsInstaller.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/classes/aps/class.ApsInstaller.php b/lib/classes/aps/class.ApsInstaller.php index 2f882449..686a640d 100644 --- a/lib/classes/aps/class.ApsInstaller.php +++ b/lib/classes/aps/class.ApsInstaller.php @@ -269,12 +269,10 @@ class ApsInstaller extends ApsParser $this->db->query('DELETE FROM `' . TABLE_APS_INSTANCES . '` WHERE `ID` = ' . $this->db->escape($Row['InstanceID'])); $this->db->query('DELETE FROM `' . TABLE_APS_SETTINGS . '` WHERE `InstanceID` = ' . $this->db->escape($Row['InstanceID'])); - if($this->DomainPath != '' && checkDisallowedPaths($this->DomainPath)) + if($this->RealPath != '' && checkDisallowedPaths($this->RealPath)) { - $documentroot = getCustomerDetail($Row['CustomerID'],'documentroot'); - //remove data, #273 - if($this->DomainPath != $documentroot) { + if($this->DomainPath != '' && $this->DomainPath != '/') { self::UnlinkRecursive($this->RealPath . $this->DomainPath . '/'); } else { // save awstats/webalizer folder if it's the docroot @@ -341,7 +339,7 @@ class ApsInstaller extends ApsParser $mapping_url = $Xml->mapping['url']; } - if (($this->DomainPath == '') || ($this->DomainPath == '/')) + if ($this->RealPath == '' || !checkDisallowedPaths($this->RealPath)) { $this->db->query('UPDATE `' . TABLE_APS_INSTANCES . '` SET `Status` = ' . INSTANCE_ERROR . ' WHERE `ID` = ' . $this->db->escape($Row['InstanceID'])); return false;