Bleach
Tool and Usage
Project details
- Year of inception
- License
- Apache License 2.0
- Programming language
- Python
- Latest release
- 6.2.0
- Latest release date
Project health
Why this tool?
Bleach is a library for Django that can sanitize HTML by escaping and stripping harmful content. It provides a filter for untrusted content and disarms potential unwanted scripts from the input. This may be useful to apply to data that is transmitted via HTML forms or otherwise.
How it works
Bleach uses the html5lib for Python and can deal with incorrect HTML code, like badly nested code or missing tags.
Based on the data you received, Bleach can apply a few actions on the code. The first one is to clean code, meaning that it will replace any potential harmful characters or strings. Special characters like < will be replaced into <
. With the linkify function it can turn hyperlinks in text into actual links that are safe and given a related rel attribute.
Usage and audience
Bleach is commonly used for data sanitizing. Target users for this tool are developers.
Tool review and remarks
The review and analysis of this project resulted in the following remarks for this security tool:
Strengths
- + More than 25 contributors
- + More than 1000 GitHub stars
- + The source code of this software is available
Installation
Supported operating systems
Bleach is known to work on Linux.
Bleach alternatives
Similar tools to Bleach:
django-sudo
Django-sudo provides a view decorator for Django web applications. It mimics the behavior of sudo on Linux systems and requires reauthentication.
django-guardian
Django-guardian extends the default Django permissions model. It does this by allowing permissions on each database object, adding fine-grained control.
django-security
Django-security is a toolkit for the Django framework with the focus on security. It provides models, views, and middleware to strengthen the defenses.
This tool page was updated at . Found an improvement? Help the community by submitting an update.
Related tool information
Categories
This tool is categorized as a Django security library, Django security tool, and data sanitizing tool.