Skip to main content

An advanced honeypot for Django

Project description

django-admin-honeypot-advanced is an honeypot for the Django framework admin page with the following features:

  • A first fake login page combined with Hashcash, so that each login attempt requires a proof-of-work that will consume computation resources of attackers.

  • A second fake login page again combined with Hashcash and affected by a Blind SQL Injection flaw, the exploitation of which requires enormous computational resources of attackers and would anyhow reveal data from an in-memory database comprising only fake credentials. Additionally, such fake credentials are made of hashed password taken from the famous rockyou list, so to deceive attackers and let them waste more computational resources in the attempt to break such hashes.

  • An endpoint affected by path traversal and pointing to a fake filesystem replicating the structure of Docker containers, so to induce attackers to believe the app is running in a misconfigured Docker container exposing sensible files like /etc/passwd and /etc/shadow. Such credential files contain password hashes that may deceive attackers and waste their computational resources.

  • A custom 404 page that returns the HTTP status code 200 and include random invisible content, so that non-existent URIs are associated with less predictable pages in the aim to make URIs bruteforcing harder.

The honeypot is a fork of Derek Payton’s django-admin-honeypot

Author: Daniele Salimonti

Version: 1.0.1

License: MIT

Documentation

tl;dr

  • Install django-admin-honeypot from PyPI:

    pip install django-admin-honeypot-advanced
  • Add admin_honeypot to INSTALLED_APPS

  • Update your urls.py:

    urlpatterns = [
        ...
        path('admin/', include('admin_honeypot.urls', namespace='admin_honeypot')),
        path('secret/', admin.site.urls),
    ]
    
    handler404 = 'admin_honeypot.views.handler404'
  • Run python manage.py migrate

NOTE: replace secret in the url above with your own secret url prefix

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

django-admin-honeypot-advanced-1.0.1.tar.gz (23.7 kB view details)

Uploaded Source

Built Distribution

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

django_admin_honeypot_advanced-1.0.1-py2.py3-none-any.whl (38.1 kB view details)

Uploaded Python 2Python 3

File details

Details for the file django-admin-honeypot-advanced-1.0.1.tar.gz.

File metadata

File hashes

Hashes for django-admin-honeypot-advanced-1.0.1.tar.gz
Algorithm Hash digest
SHA256 ece1f580d80f2906cdbdb05e4beb9c30680cae231d250d389100711abc823d05
MD5 d244ce3d623fae1b22f5506f483b5787
BLAKE2b-256 84318064a0e3ba57e406cc388c834e236b97cefe46fd81c23bb8cb3b0529d539

See more details on using hashes here.

File details

Details for the file django_admin_honeypot_advanced-1.0.1-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for django_admin_honeypot_advanced-1.0.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 88abba49b78ab88661d160bdfabaaceb222ff79a653165694d99406d6a379538
MD5 648ba320a2bbb6006b238b5d343bc707
BLAKE2b-256 4ba7221864e650ba610d43a73cb04a44005cd66a3aa7b154b52f6ebea31599c9

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