Linux anchor 4.4.0-210-generic #242-Ubuntu SMP Fri Apr 16 09:57:56 UTC 2021 x86_64
Apache/2.4.18 (Ubuntu)
Server IP : 10.10.100.4 & Your IP : 216.73.217.150
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
var /
www /
owncloud-prm /
updater /
src /
Command /
Delete
Unzip
Name
Size
Permission
Date
Action
BackupDataCommand.php
1.28
KB
-rw-r--r--
2018-04-19 18:16
BackupDbCommand.php
1.27
KB
-rw-r--r--
2018-04-19 18:16
CheckSystemCommand.php
3.42
KB
-rw-r--r--
2018-04-19 18:16
CheckpointCommand.php
3.19
KB
-rw-r--r--
2018-04-19 18:16
CleanCacheCommand.php
1.27
KB
-rw-r--r--
2018-04-19 18:16
Command.php
1.21
KB
-rw-r--r--
2018-04-19 18:16
DetectCommand.php
5.72
KB
-rw-r--r--
2018-04-19 18:16
ExecuteCoreUpgradeScriptsCommand.php
6.52
KB
-rw-r--r--
2018-04-19 18:16
InfoCommand.php
1.47
KB
-rw-r--r--
2018-04-19 18:16
MaintenanceModeCommand.php
2.03
KB
-rw-r--r--
2018-04-19 18:16
PostUpgradeCleanupCommand.php
2.62
KB
-rw-r--r--
2018-04-19 18:16
PostUpgradeRepairCommand.php
1.37
KB
-rw-r--r--
2018-04-19 18:16
PreUpgradeRepairCommand.php
1.36
KB
-rw-r--r--
2018-04-19 18:16
RestartWebServerCommand.php
1.31
KB
-rw-r--r--
2018-04-19 18:16
StartCommand.php
2.29
KB
-rw-r--r--
2018-04-19 18:16
UpdateConfigCommand.php
1.28
KB
-rw-r--r--
2018-04-19 18:16
Save
Rename
<?php /** * @author Victor Dubiniuk <dubiniuk@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 * * This code is free software: you can redistribute it and/or modify * it under the terms of the GNU Affero General Public License, version 3, * as published by the Free Software Foundation. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License, version 3, * along with this program. If not, see <http://www.gnu.org/licenses/> * */ namespace Owncloud\Updater\Command; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; use Owncloud\Updater\Utils\Collection; /** * Class CheckSystemCommand * * @package Owncloud\Updater\Command */ class CheckSystemCommand extends Command { protected $message = 'Checking system health.'; protected function configure(){ $this ->setName('upgrade:checkSystem') ->setDescription('System check. System health and if dependencies are OK (we also count the number of files and DB entries and give time estimations based on hardcoded estimation)') ; } /** * @param InputInterface $input * @param OutputInterface $output * @return int */ protected function execute(InputInterface $input, OutputInterface $output){ $locator = $this->container['utils.locator']; $fsHelper = $this->container['utils.filesystemhelper']; /** @var \Owncloud\Updater\Utils\Registry $registry */ $registry = $this->container['utils.registry']; /** @var \Owncloud\Updater\Utils\AppManager $appManager */ $appManager = $this->container['utils.appmanager']; $registry->set( 'notShippedApps', $appManager->getNotShippedApps() ); $docLink = $this->container['utils.docLink']; $collection = new Collection(); $rootDirItems= $locator->getRootDirItems(); foreach ($rootDirItems as $item){ $fsHelper->checkr($item, $collection); } $notReadableFiles = $collection->getNotReadable(); $notWritableFiles = $collection->getNotWritable(); if (count($notReadableFiles)){ $output->writeln('<error>The following files and directories are not readable:</error>'); $output->writeln($this->longArrayToString($notReadableFiles)); } if (count($notWritableFiles)){ $output->writeln('<error>The following files and directories are not writable:</error>'); $output->writeln($this->longArrayToString($notWritableFiles)); } if (count($notReadableFiles) || count($notWritableFiles)){ $output->writeln('<info>Please check if owner and permissions for these files are correct.</info>'); $output->writeln( sprintf( '<info>See %s for details.</info>', $docLink->getAdminManualUrl('installation/installation_wizard.html#strong-perms-label') ) ); return 2; } else { $output->writeln(' - file permissions are ok.'); } return 0; } /** * @param $array * @return string */ protected function longArrayToString($array){ if (count($array)>7){ $shortArray = array_slice($array, 0, 7); $more = sprintf('... and %d more items', count($array) - count($shortArray)); array_push($shortArray, $more); } else { $shortArray = $array; } $string = implode(PHP_EOL, $shortArray); return $string; } }