[Webkit-unassigned] [Bug 235656] New: Blocked link to font source does not emit error event
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Wed Jan 26 10:49:07 PST 2022
https://bugs.webkit.org/show_bug.cgi?id=235656
Bug ID: 235656
Summary: Blocked link to font source does not emit error event
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: WebCore Misc.
Assignee: webkit-unassigned at lists.webkit.org
Reporter: pgriffis at igalia.com
There are a couple of WPT tests that rely on the onerror handler being called when a font source is blocked by CSP.
They can be seen here: https://wpt.fyi/results/content-security-policy/font-src?label=master&label=experimental&product=safari&product=webkitgtk
But a snippet is:
var link = document.createElement('link');
link.rel="preload";
link.as="font";
link.href="http://{{hosts[alt][]}}:{{ports[http][0]}}/fonts/Ahem.ttf?font-none-blocked";
link.onload = t.unreached_func("Should not have loaded the font.");
link.onerror = t.step_func_done();
document.getElementsByTagName('head')[0].appendChild(link);
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20220126/677927ae/attachment.htm>
More information about the webkit-unassigned
mailing list