Re: [whatwg/fetch] Integrity-metadata should not be a preload key (PR #1418)

> > That test has a good digest for preload and a bad one for consume, and it shows that the preload is ignored.
> 
> Why would the preload be ignored though? How does that follow from the specification text?

Actually you're right. The test shows that there would be two requests, while in the spec text there would be one request and the image would fail.

I think a spec text that would correspond with the tests (and current implementation) is to keep fetch as is, but to make integrity meta data an "optional" part of the preload key, meaning that if it's not present then the lookup ignores integrity metadata.

This is also reflected by "Cross-origin script, not CORS request, with hash mismatch" - there is only one (failing) request that also fails the consumer even though the consumer doesn't specify a hash. 

-- 
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/pull/1418#issuecomment-1076436012
You are receiving this because you are subscribed to this thread.

Message ID: <whatwg/fetch/pull/1418/c1076436012@github.com>

Received on Wednesday, 23 March 2022 14:23:53 UTC