From be2242635f089b2c73e8b8b69edee9386cce9137 Mon Sep 17 00:00:00 2001 From: Michel Blockelet Date: Mon, 8 Mar 2010 14:00:51 +0100 Subject: [PATCH] [gestion/chgpass.py] cracklib to lowercase Maintenant il repond "OK" au lieu de "ok" ... darcs-hash:20100308130051-ddb99-fbb963cdce5d0a94024ac8244cc1fb49395b1a92.gz --- gestion/chgpass.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gestion/chgpass.py b/gestion/chgpass.py index 5830bcb0..d5096c23 100644 --- a/gestion/chgpass.py +++ b/gestion/chgpass.py @@ -104,7 +104,7 @@ Il ne doit pas être basé sur un mot du dictionnaire.""", 'jaune') ## 4 - Cracklib test = commands.getoutput("echo '%s' | /usr/sbin/cracklib-check" % mdp) - if test.split(':')[-1] != ' ok' : + if test.split(':')[-1].lower() != ' ok' : commentaire = { ' it does not contain enough DIFFERENT characters': u'Il y a trop de caractères identiques.' , ' it is based on a dictionary word': u'Le mot de passe est basé sur un mot du dictionnaire' ,