Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(69)

Issue 329323002: Deprecate support for xhr.withCredentials for synchronous requests (Closed)

Created:
6 years, 6 months ago by maheshkk
Modified:
6 years, 6 months ago
CC:
aandrey+blink_chromium.org, apavlov+blink_chromium.org, blink-reviews, caseq+blink_chromium.org, devtools-reviews_chromium.org, eustas+blink_chromium.org, loislo+blink_chromium.org, lushnikov+blink_chromium.org, malch+blink_chromium.org, paulirish+reviews_chromium.org, pfeldman+blink_chromium.org, sergeyv+blink_chromium.org, vsevik+blink_chromium.org, yurys+blink_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

Deprecate support for xhr.withCredentials for synchronous requests As per XML Level2 spec, withCredentials flag cannot be set on sync request. http://xhr.spec.whatwg.org/#the-withcredentials-attribute However for time being add useCounter and throw console warning to web developers. Intent to deprecate - https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/BOgLhbdljU4 BUG=383483 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=176532

Patch Set 1 #

Total comments: 1

Patch Set 2 : Deprecate withCredentials with useCounter #

Total comments: 2

Patch Set 3 : only display deprecated message without changing existing behavior #

Total comments: 3

Patch Set 4 : update per review comments #

Total comments: 5

Patch Set 5 : Rebased with latest #

Total comments: 6

Patch Set 6 : Use executionContext insread of document #

Patch Set 7 : Remove async condition in network-test.js #

