{"categories":[{"label":"Security","url":"https://skillfed.io/packages/category/security/3"}],"enrichment":{"capability":"Sanitizes SVG files by removing malicious elements, attributes, and restricting data URL MIME types through a Python wrapper around the svg-hush Rust library.","skillfed_tags":["svg-security","rust-bindings"],"use_cases":["Sanitize user-uploaded SVG files in a web application before storing or displaying them.","Strip embedded scripts and event handlers from SVG graphics in a content management system.","Enforce a whitelist of allowed image MIME types in SVG data URLs to prevent unexpected content injection.","Batch-process a collection of SVG files to remove known attack vectors before distribution.","Validate SVG safety in a document processing pipeline that accepts external graphics."],"what_it_does":"py-svg-hush is a Python wrapper around Cloudflare's svg-hush Rust library that removes potentially malicious content from SVG files. It provides a single function, filter_svg, which takes SVG bytes and an optional dictionary of allowed MIME types for data URLs, then returns sanitized SVG bytes. The package strips dangerous elements and attributes while enforcing a whitelist of permitted data URL MIME types\u2014any data URL whose type is not in the whitelist is dropped entirely.\n\nThe package is built as a compiled extension using Rust bindings, which means installation requires downloading or building wheels for your platform and Python version. It supports Python 3.10 through 3.14 on CPython and PyPy, with prebuilt wheels available for common architectures. The API is minimal and straightforward: one function call with two parameters, raising ValueError or TypeError on invalid input.","worth_installing":"Yes, if you need to sanitize untrusted SVG input and can accept the license uncertainty. The package is straightforward, has no runtime dependencies, and benefits from battle-tested Rust logic. However, verify the license terms before use in proprietary or commercial contexts, and confirm that svg-hush's threat model matches your security requirements. The aging maintenance status (182 days since last release) is not a blocker for a stable utility, but monitor the repository for security updates."},"id":"py-svg-hush","links":{"html":"https://skillfed.io/packages/py-svg-hush","md":"https://skillfed.io/packages/py-svg-hush.md","pypi":"https://pypi.org/project/py-svg-hush/"},"maintenance":{"status":"aging"},"meta":{"latest_release":"2026-02-13","license_spdx":null,"license_treatment":"unclear","name":"py_svg_hush","python_support":"supports_current","summary":null},"popularity":{"monthly_downloads":82483,"position":14160,"tier":"top_15000"},"security":{"n_vulnerabilities":0},"version":"0.3.0"}
