BSD Ports

www/py-bleach 6.2.0 DragonFly

Easy safelist-based HTML-sanitizing tool

System
DragonFly
Repository
DPorts
Maintainer
[email protected] (as in FreeBSD)
License
APACHE20
Categories
python, www
Package size
302.0 KiB, 2123.2 KiB installed

Description

Bleach is an allowed-list-based HTML sanitizing library that escapes or strips markup and attributes.

Bleach can also linkify text safely, applying filters that Django's urlize filter cannot, and optionally setting rel attributes, even on links already in the text.

Bleach is intended for sanitizing text from untrusted sources. If you find yourself jumping through hoops to allow your site administrators to do lots of things, you're probably outside the use cases. Either trust those users, or don't.

Because it relies on html5lib, Bleach is as good as modern browsers at dealing with weird, quirky HTML fragments. And any of Bleach's methods will fix unbalanced or mis-nested tags.

In the other systems

The newest version among them is 6.4.0, as upstream numbers it.

SystemPortVersionVulnerabilitiesStatusMaintainerLast update
DragonFlywww/py-bleach6.2.0 behind since 2026-07-08none known-[email protected]-
FreeBSDwww/py-bleach6.4.0 newestnone known-[email protected]2026-07-08
OpenBSDwww/py-bleach6.4.0 newestno data-The OpenBSD ports mailing-list <[email protected]>2026-10-14
NetBSDwww/py-bleach6.4.0 newestnone known-[email protected]-
MidnightBSDwww/py-bleach6.2.0_1 behind since 2026-07-08no data-[email protected]-
HardenedBSDwww/py-bleach6.4.0 newestno data-[email protected]-
GhostBSDwww/py-bleach6.4.0 newestno data-[email protected]-

Compare across BSDs

Install

Binary package:

pkg install py311-bleach

From DPorts:

cd /usr/dports/www/py-bleach && make install clean

Dependency graph

Ports that need it on the left, what it needs to run on the right; at most 8 of each. "Dependencies" below lists them all.

Dependencies

Run dependencies 3