Skip to main content

Protect against bots and DDoS attacks

Project description

flask-Humanify

A strong bot protection system for Flask with many features: rate limiting, special rules for users, web crawler detection, and automatic bot detection.

Github PyPI Libraries.io


from flask import Flask
from flask_Humanify import Humanify

app = Flask(__name__)
humanify = Humanify(app)

@app.route("/")
def index():
    """
    A route that is protected against bots and DDoS attacks.
    """
    if humanify.is_bot:
        return humanify.redirect_to_access_denied()
    return "Hello, Human!"

if __name__ == "__main__":
    app.run()

Installation

Install the package with pip:

pip install flask-Humanify

Import the extension:

from flask_Humanify import Humanify

Add the extension to your Flask app:

app = Flask(__name__)
humanify = Humanify(app)

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

flask_humanify-0.1.0.tar.gz (19.3 kB view details)

Uploaded Source

Built Distribution

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

flask_humanify-0.1.0-py3-none-any.whl (19.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: flask_humanify-0.1.0.tar.gz
  • Upload date:
  • Size: 19.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for flask_humanify-0.1.0.tar.gz
Algorithm Hash digest
SHA256 78e7cf498fcde7f5add9f560155db4b750bb48c05c628e73c356bc1c24a74aef
MD5 468c87ce631c77a215f5a0a14ea79511
BLAKE2b-256 466bcbdf0be954d095ddeffb71e9649398cdeff87db0bb1d4fe24db1a6331147

See more details on using hashes here.

File details

Details for the file flask_humanify-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: flask_humanify-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 19.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for flask_humanify-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2314f7d9aa9da8b0fa056827e0dd990c6eadcdd9df943d00e4b1ce3f734ae172
MD5 5bb1059720e6a9244288a8978883b741
BLAKE2b-256 9d58f65bc51f545458ef06f5d08b615b15a5e958b52087a4c8a3fb66ef090b0f

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