From 9a0693117593185b7d46ff9531c0a1e1f3186076 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Fri, 14 Jun 2024 13:38:55 +0200 Subject: feat: add command to export certificate bundle Signed-off-by: Robin Appelman --- core/Command/Security/ExportCertificates.php | 35 ++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 core/Command/Security/ExportCertificates.php (limited to 'core/Command') diff --git a/core/Command/Security/ExportCertificates.php b/core/Command/Security/ExportCertificates.php new file mode 100644 index 00000000000..dcf34d4bce4 --- /dev/null +++ b/core/Command/Security/ExportCertificates.php @@ -0,0 +1,35 @@ +setName('security:certificates:export') + ->setDescription('export the certificate bundle'); + } + + protected function execute(InputInterface $input, OutputInterface $output): int { + $bundlePath = $this->certificateManager->getAbsoluteBundlePath(); + $bundle = file_get_contents($bundlePath); + $output->writeln($bundle); + return 0; + } +} -- cgit v1.2.3