diff --git a/index.php b/index.php index 39ff37a6..277bfa7e 100644 --- a/index.php +++ b/index.php @@ -830,7 +830,7 @@ private function getDownloadedFilePath(): string { * * @throws \Exception */ - public function verifyIntegrity(): void { + public function verifyIntegrity(string $urlOverride = ''): void { $this->silentLog('[info] verifyIntegrity()'); if ($this->getCurrentReleaseChannel() === 'daily') { @@ -838,6 +838,11 @@ public function verifyIntegrity(): void { return; } + if ($urlOverride !== '') { + $this->silentLog('[info] custom download url provided, cannot verify signature'); + return; + } + $response = $this->getUpdateServerResponse(); if (empty($response['signature'])) { throw new \Exception('No signature specified for defined update'); diff --git a/lib/UpdateCommand.php b/lib/UpdateCommand.php index 0070ded8..67e0eb32 100644 --- a/lib/UpdateCommand.php +++ b/lib/UpdateCommand.php @@ -463,7 +463,7 @@ protected function executeStep(int $step, OutputInterface $output): array { $this->updater->silentLog('[info] Skipping integrity check as requested'); break; } - $this->updater->verifyIntegrity(); + $this->updater->verifyIntegrity($this->urlOverride); break; case 6: $this->updater->extractDownload(); diff --git a/lib/Updater.php b/lib/Updater.php index b8992d22..9a915277 100644 --- a/lib/Updater.php +++ b/lib/Updater.php @@ -814,7 +814,7 @@ private function getDownloadedFilePath(): string { * * @throws \Exception */ - public function verifyIntegrity(): void { + public function verifyIntegrity(string $urlOverride = ''): void { $this->silentLog('[info] verifyIntegrity()'); if ($this->getCurrentReleaseChannel() === 'daily') { @@ -822,6 +822,11 @@ public function verifyIntegrity(): void { return; } + if ($urlOverride !== '') { + $this->silentLog('[info] custom download url provided, cannot verify signature'); + return; + } + $response = $this->getUpdateServerResponse(); if (empty($response['signature'])) { throw new \Exception('No signature specified for defined update'); diff --git a/updater.phar b/updater.phar index ff709102..f2e464ac 100755 Binary files a/updater.phar and b/updater.phar differ