-
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Setup with custom json file #27
Comments
:arrow-up: upgraded dependencies closes #27 thanks @MikeHarrison Signed-off-by: Bruno Meilick <b@bnomei.com>
@MikeHarrison it was a bug in my code. please upgrade and it should work now. if you test on localhost try setting site/config/config.localhost.php <?php
return [
'bnomei.securityheaders.enabled' => 'force', // this will work even when debug is true
// other options...
]; |
:arrow-up: upgraded dependencies closes #27 thanks @MikeHarrison Signed-off-by: Bruno Meilick <b@bnomei.com>
Hi, I would be happy to zip up the project and send over if that would help with working out what is happening |
I can confirm the same behaviour in the current version @bnomei - can you please check? This is the relevant part of my config.php for testing:
The result is an empty CSP policy. If I remove the loader function, the defaults are appplied so unless I made some mistake, this is not fixed yet. Can you please take a look? Thanks! |
If anybody else is running into the same issue - a workaround is using the setter method:
|
@andreasba |
Hi,
I have this plugin working with the default setup, but am struggling to use a custom json file to adjust the policy. This is my config.php (included in full in case there is an issue elsewhere):
Then in my site root I have the following json file (csp.json):
When using this setup I get no CSP generated at all. Can you please advise where I am going wrong? Thanks!
The text was updated successfully, but these errors were encountered: