Deprecated: Creation of dynamic property idna_convert::$slast is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/simplepie/simplepie/idn/idna_convert.class.php on line 96

Deprecated: Return type of Zotlabs\Web\SessionHandler::open($s, $n) should either be compatible with SessionHandlerInterface::open(string $path, string $name): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Web/SessionHandler.php on line 9

Deprecated: Return type of Zotlabs\Web\SessionHandler::close() should either be compatible with SessionHandlerInterface::close(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Web/SessionHandler.php on line 78

Deprecated: Return type of Zotlabs\Web\SessionHandler::read($id) should either be compatible with SessionHandlerInterface::read(string $id): string|false, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Web/SessionHandler.php on line 18

Deprecated: Return type of Zotlabs\Web\SessionHandler::write($id, $data) should either be compatible with SessionHandlerInterface::write(string $id, string $data): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Web/SessionHandler.php on line 39

Deprecated: Return type of Zotlabs\Web\SessionHandler::destroy($id) should either be compatible with SessionHandlerInterface::destroy(string $id): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Web/SessionHandler.php on line 83

Deprecated: Return type of Zotlabs\Web\SessionHandler::gc($expire) should either be compatible with SessionHandlerInterface::gc(int $max_lifetime): int|false, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Web/SessionHandler.php on line 89

Deprecated: Creation of dynamic property idna_convert::$slast is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/simplepie/simplepie/idn/idna_convert.class.php on line 96

Deprecated: Creation of dynamic property idna_convert::$slast is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/simplepie/simplepie/idn/idna_convert.class.php on line 96

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home/lasafyfh/arc.lasalpujarras.online/Zotlabs/Lib/Apps.php on line 428
Help: Content_security_policy
Deprecated: Creation of dynamic property Smarty_Internal_Template::$compiled is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/smarty/smarty/libs/sysplugins/smarty_internal_template.php on line 719

Deprecated: Creation of dynamic property Smarty_Internal_Template::$compiled is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/smarty/smarty/libs/sysplugins/smarty_internal_template.php on line 719

Deprecated: Creation of dynamic property Smarty_Internal_Template::$compiled is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/smarty/smarty/libs/sysplugins/smarty_internal_template.php on line 719

Deprecated: Creation of dynamic property Smarty_Internal_Template::$compiled is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/smarty/smarty/libs/sysplugins/smarty_internal_template.php on line 719

Hubzilla Documentation:

Contents

content_security_policy



Called to modify CSP settings prior to the output of the Content-Security-Policy header.

This hook permits addons to modify the content-security-policy if necessary to allow loading of foreign js libraries or css styles.

if(App::$config['system']['content_security_policy']) {
        $cspsettings = Array (
                'script-src' => Array ("'self'","'unsafe-inline'","'unsafe-eval'"),
                'style-src' => Array ("'self'","'unsafe-inline'")
        );
        call_hooks('content_security_policy',$cspsettings);

        // Legitimate CSP directives (cxref: https://content-security-policy.com/)
        $validcspdirectives=Array(
                "default-src", "script-src", "style-src",
                "img-src", "connect-src", "font-src",
                "object-src", "media-src", 'frame-src',
                'sandbox', 'report-uri', 'child-src',
                'form-action', 'frame-ancestors', 'plugin-types'
        );
        $cspheader = "Content-Security-Policy:";
        foreach ($cspsettings as $cspdirective => $csp) {
                if (!in_array($cspdirective,$validcspdirectives)) {
                        logger("INVALID CSP DIRECTIVE: ".$cspdirective,LOGGER_DEBUG);
                        continue;
                }
                $cspsettingsarray=array_unique($cspsettings[$cspdirective]);
                $cspsetpolicy = implode(' ',$cspsettingsarray);
                if ($cspsetpolicy) {
                        $cspheader .= " ".$cspdirective." ".$cspsetpolicy.";";
                }
        }
        header($cspheader);
}


see: boot.php

Deprecated: Creation of dynamic property Smarty_Internal_Template::$compiled is deprecated in /home/lasafyfh/arc.lasalpujarras.online/vendor/smarty/smarty/libs/sysplugins/smarty_internal_template.php on line 719