.NET Framework - Generate PasswordSalt 128

Asked By JuanPuebl on 10-Oct-07 07:47 PM
I am trying to execute the procedure aspnet_Membership_CreateUser but I do not
know how to generate the parameter PasswordSalt nvarchar(128).

Thanks




Vadym Stetsiak replied on 11-Oct-07 07:30 AM
Hello, Juan!

To generate random value you can use RNGCryptoServiceProvider class from
.NET BCL.
This class returns binary data (byte[]), which can be converted to base64 or
simple hex

--
With best regards, Vadym Stetsiak.
Blog: http://vadmyst.blogspot.com


You wrote  on Wed, 10 Oct 2007 16:47:00 -0700:

JP> I'm trying to execute the procedure aspnet_Membership_CreateUser but
JP> I don't  know how to generate the parameter PasswordSalt
JP> nvarchar(128).

JP> Thanks