[OOR-CORS] Fix messages for CORS-disabled schemes
With this CL, CORSURLLoader only allows "http", "https" and "data" schemes for CORS enabled requests. This CL adds a new error code, kCORSDisabledScheme, for the error. As noted in the design doc[1], no one updates the scheme list in Chromium, so it's safe to assume url::GetCORSEnabledSchemes is equivalent to the counterpart in blink::SchemeRegistry. We are planning to remove blink::SchemeRegistry::RegisterURLSchemeAsSecure. The existing xmlhttprequest/resources/cross-origin-unsupported-url.js output relies heavily on the error output timing. This CL fixes the test. Because the error is reported asynchronously, console messages change a bit (i.e., the line number doesn't show up). We accept that change. 1: https://docs.google.com/document/d/1JNmUcvbw2UcjfdI2uyUpveHXCbae-DQ1n8d_sVs5fLg/edit#heading=h.r9hjqrw3gn9e Bug: 736308 Cq-Include-Trybots: luci.chromium.try:linux_mojo Change-Id: Id49ad02e1413353e96c9fed1d0a84d34f0262fab Reviewed-on: https://chromium-review.googlesource.com/1144903Reviewed-by:Kinuko Yasuda <kinuko@chromium.org> Reviewed-by:
Adam Rice <ricea@chromium.org> Commit-Queue: Yutaka Hirano <yhirano@chromium.org> Cr-Commit-Position: refs/heads/master@{#577120}
Showing
Please register or sign in to comment