We reached out to jQuery and code.jquery.com does this for a few months now.
1,060 karma · joined August 21, 2013
We reached out to jQuery and code.jquery.com does this for a few months now.
Unfortunately, this could be used as a cache poisoning attack to bypass Content Security Policy.
See the section about "Content addressable storage" at <https://frederik-braun.com/subresource-integrity.html>.
(If you can come up with a magical solution to this problem, join the W3C web application security group mailing list and send us an email.)
SRI returns false (i.e. non-matching integrity) for scripts (or stylesheets) that do not enable CORS and are not same-origin [1]. Otherwise, an attacker could just disable CORS to bypass SRI.
flies away
[1] https://w3c.github.io/webappsec/specs/subresourceintegrity/#...
works well in Firefox.
Learn your electronics and don't believe in rumors ;)