I have a custom decorator that I implemented to use Duo Push 2FA. Which looks something like this:
views.py
@duo_auth.duo_auth_required
def get_stuff(request):
page = request.GET.get('page', 1)
If it does not meet the requirements it'll bounce you to a page that requires you to authenticate via DUO. And I've gone as far as to decorate all my views with it, but when it comes down to the admin page, I'm not entirely sure how to integrate it there.
urlpatterns = [
url(r'^admin/', admin.site.urls),
Is it possible to add the decorator on the urls pattern?