-
Notifications
You must be signed in to change notification settings - Fork 22.9k
FF145 Relnote: Trusted Types early beta #41518
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
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Preview URLs
Flaws (2)Note! 2 documents with no flaws that don't need to be listed. 🎉 URL:
External URLs (2)URL:
URL:
(comment last updated: 2025-10-14 02:11:53) |
### Extensions to other interfaces | ||
|
||
The following sections list injection sinks that are expected to accept trusted types as well as strings. | ||
|
||
#### TrustedHTML | ||
|
||
- {{domxref("Document.parseHTMLUnsafe_static()")}} | ||
- {{domxref("Document.write()")}} | ||
- {{domxref("DOMParser.parseFromString()")}} | ||
- {{domxref("Element.innerHTML")}} | ||
- {{domxref("Element.insertAdjacentHTML")}} | ||
- {{domxref("Element.outerHTML")}} | ||
- {{domxref("Element.setHTMLUnsafe()")}} | ||
- {{domxref("HTMLIFrameElement.srcdoc")}} | ||
- {{domxref("Range.createContextualFragment()")}} | ||
- {{domxref("ShadowRoot.innerHTML")}} | ||
- {{domxref("ShadowRoot.setHTMLUnsafe()")}} | ||
|
||
#### TrustedScript | ||
|
||
- {{domxref("HTMLScriptElement.innerText")}} | ||
- {{domxref("HTMLScriptElement.textContent")}} | ||
- {{domxref("HTMLScriptElement.text")}} | ||
- {{domxref("window.setTimeout()")}} | ||
- {{domxref("window.setInterval()")}} | ||
|
||
#### TrustedScriptURL | ||
|
||
- {{domxref("HTMLScriptElement.src")}} | ||
- {{domxref("SvgAnimatedString.baseVal")}} | ||
|
||
## Extensions to HTTP | ||
|
||
- {{CSP("require-trusted-types-for")}} | ||
- : Enforces that [Trusted Types](/en-US/docs/Web/API/Trusted_Types_API) are passed to DOM XSS [injection sinks](/en-US/docs/Web/API/Trusted_Types_API#concepts_and_usage). | ||
- {{CSP("trusted-types")}} | ||
- : Used to specify an allowlist of [Trusted Types](/en-US/docs/Web/API/Trusted_Types_API) policy names. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wbamberg I added the HTTP list to the TT API overview because the associated CSP directives were not obvious, and I added the injection sink lists because these are APIs that were updated as part of this API, even if not covered in the specific spec.
The injection sink lists may not be exhaustive. Best I can do so far.
FF145 supports Trusted Types in early beta in https://bugzilla.mozilla.org/show_bug.cgi?id=1992941
This adds a release note, experimental feature, and updates the API overview page.
Its in draft while I confirm the scope with engineering.
Related work can be tracked in #41507