Re: Fwd: Proper VARIANT to use for System.Security.Cryptography.RNGCryptoServiceProvider?
| From: | Pierre Joye | Date: | Tue, 20 Oct 2015 10:44:03 +0000 |
| Subject: | Re: Fwd: Proper VARIANT to use for System.Security.Cryptography.RNGCryptoServiceProvider? | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-88882@lists.php.net to get a copy of this message | ||
Hi,
On Oct 19, 2015 9:52 PM, "Scott Arciszewski" <scott@paragonie.com> wrote:
>
> Okay, I've tried both windows@lists.php.net and
> php.windows@lists.php.net and I give up trying there.
>
> ------
>
> Since CAPICOM is deprecated, for users without ext/mcrypt or
> ext/openssl, I'd like random_compat to work on Windows 7 and later.
>
> $rng = new DOTNET(
> 'mscorlib',
> 'System.Security.Cryptography.RNGCryptoServiceProvider'
> );
> $variant = new Variant($mystery_one, $mystery_two);
> $bytes = $rng->GetBytes($variant);
>
> Can anyone tell me what to use for $mystery_one and $mystery_two? I
> can't make heads or tails of ext/com_dotnet in php-src.
>
> References:
>
>
http://stackoverflow.com/questions/6497670/calling-rngcrypto-from-coms-dotnet-class-from-php
> https://github.com/paragonie/random_compat/issues/67
>
http://community.sitepoint.com/t/php-and-net-secure-rndnum-generation-using-dotnet-class/86511
>
> Scott Arciszewski
> Chief Development Officer
> Paragon Initiative Enterprises <https://paragonie.com>
Why not rely on openssl? Which uses the windows c-rng?
I do not consider dotnet anywhere close to stable now, and almost never
available.
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>