Click here to Skip to main content
Rate this: bad
Please Sign up or sign in to vote.
See more: C#4.0
i have the below packet of data:
i want to retrieve the below hashcode (32 digit):
Can you provide me with algorithm to generate the 32 bit string?
Thanks in advance
Posted 25-Jun-13 2:14am
Sergey Alexandrovich Kryukov at 25-Jun-13 7:54am
The question makes no sense. What is "retrieve"? You can generate (calculate) hash code, but there many different algorithms, not one.
But, most importantly: you show a string of the length 33 (characters) and call it "32 bit string". You apparently don't know what you want...
CPallini at 25-Jun-13 8:08am
My 5. You even counted the number of characters.
Sergey Alexandrovich Kryukov at 25-Jun-13 10:36am
Thank you, Carlo.
I counted number of characters after I saw it's odd without counting. Sometimes, I sense asymmetry from the first glance...
Sergey Alexandrovich Kryukov at 25-Jun-13 10:44am
And I finally added a real formal answer, please see.
Not sure if OP will get it... :-)
mradelie at 25-Jun-13 8:37am
you right, can you provide me with the algorithm about how to generate hashcode with 32 bit
Sergey Alexandrovich Kryukov at 25-Jun-13 10:37am
As I say, there are many different algorithms. What, you don't care which one? You should just read some literature on the topic.
mradelie at 26-Jun-13 1:22am
can you provide me with the all algorithm that generate a string with 32 bit?
For correction code must be 128822e1bedbd09eaa210670615f4813
Rate this: bad
Please Sign up or sign in to vote.

Solution 1

Please see my comments to the question: there is no one single algorithms.
Also, hash functions are different for different purposes. There are at least two distinct classes of them:[^],[^].
It depends on your purpose, which you did not bother to share with us.
You can learn the algorithms starting from the articles referenced above, but a good number of them are readily available from .NET FCL.
First of all, each and every .NET object of any type has one:[^].
And on the cryptographic side, a number of them are available:[^].
CPallini at 25-Jun-13 11:14am
My 5.
Sergey Alexandrovich Kryukov at 25-Jun-13 16:01pm
Thank you, Carlo.
Rate this: bad
Please Sign up or sign in to vote.

Solution 2

for more clarification:
I have the below packet or data :
i want an algorithm to generate the below code or string (which is 32 bit):
i tried several algorithm using md5,sha1,...
but they generate me other code different then the code that i want.
is there any customisation for md5 algorithm or function to get the code that i want?
Any advice please

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 277
1 Maciej Los 230
2 BillWoodruff 205
3 Sergey Alexandrovich Kryukov 195
4 DamithSL 165
0 OriginalGriff 5,130
1 DamithSL 4,157
2 Maciej Los 3,650
3 Kornfeld Eliyahu Peter 3,460
4 Sergey Alexandrovich Kryukov 2,811

Advertise | Privacy | Mobile
Web01 | 2.8.141216.1 | Last Updated 26 Jun 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100