Skip to main content

Utility functions to prevent possible XSS attack on django/mako templates

Project description

Utilities to prevent possible Cross Site Scripting (XSS) attacks on Django/Mako templates.

Overview

This repo houses utility functions to protect edx codebase (Python, Javascript and other templating engine eg django/mako) against possible XSS attacks. Helper code include html & js escaping filters for django and mako templates. For more information, please read Preventing Cross Site Scripting Vulnerabilities.

Documentation

The full documentation is in the docs directory TODO: Publish to https://xss-utils.readthedocs.org.

License

The code in this repository is licensed under the AGPL 3.0 unless otherwise noted.

Please see LICENSE.txt for details.

How To Contribute

Contributions are very welcome.

Please read How To Contribute for details.

PR description template should be automatically applied if you are sending PR from github interface; otherwise you can find it it at PULL_REQUEST_TEMPLATE.md

Issue report template should be automatically applied if you are sending it from github UI as well; otherwise you can find it at ISSUE_TEMPLATE.md

Reporting Security Issues

Please do not report security issues in public. Please email security@openedx.org.

Getting Help

Have a question about this repository, or about Open edX in general? Please refer to this list of resources if you need any assistance.

Change Log

Unreleased

[0.8.0] - 2025-04-17

  • Add support for django 5.2.

[0.7.1] - 2025-02-28

  • Fix to PyPI publishing workflow.

[0.7.0] - 2025-02-28

  • Drop support for Python 3.8

[0.6.0] - 2024-04-22

  • Test and declare Python 3.11 and 3.12 compatibility.

[0.5.0] - 2023-08-01

[0.4.0] - 2022-01-20

Added

  • Added Support for Django40

Dropped

  • Dropped Django22, 30, 31 from CI

[0.3.0] - 2021-07-07

Added

  • Support for django3.0, 3.1, 3.2

[0.1.0] - 2018-08-17

Added

  • Utilities to enable html escaping, preventing Cross Site Scripting (XSS) attacks in Django templates.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

xss_utils-1.0.0.tar.gz (21.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

xss_utils-1.0.0-py2.py3-none-any.whl (17.4 kB view details)

Uploaded Python 2Python 3

File details

Details for the file xss_utils-1.0.0.tar.gz.

File metadata

  • Download URL: xss_utils-1.0.0.tar.gz
  • Upload date:
  • Size: 21.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for xss_utils-1.0.0.tar.gz
Algorithm Hash digest
SHA256 764d9928e0c6a296301b38b4f7bc35179b4d8547895003144f1ad4eba6338c58
MD5 9680ce2afd450b0657c7a111451342f6
BLAKE2b-256 8ad5c47cd77c767385e926b4479c462cad8fadb0022dae5289e4eec8e74e2db4

See more details on using hashes here.

File details

Details for the file xss_utils-1.0.0-py2.py3-none-any.whl.

File metadata

  • Download URL: xss_utils-1.0.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 17.4 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for xss_utils-1.0.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 3390237698804473d4560353327102a8159e5770901b60e631d4ed8f74887bd9
MD5 93a1b9d9a2b3a40b17cbf56ead74c25a
BLAKE2b-256 29688fe19515f50f26f619471b65b71cc66da68c1996690bc44bbde597dfae0f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page