Skip to main content

A library that returns naughty strings from an offline database of Big List of Naughty Strings & emojis

Project description

https://badge.fury.io/py/naughty-string-validator.svg https://travis-ci.org/shashikumarraja/naughty_string_validator_python.svg?branch=master https://coveralls.io/repos/github/shashikumarraja/naughty_string_validator_python/badge.svg?branch=master Updates Python 3

A python library that returns naughty strings from an offline database of Big List of Naughty Strings and emojis. The db will be continuously growing with each release.

The Big List of Naughty Strings is an evolving list of strings which have a high probability of causing issues when used as user-input data.

This library can be inluded in the test automation framework for API, UI, or DB testing to validate them against naughty strings.

Installation

pip install naughty_string_validator

Usage

from naughty_string_validator import *
  • To get a random naughty string from the list

print(get_random_naughty_string())

#output
"<a href=\"\\xE2\\x80\\x88javascript…(1)\" id=\"fuzzelement1\">test</a>"
  • To get entire naughty string list

print(get_naughty_string_list())

#output
["", "undefined", "undef", "null", "NULL", "(null)", "nil", ]
  • To get a random emoji from the emoji list

print(get_random_emoji())

#output
"😃"
  • To get a entire emoji list

print(get_emoji_list())

#output
["😀", "😃", "😄", "😁", "😆", "😅", "😂", "🤣", "☺️", "😊", ]

Tests

  • To run tests

    py.test –cov=naughty_string_validator test/ –verbose

Documentation

The full documentation is at http://naughty_string_validator_python.rtfd.org.

History

0.1.0 (2013-07-10)

  • First release on PyPI.

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

naughty_string_validator-0.1.0.tar.gz (40.8 kB view details)

Uploaded Source

File details

Details for the file naughty_string_validator-0.1.0.tar.gz.

File metadata

  • Download URL: naughty_string_validator-0.1.0.tar.gz
  • Upload date:
  • Size: 40.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/39.1.0 requests-toolbelt/0.8.0 tqdm/4.25.0 CPython/2.7.15

File hashes

Hashes for naughty_string_validator-0.1.0.tar.gz
Algorithm Hash digest
SHA256 a9e81238dda6783c2097883f3d3c6f6141749c10088cd5b3f4115a0281bb8d6f
MD5 13d411b464813d12c552f530663b5e8f
BLAKE2b-256 fdb89b1295bf6d7052293abfa05677b28d67a35d66547a7bdc4f8ca0c314ab47

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