Re: Upgrading Encryption to .Net not Working!!!!!!!
From: TC (getmyemails2_at_yahoo.com)
Date: 04/25/05
- Next message: J'son: "Creating User Accounts with or without Active Directory"
- Previous message: William Stacey [MVP]: "Re: IsAuthenticated property on IIdentity interface"
- In reply to: swat: "Re: Upgrading Encryption to .Net not Working!!!!!!!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Mon, 25 Apr 2005 13:36:54 -0400
Hey Swat,
That was one thought I had. As it turns out, below is what I needed:
string encrypted=
System.Web.Security.FormsAuthentication.HashPasswordForStoringInConfigFile(passWord,"md5");
Regards,
TC
"swat" <loka_1999@yahoo.com> wrote in message
news:1114438291.499174.280750@o13g2000cwo.googlegroups.com...
> Your VB code is returning the hash in hex, while your C# code is
> returning it as a Base64 encoded string.
>
> Try this:
> -------------------------
> StringBuilder hexVal = new StringBuilder();
> foreach (byte b in bytHash)
> {
> hexVal.Append(b.ToString("X"));
> }
> -------------------------
>
> return hexVal.ToString() instead of Convert.ToBase64String(bytHash)
>
>
> HTH
>
- Next message: J'son: "Creating User Accounts with or without Active Directory"
- Previous message: William Stacey [MVP]: "Re: IsAuthenticated property on IIdentity interface"
- In reply to: swat: "Re: Upgrading Encryption to .Net not Working!!!!!!!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|