Unified diffs Side-by-side diffs Delta from patch set Stats (+21 lines, -0 lines) Patch
M LayoutTests/http/tests/inspector/console-xhr-logging-expected.txt View 1 2 3 4 5 6 2 chunks +2 lines, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/har-content-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/load-resource-for-frontend-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/network-content-replacement-xhr-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/network-cyrillic-xhr-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/network-empty-xhr-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/network-xhr-replay-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/network/network-xhr-sync-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/inspector/resource-tree/resource-tree-no-xhrs-expected.txt View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/xmlhttprequest/access-control-preflight-credential-sync-expected.txt View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M LayoutTests/http/tests/xmlhttprequest/cross-origin-cookie-storage-expected.txt View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/frame/UseCounter.h View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M Source/core/frame/UseCounter.cpp View 1 2 3 4 5 6 1 chunk +3 lines, -0 lines 0 comments Download
M Source/core/xml/XMLHttpRequest.cpp View 1 2 3 4 5 6 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 40 (0 generated)
maheshkk
First proposal is to just throw warning. Still does not match spec, alternatively we can ...
6 years, 6 months ago (2014-06-11 20:34:42 UTC) #1
Inactive
Please update your CL description to contain the behavior of IE11 and Firefox 29. https://codereview.chromium.org/329323002/diff/1/Source/core/xml/XMLHttpRequest.cpp ...
6 years, 6 months ago (2014-06-12 13:28:40 UTC) #2
maheshkk
Thanks for the review Chris. On 2014/06/12 13:28:40, Chris Dumez wrote: > Please update your ...
6 years, 6 months ago (2014-06-12 15:01:06 UTC) #3
maheshkk
dglazkov, PTAL, and do you think we should deprecate withCredentials or just throw exception as ...
6 years, 6 months ago (2014-06-13 20:13:34 UTC) #4
dglazkov
On 2014/06/13 at 20:13:34, mahesh.kk wrote: > dglazkov, PTAL, and do you think we should ...
6 years, 6 months ago (2014-06-13 20:42:06 UTC) #5
maheshkk
On 2014/06/13 20:42:06, dglazkov wrote: > On 2014/06/13 at 20:13:34, mahesh.kk wrote: > > dglazkov, ...
6 years, 6 months ago (2014-06-13 20:43:24 UTC) #6
maheshkk
Added UseCounter and deprecate message for withCredentials. PTAL.
6 years, 6 months ago (2014-06-13 21:48:26 UTC) #7
sof
https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp#newcode494 Source/core/xml/XMLHttpRequest.cpp:494: return; If I understand your intent correctly, isn't this ...
6 years, 6 months ago (2014-06-16 14:21:34 UTC) #8
maheshkk
On 2014/06/16 14:21:34, sof wrote: > https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp > File Source/core/xml/XMLHttpRequest.cpp (right): > > https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp#newcode494 > ...
6 years, 6 months ago (2014-06-16 15:53:21 UTC) #9
Inactive
https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp#newcode494 Source/core/xml/XMLHttpRequest.cpp:494: return; On 2014/06/16 14:21:34, sof wrote: > If I ...
6 years, 6 months ago (2014-06-16 17:07:33 UTC) #10
maheshkk
On 2014/06/16 17:07:33, Chris Dumez wrote: > https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp > File Source/core/xml/XMLHttpRequest.cpp (right): > > https://codereview.chromium.org/329323002/diff/20001/Source/core/xml/XMLHttpRequest.cpp#newcode494 ...
6 years, 6 months ago (2014-06-16 17:57:42 UTC) #11
Inactive
https://codereview.chromium.org/329323002/diff/40001/Source/core/frame/UseCounter.cpp File Source/core/frame/UseCounter.cpp (right): https://codereview.chromium.org/329323002/diff/40001/Source/core/frame/UseCounter.cpp#newcode737 Source/core/frame/UseCounter.cpp:737: return "Support for withCredentials deprecated for synchronous requests."; Setting ...
6 years, 6 months ago (2014-06-16 18:05:47 UTC) #12
sof
Great, thanks for updating the patch. If not already, have you looked at http://www.chromium.org/blink#TOC-Launch-Process:-Deprecation and ...
6 years, 6 months ago (2014-06-16 18:11:12 UTC) #13
maheshkk
Thanks again Chris, sof for your reviews! I have updated patch per your comments.
6 years, 6 months ago (2014-06-16 21:38:42 UTC) #14
Inactive
On 2014/06/16 21:38:42, maheshkk wrote: > Thanks again Chris, sof for your reviews! I have ...
6 years, 6 months ago (2014-06-16 21:40:18 UTC) #15
eseidel
https://codereview.chromium.org/329323002/diff/80001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/80001/Source/core/xml/XMLHttpRequest.cpp#newcode490 Source/core/xml/XMLHttpRequest.cpp:490: // FIXME: According to XMLHttpRequest Level 2 we should ...
6 years, 6 months ago (2014-06-16 23:23:51 UTC) #16
Inactive
https://codereview.chromium.org/329323002/diff/80001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/80001/Source/core/xml/XMLHttpRequest.cpp#newcode490 Source/core/xml/XMLHttpRequest.cpp:490: // FIXME: According to XMLHttpRequest Level 2 we should ...
6 years, 6 months ago (2014-06-17 00:02:22 UTC) #17
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/329323002/diff/80001/LayoutTests/http/tests/inspector/network-test.js File LayoutTests/http/tests/inspector/network-test.js (right): https://codereview.chromium.org/329323002/diff/80001/LayoutTests/http/tests/inspector/network-test.js#newcode94 LayoutTests/http/tests/inspector/network-test.js:94: if (async) I think we should catch bad combination ...
6 years, 6 months ago (2014-06-17 02:19:49 UTC) #18
sof
https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp#newcode492 Source/core/xml/XMLHttpRequest.cpp:492: if (!m_async && executionContext()->isDocument()) No need to check isDocument(), ...
6 years, 6 months ago (2014-06-18 08:16:06 UTC) #19
maheshkk
On 2014/06/18 08:16:06, sof wrote: > https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp > File Source/core/xml/XMLHttpRequest.cpp (right): > > https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp#newcode492 > ...
6 years, 6 months ago (2014-06-18 15:36:34 UTC) #20
sof
(Please comment on the issues raised rather than inline; it just gets messy without.) On ...
6 years, 6 months ago (2014-06-18 15:44:07 UTC) #21
maheshkk
https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp#newcode492 Source/core/xml/XMLHttpRequest.cpp:492: if (!m_async && executionContext()->isDocument()) On 2014/06/18 08:16:06, sof wrote: ...
6 years, 6 months ago (2014-06-18 15:55:08 UTC) #22
sof
https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp#newcode493 Source/core/xml/XMLHttpRequest.cpp:493: UseCounter::countDeprecation(document(), UseCounter::SyncXHRWithCredentials); On 2014/06/18 15:55:08, maheshkk wrote: > On ...
6 years, 6 months ago (2014-06-18 16:13:36 UTC) #23
maheshkk
https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp File Source/core/xml/XMLHttpRequest.cpp (right): https://codereview.chromium.org/329323002/diff/100001/Source/core/xml/XMLHttpRequest.cpp#newcode493 Source/core/xml/XMLHttpRequest.cpp:493: UseCounter::countDeprecation(document(), UseCounter::SyncXHRWithCredentials); On 2014/06/18 16:13:36, sof wrote: > On ...
6 years, 6 months ago (2014-06-18 23:53:07 UTC) #24
eseidel
I think it's fine to go ahead and deprecate directly. No need to use count ...
6 years, 6 months ago (2014-06-19 00:07:58 UTC) #25
maheshkk
On 2014/06/19 00:07:58, eseidel wrote: > I think it's fine to go ahead and deprecate ...
6 years, 6 months ago (2014-06-19 00:26:45 UTC) #26
sof
Good - with that clarification made, lgtm (patchset 6.)
6 years, 6 months ago (2014-06-19 06:37:20 UTC) #27
maheshkk
The CQ bit was checked by mahesh.kk@samsung.com
6 years, 6 months ago (2014-06-19 08:26:11 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/mahesh.kk@samsung.com/329323002/120001
6 years, 6 months ago (2014-06-19 08:26:36 UTC) #29
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 6 months ago (2014-06-19 08:26:46 UTC) #30
commit-bot: I haz the power
Failed to apply patch for Source/core/frame/UseCounter.h: While running patch -p1 --forward --force --no-backup-if-mismatch; patching file ...
6 years, 6 months ago (2014-06-19 08:26:47 UTC) #31
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/329323002/diff/80001/LayoutTests/http/tests/inspector/network-test.js File LayoutTests/http/tests/inspector/network-test.js (right): https://codereview.chromium.org/329323002/diff/80001/LayoutTests/http/tests/inspector/network-test.js#newcode94 LayoutTests/http/tests/inspector/network-test.js:94: if (async) On 2014/06/17 02:19:49, tyoshino wrote: > I ...
6 years, 6 months ago (2014-06-19 08:31:13 UTC) #32
maheshkk
On 2014/06/19 08:31:13, tyoshino wrote: > https://codereview.chromium.org/329323002/diff/80001/LayoutTests/http/tests/inspector/network-test.js > File LayoutTests/http/tests/inspector/network-test.js (right): > > https://codereview.chromium.org/329323002/diff/80001/LayoutTests/http/tests/inspector/network-test.js#newcode94 > ...
6 years, 6 months ago (2014-06-19 08:45:43 UTC) #33
tyoshino (SeeGerritForStatus)
On 2014/06/19 08:45:43, maheshkk wrote: > @tyoshino sorry you had to remind, I thought comment ...
6 years, 6 months ago (2014-06-19 08:58:16 UTC) #34
tyoshino (SeeGerritForStatus)
Sorry. Typo On 2014/06/19 08:58:16, tyoshino wrote: > With your change, makeXHR() will silently ignores ...
6 years, 6 months ago (2014-06-19 08:59:09 UTC) #35
maheshkk
On 2014/06/19 08:58:16, tyoshino wrote: > On 2014/06/19 08:45:43, maheshkk wrote: > > @tyoshino sorry ...
6 years, 6 months ago (2014-06-19 09:14:43 UTC) #36
tyoshino (SeeGerritForStatus)
On 2014/06/19 09:14:43, maheshkk wrote: > Ah my bad. now that I read your comments ...
6 years, 6 months ago (2014-06-19 15:17:35 UTC) #37
maheshkk
The CQ bit was checked by mahesh.kk@samsung.com
6 years, 6 months ago (2014-06-19 16:49:35 UTC) #38
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/mahesh.kk@samsung.com/329323002/140001
6 years, 6 months ago (2014-06-19 16:50:08 UTC) #39
commit-bot: I haz the power
6 years, 6 months ago (2014-06-19 17:58:50 UTC) #40
Message was sent while issue was closed.
Change committed as 176532

Powered by Google App Engine
This is Rietveld 408576698