X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/492af79c27f089e28c76007f93fef4995eda9d94..refs/pull/3303/head:/app/Util/CspService.php diff --git a/app/Util/CspService.php b/app/Util/CspService.php index 2979ebc3e..812e1a4be 100644 --- a/app/Util/CspService.php +++ b/app/Util/CspService.php @@ -12,7 +12,7 @@ class CspService public function __construct(string $nonce = '') { - $this->nonce = $nonce ?: Str::random(16); + $this->nonce = $nonce ?: Str::random(24); } /** @@ -90,7 +90,7 @@ class CspService protected function getAllowedIframeHosts(): array { $hosts = config('app.iframe_hosts', ''); + return array_filter(explode(' ', $hosts)); } - -} \ No newline at end of file +}