-
Notifications
You must be signed in to change notification settings - Fork 313
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OpaqueResponse object #258
Comments
Yeah, they shouldn't have a method. You mentioned in IRC the possibility of exposing status on OpaqueResponses, or something to indicate "not 200". Had any more thoughts on that? This would be used by the cache to reject .add based on 404s etc. |
We need to ask @abarth et al whether they think we can expose the HTTP status code of tainted cross-origin resources. It seems somewhat scary to expose more, but as you said appcache already did without alarming people. |
@abarth some background: In ServiceWorker we have caches: var cache = new Cache();
var cachePromise = cache.add(url1, request2, url3...);
This means you can use AppCache to determine if a response from another origin, without CORS, looks like a 200 or a 4xx/5xx. If that isn't a security risk, we'd like ServiceWorker caches to behave in a similar way. fetch(request).then(function(response) {
// ...
}); When the response is to another origin and doesn't have CORS headers, we consider that an I'm less sure what to do about the cross-origin redirects. |
@abarth, correct. With elements you only learn about actual connection vs network error. With certain elements you can learn a bit more about whether the response can be decoded in some fashion. This would expose actual response data, accurately. |
We're not doing this for now. |
In Chrome, |
I can never find this thread when I want to, so here are some keywords I usually use to find it: detect 404 crossorigin addAll |
First of all, this should probably not expose anything.
Having said that, what is method? Responses don't have a method.
The text was updated successfully, but these errors were encountered: