From 9510e96da647a5cc2ba6bab381f0df86a3a7db8b Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Wed, 16 Apr 2014 07:47:56 -0400 Subject: [PATCH] [1.6.x] Added a note regarding django.contrib.auth.authenticate. Thanks Josh Brown for the suggestion. Backport of ae5b662796 from master --- docs/topics/auth/default.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/topics/auth/default.txt b/docs/topics/auth/default.txt index 40c81f2e14..f8dc1afb6c 100644 --- a/docs/topics/auth/default.txt +++ b/docs/topics/auth/default.txt @@ -137,6 +137,16 @@ Authenticating Users # the authentication system was unable to verify the username and password print("The username and password were incorrect.") + .. note:: + + This is a low level way to authenticate a set of credentials; for + example, it's used by the + :class:`~django.contrib.auth.middleware.RemoteUserMiddleware`. Unless + you are writing your own authentication system, you probably won't use + this. Rather if you are looking for a way to limit access to logged in + users, see the :func:`~django.contrib.auth.decorators.login_required` + decorator. + .. _topic-authorization: Permissions and Authorization