On Saturday 09 November 2002 02:40, [EMAIL PROTECTED] wrote: > Can anyone duplicate the following problem?
Yes. > In Admin (VAdmin 1.0.2) go to the user details, and set 'Expiry' date to > any number. Now try logging in as that user. I am getting 'Unknown user or > password' error. > > As far as I understand the above function, it is to expire user accounts > in 'N' number of days. Am I wrong? You're correct. There's a bug in VAdmin 1.0.2. Basically, when setting and retrieving the expire time it was doing so relative to the unix epoch when in fact it should be relative to the current time. To fix it: Edit chattrs.mod, Line 177 Change from: $repl = vchattr($VADMIN_DOMAIN, $secret, $userid, "EXPIRY", $ExpiryTimeSec); To: $repl = vchattr($VADMIN_DOMAIN, $secret, $userid, "EXPIRY", $ExpiryTimeSec + time()); Edit getuser.mod, Line 33 Change from: if ($user_ary[10]!="-") $ExpiryTime=intval($user_ary[10]/(60*60*24)); To: if ($user_ary[10]!="-") $ExpiryTime=intval(($user_ary[10] - time())/(60*60*24)); ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf -- squirrelmail-users mailing list List Address: [EMAIL PROTECTED] List Archives: http://sourceforge.net/mailarchive/forum.php?forum_id=2995 List Info: https://lists.sourceforge.net/lists/listinfo/squirrelmail-users
