Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
brendanheywood authored Feb 27, 2024
1 parent b0c057a commit 51ccdb9
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,23 @@ CSP support in browsers is quite good:

https://caniuse.com/#search=CSP

To get started visit this admin settings page and enter a basic policy into csp_header_reporting and enable it with csp_header_enable.

/admin/settings.php?section=local_csp_settings

Then you will need to wait for a couple days or a week to collect statistics on what pages are violating that policy.
You can see all the violations here:

/local/csp/csp_report.php

As you discover violations you need to make the business decision of which domains should be allowed and either amend the CSP policy, or change the learning content so they do not violate the policy.

Each time you change the policy you can reset the statistics, either partially for each directives or fully.
When you gain confidence in your policy you can convert it from a 'reporting only' policy to a real policy that is enforced.

Be aware that if you prematurely set a policy which is too strict you can break your learning content and even completely break Moodle itself.


Branches
--------

Expand Down

0 comments on commit 51ccdb9

Please sign in to comment.