Script sources (script-src) is the most important CSP directive. It decides where JavaScript may be loaded from. Blocking unknown script sources is what stops most injected-script attacks.
Where to configure it
Aegisify Shield → Security Headers → CSP Builder → Script sources (Pro).
How to fill it in
- Enter one source per line, for example
https://www.googletagmanager.comorhttps://js.stripe.com. - Your own site is always included.
- Set the mode to Report-Only first.
Finding the sources you need
- Turn on Report-Only and browse the site, including checkout, forms, and pages with embeds.
- Review CSP Reports for blocked script URIs.
- Add only sources you recognize and trust.
- Repeat until the reports are clean, then switch to Enforced.
Inline scripts
Allow inline scripts adds 'unsafe-inline'. It is off by default because it weakens protection against injected scripts. Some themes and plugins need it; treat it as a temporary compatibility measure and Shield will warn you while it is on with an enforced directive.
Common sources
Analytics, tag managers, payment providers, chat widgets, video players, and CAPTCHA services. Remove sources for services you no longer use.
Related: CSP Builder mode, Allow inline JavaScript.
