Hi Larrson,

Truncated Hashing. See
http://www.codeproject.com/useritems/InstallationID.asp. In a
nutshell, grab the entire hash from the obhect, then extract bytes[0 -
4].

As for the integer conversion, look the the Integer class ctors.

Jeff

On 11/9/07, Larrson <[EMAIL PROTECTED]> wrote:
>
> Hi all,
>
> I've got lost a bit. Could anyone tell me how to derive only 5 first
> bytes from the result of SHA calculation:
>
> SHA1 hash;
> byte digest[ SHA1::DIGESTSIZE ];
> hash.CalculateDigest( digest, (byte *) (LPCTSTR)UserName,
> UserName.GetLength() );
>
> and change them into Integer value for further calculations?
>
> Regards,
> L.
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [EMAIL PROTECTED]
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.
-~----------~----~----~----~------~----~------~--~---

Reply via email to