From: Chris H. <ta...@us...> - 2002-12-02 19:33:29
|
Update of /cvsroot/squirrelmail/squirrelmail/functions In directory sc8-pr-cvs1:/tmp/cvs-serv14197 Modified Files: auth.php Log Message: Fixed some E_ALL warnings, should now be E_ALL clean. No new functionality. Index: auth.php =================================================================== RCS file: /cvsroot/squirrelmail/squirrelmail/functions/auth.php,v retrieving revision 1.28 retrieving revision 1.29 diff -u -w -r1.28 -r1.29 --- auth.php 6 Nov 2002 18:55:12 -0000 1.28 +++ auth.php 2 Dec 2002 19:33:23 -0000 1.29 @@ -73,7 +73,7 @@ $result=digest_md5_parse_challenge($challenge); // verify server supports qop=auth - $qop = explode(",",$result['qop']); + // $qop = explode(",",$result['qop']); //if (!in_array("auth",$qop)) { // rfc2831: client MUST fail if no qop methods supported // return false; @@ -120,7 +120,7 @@ returns an array. See the RFC for details on what's in the challenge string. */ $challenge=base64_decode($challenge); - while (strlen($challenge)) { + while (isset($challenge)) { if ($challenge{0} == ',') { // First char is a comma, must not be 1st time through loop $challenge=substr($challenge,1); } @@ -142,7 +142,11 @@ } else { // We're in a "simple" value - explode to next comma $val=explode(',',$challenge,2); + if (isset($val[1])) { $challenge=$val[1]; + } else { + unset($challenge); + } $value=$val[0]; } $parsed["$key"]=$value; |