
Security News
Another Round of TEA Protocol Spam Floods npm, But It’s Not a Worm
Recent coverage mislabels the latest TEA protocol spam as a worm. Here’s what’s actually happening.
@chopsui/trusted-types-policy
Advanced tools
Creates a secure TrustedTypes policy using DOMPurify as the sanitizer.
This package contains a function that creates a trusted types policy for HTML and JavaScript UIs which are using React (or any other framework) to protect from insecure usage of dangerouslySetInnerHTML either by the devs or any package/library that the project is using. If TrustedTypes are not supported by the browser it will fall back to the polyfill, see support here.
Add this meta tag line to your main HTML/template file, or all of them if you have multiple in the <head> tag.
<meta http-equiv="Content-Security-Policy" content="require-trusted-types-for 'script'">
Call this method in your entry point ts file (for React that will be index.tsx or index.ts)
import createInnerHTMLSanitizingPolicy from '@chopsui/trusted-types-policy';
createInnerHTMLSanitizingPolicy();
This should create a Trusted Types policy and any HTML string being insterted will be converted to a trusted type element.
FAQs
Creates a secure TrustedTypes policy using DOMPurify as the sanitizer.
We found that @chopsui/trusted-types-policy demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 11 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Recent coverage mislabels the latest TEA protocol spam as a worm. Here’s what’s actually happening.

Security News
PyPI adds Trusted Publishing support for GitLab Self-Managed as adoption reaches 25% of uploads

Research
/Security News
A malicious Chrome extension posing as an Ethereum wallet steals seed phrases by encoding them into Sui transactions, enabling full wallet takeover.