*nB&O!fl6|H-7S/!odD_ R'\qum'I{_T)D}OCa:Ea -U!\b),Zu?Bz10@/HJ~( .A4X";xR"_OkKg1P_BNH b0x0\mTf8{{\^MQo'{\{ X*!,[\$;nm}zHh#VV]WG &y*p*IFjP}\_`$3wmX~~ sFSGQo(DzzKdit\v;b0vfAx_bY\veVPF6 example: passwd.php?l=30&a=lsd l = length a = alphabet (d = digits [0-9]; h = hex digits [A-F]; l = lower case [a-z]; u = upper case [A-Z]; s = special (see source code)) s = seed (don't use it unless you really know what you're doing) --------------------------- and here comes the code: ?@[\\]^_`{|}~'; // s $alphabet= ''; $mode = $_GET['a']; if(stripos($mode, 'd') !== FALSE) $alphabet .= $digits; if(stripos($mode, 'h') !== FALSE) $alphabet .= $hex_dig; if(stripos($mode, 'l') !== FALSE) $alphabet .= $lower_c; if(stripos($mode, 'u') !== FALSE) $alphabet .= $upper_c; if(stripos($mode, 's') !== FALSE) $alphabet .= $special; if($alphabet == '') $alphabet = $digits . $lower_c . $upper_c . $special; function make_seed() { list($usec, $sec) = explode(' ', microtime()); return (float) $sec + ((float) $usec * 100000); } mt_srand($_GET['s']?$_GET['s']:make_seed()); $len=$_GET['l']>0?$_GET['l']:20; for($n;$n<10;++$n) { for($i=$len;$i;--$i) echo $alphabet[mt_rand(0, strlen($alphabet)-1)]; echo "\n"; } ?> example: passwd.php?l=30&a=lsd l = length a = alphabet (d = digits [0-9]; h = hex digits [A-F]; l = lower case [a-z]; u = upper case [A-Z]; s = special (see source code)) s = seed (don't use it unless you really know what you're doing) --------------------------- and here comes the code: