Closed Bug 1871063 Opened 2 years ago Closed 2 years ago

CSP: Trigger securityviolationevents on the document when a SharedWorker is blocked

Categories

(Core :: DOM: Workers, defect)

defect

Tracking

()

RESOLVED FIXED
124 Branch
Tracking Status
firefox124 --- fixed

People

(Reporter: tschuster, Assigned: tschuster)

References

(Blocks 1 open bug)

Details

Attachments

(2 files)

We currently have various failures in the content-security-policy/gen WPT folder related to new SharedWorker() not triggering a "securitypolicyviolation" event on the document.

This happens because we actually load the SharedWorker in the RemoteWorkerChild and we can't access the document in nsCSPContext::FireViolationEvent after blocking. We can workaround this by forwarding the error via PRemoteWorkerChild::SendError.

Depends on D196968

Attachment #9369664 - Attachment description: WIP: Bug 1871063 - Forward CSP violations from creating a new SharedWorker → Bug 1871063 - Forward CSP violations from creating a new SharedWorker. r?#dom-workers-and-storage-reviewers
Attachment #9369665 - Attachment description: WIP: Bug 1871063 - Update WPT meta data → Bug 1871063 - Update WPT meta data. r?#dom-workers-and-storage-reviewers
Severity: -- → S3

Hi Andrew, can you have a look at or redirect the patch?

Flags: needinfo?(bugmail)
Flags: needinfo?(echuang)

Thanks Eden.

Flags: needinfo?(echuang)
Flags: needinfo?(bugmail)
Attachment #9369664 - Attachment description: Bug 1871063 - Forward CSP violations from creating a new SharedWorker. r?#dom-workers-and-storage-reviewers → Bug 1871063 - Forward CSP violations from creating a new SharedWorker. r?edenchuang
Attachment #9369665 - Attachment description: Bug 1871063 - Update WPT meta data. r?#dom-workers-and-storage-reviewers → Bug 1871063 - Update WPT meta data. r?edenchuang
Pushed by tschuster@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/db0d5b6a75a4 Forward CSP violations from creating a new SharedWorker. r=edenchuang https://hg.mozilla.org/integration/autoland/rev/9445b35a9902 Update WPT meta data. r=edenchuang
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 124 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: