awesome-repositories.com
Blog
awesome-repositories.com

Descubre los mejores repositorios open-source con nuestra búsqueda potenciada por IA.

ExplorarBúsquedas curadasAlternativas open-sourceSoftware autohospedableBlogMapa del sitio
ProyectoAcerca deCómo clasificamosPrensaServidor MCP
Aviso legalPrivacidadTérminos
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
cure53 avatar

cure53/DOMPurify

0
View on GitHub↗
16,638 estrellas·821 forks·JavaScript·other·4 vistascure53.de/purify↗

DOMPurify

DOMPurify is a security-focused library designed to sanitize untrusted HTML input, preventing cross-site scripting attacks by stripping malicious code while preserving safe content. It functions as a utility for secure document object model manipulation, ensuring that user-provided rich text can be rendered safely within web applications.

The library distinguishes itself through a single-pass, mutation-observer-free processing model that operates on detached document fragments to avoid triggering unintended side effects. It employs recursive node traversal and context-aware logic to inspect and neutralize dangerous elements at any depth, validating all markup against a strictly defined allowlist of permitted tags and attributes.

Beyond basic sanitization, the project provides comprehensive support for browser-level security standards, including integration with trusted types policies. This ensures that sanitized output is compatible with modern security requirements, preventing the injection of unverified strings into sensitive document sinks. The library is available as a standalone package and includes a polyfill to maintain consistent security enforcement across different browser environments.

Features

  • HTML Sanitization Utilities - Strips malicious code from untrusted HTML input to prevent cross-site scripting attacks in web applications.
  • Input Sanitization - Removes malicious code and dangerous elements from input to prevent cross-site scripting while preserving safe content.
  • Cross-Site Scripting Prevention - Provides robust sanitization and encoding techniques to prevent cross-site scripting and filter evasion attacks.
  • DOM Security Utilities - Provides a secure utility for manipulating the document object model by filtering untrusted input.
  • Trusted Types Policies - Integrates with browser-level Trusted Types to prevent the execution of unverified string-based code.
  • Trusted Types Integrations - Integrates with browser security policies to ensure sanitized output is safely handled by sensitive document sinks.
  • Safe Rich Text Renderers - Enables safe rendering of user-provided rich text by stripping dangerous elements.
  • Trusted Types Polyfills - Ensures consistent security enforcement across browsers by polyfilling Trusted Types support.
  • HTML Content Policies - Enforces strict content policies by limiting allowed HTML tags and attributes.
  • DOM Security Policy Enforcers - Ensures dynamically generated content adheres to strict document object model safety standards.
  • DOM-Tree Sanitizers - Uses native browser parsing to safely inspect and clean document fragments.
  • HTML Allowlists - Provides granular control over permitted HTML elements and attributes to prevent malicious code injection.
  • Vulnerability Scanners - XSS sanitizer for HTML, MathML, and SVG.
  • Input Validation and Sanitization - Fast and tolerant XSS sanitizer for HTML and SVG.
  • Security and Sanitization - Fast, robust XSS sanitizer for HTML and SVG.
  • Security Middleware - Fast and secure DOM-only sanitizer for HTML, MathML, and SVG.
  • Security & Privacy - Fast, high-tolerance XSS filter for HTML/SVG.
  • Sanitization Contexts - Adapts sanitization logic dynamically to handle complex or nested HTML structures safely.
  • Single-Pass Cleanup Engines - Performs efficient, side-effect-free sanitization on detached document fragments.
  • Recursive Tree Traversers - Ensures deep inspection of document structures to neutralize nested malicious content.

Historial de estrellas

Gráfico del historial de estrellas de cure53/dompurifyGráfico del historial de estrellas de cure53/dompurify

Búsqueda con IA

Explora más repositorios increíbles

Describe lo que necesitas en lenguaje sencillo: la IA clasifica miles de proyectos open-source curados por relevancia.

Start searching with AI

Preguntas frecuentes

¿Qué hace cure53/dompurify?

DOMPurify is a security-focused library designed to sanitize untrusted HTML input, preventing cross-site scripting attacks by stripping malicious code while preserving safe content. It functions as a utility for secure document object model manipulation, ensuring that user-provided rich text can be rendered safely within web applications.

¿Cuáles son las características principales de cure53/dompurify?

Las características principales de cure53/dompurify son: HTML Sanitization Utilities, Input Sanitization, Cross-Site Scripting Prevention, DOM Security Utilities, Trusted Types Policies, Trusted Types Integrations, Safe Rich Text Renderers, Trusted Types Polyfills.

¿Qué alternativas de código abierto existen para cure53/dompurify?

Las alternativas de código abierto para cure53/dompurify incluyen: leizongmin/js-xss — js-xss is an HTML XSS sanitizer and whitelist-based HTML filter designed to remove malicious code from untrusted HTML.… microcosm-cc/bluemonday — bluemonday is a Go library for scrubbing user-generated HTML content to prevent cross-site scripting and other… erusev/parsedown — Parsedown is a PHP library that converts Markdown text and common extensions into structured HTML output for web… rexxars/react-markdown — react-markdown is a React renderer that converts markdown text into a virtual DOM to safely display formatted content.… apostrophecms/sanitize-html — This is an HTML sanitization library designed to remove dangerous tags and attributes from user-submitted HTML to… chriso/validator.js — validator.js is a JavaScript string validation and sanitization library. It provides a set of functions to verify that…

Alternativas open-source a DOMPurify

Proyectos open-source similares, clasificados según cuántas características comparten con DOMPurify.
  • leizongmin/js-xssAvatar de leizongmin

    leizongmin/js-xss

    5,319Ver en GitHub↗

    js-xss is an HTML XSS sanitizer and whitelist-based HTML filter designed to remove malicious code from untrusted HTML. It serves as a tool for cross-site scripting prevention and user-generated content management by cleaning HTML strings to ensure safe browser rendering. The library includes a CSS style validator to scrub inline styles against a whitelist and an HTML content purifier capable of stripping all tags to extract raw text. It allows for custom HTML filtering through the definition of specific rules and handler functions to control permitted elements and attributes. The tool covers

    HTML
    Ver en GitHub↗5,319
  • microcosm-cc/bluemondayAvatar de microcosm-cc

    microcosm-cc/bluemonday

    3,688Ver en GitHub↗

    bluemonday is a Go library for scrubbing user-generated HTML content to prevent cross-site scripting and other injection attacks. It functions as an HTML policy engine and sanitizer that removes dangerous scripts and malicious tags by applying configurable element and attribute allowlists. The project distinguishes itself through a rule-based system that utilizes regular expressions and name-based lists to define permitted tags, attributes, and CSS styles. It includes a URL security validator that enforces safe protocols and automatically injects security attributes such as nofollow and noope

    Goallowlistgogolang
    Ver en GitHub↗3,688
  • erusev/parsedownAvatar de erusev

    erusev/parsedown

    15,049Ver en GitHub↗

    Parsedown is a PHP library that converts Markdown text and common extensions into structured HTML output for web browsers. It functions as a Markdown to HTML converter that processes both block-level and inline elements to generate valid web content. The library includes a PHP HTML sanitizer designed to escape HTML and scripting vectors. This security layer provides input sanitization to prevent attacks when processing untrusted user-generated content.

    PHP
    Ver en GitHub↗15,049
  • rexxars/react-markdownAvatar de rexxars

    rexxars/react-markdown

    15,773Ver en GitHub↗

    react-markdown is a React renderer that converts markdown text into a virtual DOM to safely display formatted content. It functions as a markdown syntax parser and renderer that transforms markdown strings into structural elements, ensuring XSS-safe content delivery. The project allows for the mapping of standard markdown elements to custom React components for specialized styling and behavior. It supports syntax extensions through a plugin system, enabling additional formatting features such as tables, footnotes, and tasklists. The system includes security primitives for HTML and URL saniti

    JavaScript
    Ver en GitHub↗15,773
  • Ver las 30 alternativas a DOMPurify→