Closed Bug 1613571 Opened 5 years ago Closed 5 years ago

Fix some more issues with service worker exceptions

Categories

(Core :: DOM: Service Workers, task)

task
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla74
Tracking Status
firefox74 --- fixed

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

ServiceWorkerScopeAndScriptAreValid doesn't quite do what the spec says in various ways.

Behavior changes:

  1. We now throw a TypeError, not a SecurityError, when the script URI scheme is
    not 'http' or 'https', like the spec says to.

  2. We now throw when the scope URI scheme is not 'http' or 'https', like the
    spec says to.

  3. We now throw a proper TypeError, not a DOMException, at the end of
    CheckForSlashEscapedCharsInPath.

  4. More informative error messages.

Pushed by bzbarsky@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e2543a95ade0 Align service worker invalid-script-url and invalid-scope-url checks better with the spec. r=dom-workers-and-storage-reviewers,perry
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/21642 for changes under testing/web-platform/tests
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla74
Upstream PR merged by moz-wptsync-bot
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: