Skip to main content

Django middleware to capture current request and user.

Project description

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.

It is tested against:
  • Django 1.4.10 (Python 2.6 and 2.7)
  • Django 1.5.5 (Python 2.6, 2.7, 3.2 and 3.3)
  • Django 1.6.1 (Python 2.6, 2.7, 3.2 and 3.3)
  • Django master (Python 2.7, 3.2 and 3.3)

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
django-crum-0.6.1.tar.gz (4.2 kB) Copy SHA256 hash SHA256 Source None Jan 20, 2014

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page