From 11ee7bc2336c919b58ee6ee6ab4937ed44cf5135 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Israel=20Saeta=20P=C3=A9rez?= Date: Mon, 12 Jun 2017 17:53:12 +0200 Subject: [PATCH] Doc: `BasicAuthenticationDefender` should precede other auth classes (#80) --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index fcaee5c..2ab9f2f 100644 --- a/README.md +++ b/README.md @@ -354,7 +354,7 @@ Adapting to other authentication method -------------------- `defender` can be used for authentication other than `Django authentication system`. -E.g. if `django-rest-framework` authentication has to be protected from brute force attack,custom authentication method can be implemented. +E.g. if `django-rest-framework` authentication has to be protected from brute force attack, a custom authentication method can be implemented. There's sample `BasicAuthenticationDefender` class based on `djangorestframework.BasicAuthentication`: @@ -431,7 +431,7 @@ class BasicAuthenticationDefender(BasicAuthentication): ``` -To make it works add `BasicAuthenticationDefender` to `DEFAULT_AUTHENTICATION_CLASSES` in your `settings.py`. +To make it works add `BasicAuthenticationDefender` to `DEFAULT_AUTHENTICATION_CLASSES` above all other authentication methods in your `settings.py`. Running Tests =============