Application security / Practical guide

Review third-party JavaScript on your sensitive pages

By OfRoot Technology · · Sources checked

A focused review of browser scripts, supplier permissions and a safe Content Security Policy rollout.

The short version

Start with one important user journey. Identify the scripts it loads, who can change them and the controls that limit their behavior. Test changes with synthetic data and keep a rollback ready. A passing repository scan cannot answer all of these browser and supplier questions.

Use the incident as context, not a diagnosis

Optimizely’s corrected incident report is context for this guide. It is not evidence that your site is affected. The review below is OfRoot’s engineering advice.

[1] Optimizely incident report, November 17; corrected November 18, 2026 ↗

List the code your visitors actually receive

Choose an authorized test environment and trace one journey, such as checkout or account recovery. Record each script, its purpose and owner, including code introduced by tag managers and embedded services. Check the browser’s loaded resources as well as the repository.

Ask whether each script needs to run on that page. Record who can publish supplier-side changes and whether your team can review that history. OWASP’s guidance treats third-party JavaScript as part of the application’s security risk.

[2] OWASP Third Party JavaScript Management Cheat Sheet ↗

Test a browser policy before enforcing it

A Content Security Policy restricts what a page may load or execute. MDN describes a report-only mode that reports policy violations without blocking them. Use it to observe compatibility before deciding what to enforce; report-only mode itself does not prevent execution.

Keep any existing enforced policy in place while evaluating a candidate. Test approved scripts and expected rejection cases. Do not treat a broad domain allowlist as proof that code served by an allowed supplier is trustworthy.

[3] MDN: Content Security Policy ↗

Keep the test useful and reversible

Use synthetic accounts and payment test modes. Confirm the legitimate journey still works, capture only the evidence needed and assign an owner to unresolved findings. Review what policy reports contain before sending them to another service; page addresses can carry private information.

Record the tested version, policy, exclusions and rollback. Have a person review the result before changing production. A quiet report can reflect limited test coverage, so write down what you exercised.

Combine repository checks with application testing

OfRoot Repository Check reports selected patterns in staged Git content. It does not inspect a vendor account, monitor a live browser or establish whether an incident occurred.

OfRoot can help map these dependencies, fix findings and retest the workflow. Where a penetration test is useful, we arrange the authorized scope with approved security specialists.

Sources and further reading

  1. Optimizely incident report, November 17; corrected November 18, 2026 ↗
  2. OWASP Third Party JavaScript Management Cheat Sheet ↗
  3. MDN: Content Security Policy ↗

Follow the security developments behind the work.

Optimizely updates its Web Experimentation incident report →

Need a review, a penetration test or help fixing findings?

Explore application security →