Menu

#2 DOTNET seems to return zeros only

open
nobody
None
5
2011-10-12
2011-10-12
No

Lines 216 and after:

$csp = new DOTNET("mscorlib", "System.Security.Cryptography.RNGCryptoServiceProvider");
$array = array_fill(0, $length, null);
$variant = new VARIANT($array, VT_ARRAY | VT_UI1);
$csp->GetBytes($variant);
unset($csp);
return (binary) implode('', $array);

seems to me that we have random bytes in $variant but returned is $array (which still contains zeros only)

Discussion


Log in to post a comment.