From dc83766b5c1f0080b5c038a6727eb76378d54c2f Mon Sep 17 00:00:00 2001 From: Gabriel Detraz Date: Thu, 10 Jan 2019 16:10:43 +0100 Subject: [PATCH] Case insensitive search --- freeradius_utils/auth.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/freeradius_utils/auth.py b/freeradius_utils/auth.py index e605aea5..0e83b610 100644 --- a/freeradius_utils/auth.py +++ b/freeradius_utils/auth.py @@ -289,7 +289,7 @@ def check_user_machine_and_register(nas_type, username, mac_address): Renvoie le mot de passe ntlm de l'user si tout est ok Utilise pour les authentifications en 802.1X""" interface = Interface.objects.filter(mac_address=mac_address).first() - user = User.objects.filter(pseudo=username).first() + user = User.objects.filter(pseudo__iexact=username).first() if not user: return (False, u"User inconnu", '') if not user.has_access():