Skip to main content

Django middleware to capture current request and user.

Project description

Build Status PyPI Version PyPI License Python Versions Django Versions Read the Docs

Django-CRUM

Django-CRUM (Current Request User Middleware) captures the current request and user in thread local storage.

It enables apps to check permissions, capture audit trails or otherwise access the current request and user without requiring the request object to be passed directly. It also offers a context manager to allow for temporarily impersonating another user.

It provides a signal to extend the built-in function for getting the current user, which could be helpful when using custom authentication methods or user models.

Documentation can be found at RTFD.

It is tested against:
  • Django 1.11 (Python 3.5 and 3.6)

  • Django 2.0 (Python 3.5, 3.6 and 3.7)

  • Django 2.1 (Python 3.5, 3.6 and 3.7)

  • Django 2.2 (Python 3.5, 3.6, 3.7, 3.8 and 3.9)

  • Django 3.0 (Python 3.6, 3.7, 3.8 and 3.9)

  • Django 3.1 (Python 3.6, 3.7, 3.8 and 3.9)

  • Django master/3.2 (Python 3.6, 3.7, 3.8 and 3.9)

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-crum-0.7.9.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

django_crum-0.7.9-py2.py3-none-any.whl (4.7 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file django-crum-0.7.9.tar.gz.

File metadata

  • Download URL: django-crum-0.7.9.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.0

File hashes

Hashes for django-crum-0.7.9.tar.gz
Algorithm Hash digest
SHA256 65e9bc0f070a663fafc4d9e357f45fd4e6f01838b20a9e2fb7670f5706754288
MD5 1a4e40aa27039fa2721ff88b8d53ab29
BLAKE2b-256 341dc56588f67130aeef8828e47535e8551337d2ae02f91f1414da61bc5e49fb

See more details on using hashes here.

File details

Details for the file django_crum-0.7.9-py2.py3-none-any.whl.

File metadata

  • Download URL: django_crum-0.7.9-py2.py3-none-any.whl
  • Upload date:
  • Size: 4.7 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.51.0 CPython/3.8.0

File hashes

Hashes for django_crum-0.7.9-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 037cc8b822975bb1d41cd24269b59a512cc77448fadc3f34ab9a17b229b4b471
MD5 365784792117f1150dcfd4644587945e
BLAKE2b-256 cdf98fad70a3bd011a6be7c5c6067278f006a25341eb39d901fbda307e26804c

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