Bug 156322 - Treat CSP level 2 connect-src violations as network errors
Summary: Treat CSP level 2 connect-src violations as network errors
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Page Loading (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2016-04-06 17:14 PDT by John Wilander
Modified: 2016-07-14 17:43 PDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John Wilander 2016-04-06 17:14:32 PDT
As Alex Christensen points out in https://bugs.webkit.org/show_bug.cgi?id=153598#c27, we should fire an error event and not throw an exception for asynchronous requests that violate CSP. For synchronous events we should throw a NetworkError.

The details can be found here:
https://www.w3.org/TR/XMLHttpRequest/#network-error
Comment 1 Radar WebKit Bug Importer 2016-05-27 12:09:18 PDT
<rdar://problem/26522382>
Comment 2 John Wilander 2016-07-14 17:43:21 PDT
This was eventually addressed in https://trac.webkit.org/changeset/199221 which is the patch for https://bugs.webkit.org/show_bug.cgi?id=153598.