diff options
author | Côme Chilliet <come.chilliet@nextcloud.com> | 2023-05-11 11:52:04 +0200 |
---|---|---|
committer | Côme Chilliet <come.chilliet@nextcloud.com> | 2023-05-11 11:56:14 +0200 |
commit | a92028f5cdad089bac597e042656545acc78d86b (patch) | |
tree | ecf0d61be52ba35a1f3d160fb78190473f7480bb /apps/encryption/lib/Command | |
parent | 36fc5dc8ae989f0694ca97c9175ee0debbc36142 (diff) | |
download | nextcloud-server-a92028f5cdad089bac597e042656545acc78d86b.tar.gz nextcloud-server-a92028f5cdad089bac597e042656545acc78d86b.zip |
Rename command to drop-legacy-filekey and remove comment about legacy mode.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'apps/encryption/lib/Command')
-rw-r--r-- | apps/encryption/lib/Command/DropLegacyFileKey.php (renamed from apps/encryption/lib/Command/FixLegacyFileKey.php) | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/apps/encryption/lib/Command/FixLegacyFileKey.php b/apps/encryption/lib/Command/DropLegacyFileKey.php index 7b0b4ccfb73..acfb7c334ee 100644 --- a/apps/encryption/lib/Command/FixLegacyFileKey.php +++ b/apps/encryption/lib/Command/DropLegacyFileKey.php @@ -36,7 +36,7 @@ use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; -class FixLegacyFileKey extends Command { +class DropLegacyFileKey extends Command { private View $rootView; public function __construct( @@ -50,7 +50,7 @@ class FixLegacyFileKey extends Command { protected function configure(): void { $this - ->setName('encryption:fix-legacy-filekey') + ->setName('encryption:drop-legacy-filekey') ->setDescription('Scan the files for the legacy filekey format using RC4 and get rid of it (if master key is enabled)'); } @@ -74,7 +74,7 @@ class FixLegacyFileKey extends Command { } if ($result) { - $output->writeln('All scanned files are properly encrypted. You can disable the legacy compatibility mode.'); + $output->writeln('All scanned files are properly encrypted.'); return 0; } @@ -139,6 +139,7 @@ class FixLegacyFileKey extends Command { return; } $this->rootView->touch($source, $fileInfo->getMTime()); + $this->rootView->unlink($target); $output->writeln('<info>Migrated ' . $source . '</info>', OutputInterface::VERBOSITY_VERBOSE); } catch (DecryptionFailedException $e) { if ($this->rootView->file_exists($target)) { |