/[LeafOK_CVS]/fenglin/lib/passwd.inc.php
ViewVC logotype

Diff of /fenglin/lib/passwd.inc.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.4 by sysadm, Wed Apr 23 05:13:57 2025 UTC Revision 1.6 by sysadm, Tue Apr 29 11:55:32 2025 UTC
# Line 19  function verify_pass_complexity($passwor Line 19  function verify_pass_complexity($passwor
19          for ($i = 0; $i < $len; $i++)          for ($i = 0; $i < $len; $i++)
20          {          {
21                  $c = $password[$i];                  $c = $password[$i];
22                    
23                  if (is_numeric($c))                  if (is_numeric($c))
24                  {                  {
25                          $num_count++;                          $num_count++;
# Line 54  function gen_passwd($len) Line 54  function gen_passwd($len)
54              $num = mt_rand(0, 61);              $num = mt_rand(0, 61);
55              $str .= chr($num < 10 ? (ord("0") + $num) : ($num < 36 ? (ord("A") + $num - 10) : (ord("a") + $num - 36)));              $str .= chr($num < 10 ? (ord("0") + $num) : ($num < 36 ? (ord("A") + $num - 10) : (ord("a") + $num - 36)));
56          }          }
57            
58          return $str;          return $str;
59  }  }
   
 ?>  


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1