Category "django-middleware"

How to return an rest_framework.response object from a django custom middleware class?

I am trying to write a middleware class that ensures that the user is logged in. But the problem is this middleware class will only be applicable to a small set

django - get 'REMOTE_USER' from middleware class

We use kerberos for our authentication. Using request.META['REMOTE_USER'] I am able to get the authenticated user in my views.py however when I move this to