Category "django-middleware"

Django middleware to check ios/android app version using request header

I have an app for both Android and iOS platforms which their backend is written with Django and Django-rest-framework . I've been asked to check header of reque

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