Skip to main content

A library used to stop your website from being attacked.

Project description

xss-shield

A Python library to prevent your website from being attacked.

PyPI

PyPI - Downloads PyPI - Python Version PyPI - Wheel GitHub top language

Installing

Type command:

$ pip install xss-shield

Usage

Function excape(s: str, strict=True)

Arguments

s: the string to parse

strict: if strict = False -> only replace <script> tag

example:

import xss_shield

unsafe_str = '<script>alert("Bad.");</script>'
safe_str = xss_shield.escape(unsafe_str)

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_shield-1.0.1.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

xss_shield-1.0.1-py3-none-any.whl (2.7 kB view details)

Uploaded Python 3

File details

Details for the file xss_shield-1.0.1.tar.gz.

File metadata

  • Download URL: xss_shield-1.0.1.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.10.5

File hashes

Hashes for xss_shield-1.0.1.tar.gz
Algorithm Hash digest
SHA256 4ac444d1c4abbd132f30d5a5ce6508c3695db02585127c1e9a28e38e42d212bd
MD5 70b4e7bab9a3f0611b392f05db5e25b2
BLAKE2b-256 36f76cfc87e3139bc82debec29a0021f06a4e587628ff18711187a0f5d00c209

See more details on using hashes here.

File details

Details for the file xss_shield-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: xss_shield-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 2.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.10.5

File hashes

Hashes for xss_shield-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d32c038dbbcf56d77b849c172315e7be8e76ab2df932f72fec53fb8d515dfe62
MD5 fef9c16da4f1cf6bec4d220fee85fe58
BLAKE2b-256 181e13ef267c477cee2944cce11185e006924cecfeb8a8b38c53d4bd00a76963

See more details on using hashes here.

Supported by

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