Fix: When using a disabled user, web service must be forbidden

This commit is contained in:
Laurent Destailleur 2012-03-20 17:18:20 +01:00
parent 6d7aba45de
commit c0013a4581

View File

@ -65,6 +65,12 @@ function check_authentication($authentication,&$error,&$errorcode,&$errorlabel)
$errorcode='BAD_CREDENTIALS'; $errorlabel='Bad value for login or password';
}
if (! $error && $fuser->statut == 0)
{
$error++;
$errorcode='ERROR_USER_DISABLED'; $errorlabel='This user has been locked or disabled';
}
// Validation of login
if (! $error)
{