Questions tagged [hashing]

A hash function is any algorithm that maps data of arbitrary length to data of a fixed length. The values returned by a hash function are called hash values, hash codes, hash sums, checksums or simply hashes. From Wikipedia: http://en.wikipedia.org/wiki/Hash_function

A hash function is any algorithm that maps data of arbitrary length to data of a fixed length. The values returned by a hash function are called hash values, hash codes, hash sums, checksums or simply hashes. Recent development of internet payment networks also uses a form of 'hashing' for checksums, and has brought additional attention to the term.

From wikipedia: hash function

162 questions
44
votes
6 answers

Is it more secure to hash a password multiple times?

I've read a few times that when storing passwords, it's good practice to 'double hash' the strings (eg. with md5 then sha1, both with salts, obviously). I guess the first question is, "is this actually correct?" If not, then please, dismiss the rest…
Narcissus
  • 667
5
votes
4 answers

Concept behind SHA-1 Checksum

What's the basis behind SHA-1 or SHA-2 or other Checksum algorithms? I read about it here http://en.wikipedia.org/wiki/SHA-1#Data_Integrity But I am still wondering about an answer in a layman's language. Can I understand it as a very, very…
Vishwas
  • 1,871
3
votes
0 answers

Hashing algorithm without the avalanche effect

I know that one of the most important features of hashing algorithms, is that minor changes in the input should reflect great change in the hash itself (the avalanche effect), but I'm currently searching for a solution that doesn't implement…
Daniel
  • 236
3
votes
0 answers

Is the Rabin fingerprinting scheme with a random polynomial a universal hash function family?

Say I have a greater-than-expected number of collisions in my hash table that has 2^w buckets (half of them empty). So I pick a fresh new random CRC polynomial that generates w-bit check values (i.e., a w+1 bit value with the high bit and the low…
David Cary
  • 1,462
2
votes
1 answer

What are Hash Functions?

I am trying to read up on System Design, and several articles talk about how a Primary Key for the input data, which is a string, can be passed into a Hash function and we get a number. This can eventually be used in consistent hashing, or other…
Ufder
  • 209
2
votes
1 answer

Hashing a tuple of maximum-valued integers

I'm considering a hash function for a tuple of and maximum-valued integers for example (3 ,2, 5 ) -- where each element of the tuple has some maximum value N. My plan is to treat the elements of the tuple as the digits of a number in base N, so that…
Olumide
  • 251
1
vote
1 answer

Max number of items mapped to same location in hashmap

I have a question about hashmaps. If you have this hashmap with m slots, and need to map n items to it, and n > m. There will be collisions for sure. But assuming there is simple uniform hashing assumption, this means that the maximum amount of…
omega
  • 139
0
votes
1 answer

Combine Multiple Minimal Perfect Hashing

I'm building some Minimal Perfect Hash from multiple datasets using the CHD algorithm I would like to know if there exists a "smart" way to combine all the different MPH obtained from previous steps and use them to build a new one at minimal cost.
jeremie
  • 153
  • 4
0
votes
0 answers

Partition stream of data between n servers, with m duplicates

I'm partitioning a stream of input data between n servers. The simple way of doing it is to use the hash of some property of each input data packet to assign a single server, using mod or similar, and be done with it. However, I want some degree of…
thecoop
  • 529
0
votes
1 answer

Hash function for progressive changes

I am looking for a hashing algorithm that works like this. I start with a text file, and compute its hash. Now I know that I will remove one character at, say, position 67 and this character is a "m", and I would like to compute the new hash without…
0
votes
2 answers

How do crackers determine number of iterations of a Hashing algorithm?

Does a cracker need to know the number of iterations a hashing algorithm uses to compute a hash? If they don't know it, how do they figure it out? How much longer does it take to figure it out, than if they didn't know? I can only guess that they…
TruthOf42
  • 762
-1
votes
1 answer

Is this no-collision-type hash algorithm safe?

I've designed a hash algorithm based on mathematical exponentiation, exponentiating each number by its following number. To be able to exponentiate indefinitely, numbers are first normalized to a 0-1 range. Then, to preserve the ordering…
-3
votes
2 answers

Which is the best hash algorithm considering uniqueness and slowness

I couldn't find an answer, so let's try here... I thought a bit about security and came to the conclusion, that the used hash algorithm should be as slow as possible, to slow potential attackers. (Slow means like ~1.5s). I don't want to use multiple…
-5
votes
6 answers

(closed) Why do we bother hashing data?

I don't understand why we hash data like passwords. I know it's harder to steal hashed data rather than just plain text, and it takes longer, but once one of those public hashing methods gets cracked, lots of that data's gonna be stolen. And by the…