Skip to content

Commit

Permalink
Bug 1493449. Change the default credentials mode for module scripts f…
Browse files Browse the repository at this point in the history
…rom 'omit' to 'same-origin'. r=farre

The tests come directly from
web-platform-tests/wpt#13176 and
web-platform-tests/wpt#13245

Differential Revision: https://phabricator.services.mozilla.com/D7113

UltraBlame original commit: 2de25096cdd54c32488a4d5fdb1fefce6d1fb6db
  • Loading branch information
marco-c committed Oct 3, 2019
1 parent ea573cd commit 04e37b2
Show file tree
Hide file tree
Showing 7 changed files with 1,086 additions and 39 deletions.
14 changes: 1 addition & 13 deletions dom/script/ScriptLoader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6761,20 +6761,8 @@ CORSMode
=
=
CORS_NONE
)
{
securityFlags
|
=
nsILoadInfo
:
:
SEC_COOKIES_OMIT
;
}
else
if
(
|
aRequest
-
>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
[
dynamic
-
imports
-
credentials
.
sub
.
html
]
[
Dynamic
imports
should
be
loaded
with
or
without
the
credentials
based
on
the
same
-
origin
-
ness
and
the
parent
script
'
s
crossOrigin
attribute
]
expected
:
FAIL
bug
:
1342012
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,6 @@ fetching
expected
:
FAIL
bug
:
1342012
Original file line number Diff line number Diff line change
Expand Up @@ -327,15 +327,14 @@
.
sameOriginNone
'
not
found
'
'
Modules
should
be
loaded
without
with
the
credentials
when
Expand Down Expand Up @@ -447,9 +446,10 @@
'
Modules
should
not
be
loaded
without
with
the
credentials
when
Expand Down Expand Up @@ -481,9 +481,10 @@
'
Modules
should
not
be
loaded
without
with
the
credentials
when
Expand Down Expand Up @@ -554,18 +555,17 @@
(
w
.
sameOriginNoneDecendent
sameOriginNoneDescendant
'
not
found
'
'
Decendent
Descendant
modules
should
be
loaded
without
with
the
credentials
when
Expand All @@ -589,12 +589,12 @@
(
w
.
sameOriginAnonymousDecendent
sameOriginAnonymousDescendant
'
found
'
'
Decendent
Descendant
modules
should
be
Expand Down Expand Up @@ -629,12 +629,12 @@
(
w
.
sameOriginUseCredentialsDecendent
sameOriginUseCredentialsDescendant
'
found
'
'
Decendent
Descendant
modules
should
be
Expand Down Expand Up @@ -671,18 +671,19 @@
(
w
.
crossOriginNoneDecendent
crossOriginNoneDescendant
'
not
found
'
'
Decendent
Descendant
modules
should
not
be
loaded
without
with
the
credentials
when
Expand All @@ -706,18 +707,19 @@
(
w
.
crossOriginAnonymousDecendent
crossOriginAnonymousDescendant
'
not
found
'
'
Decendent
Descendant
modules
should
not
be
loaded
without
with
the
credentials
when
Expand Down Expand Up @@ -747,12 +749,12 @@
(
w
.
crossOriginUseCredentialsDecendent
crossOriginUseCredentialsDescendant
'
found
'
'
Decendent
Descendant
modules
should
be
Expand Down
Loading

0 comments on commit 04e37b2

Please sign in to comment.