A cryptographic hash algorithm is a function which takes a variable size input and produces a fixed size output. The algorithm makes it difficult to predict the output for a given input, find two inputs with the same output, or reconstruct the input from the output.

learn more… | top users | synonyms (1)

6
votes
1answer
283 views

Is SpookyHash vulnerable to HashDoS?

Aumasson, Bernstein and Bosslet did an excellent job demonstrating fatal weaknesses in MurmurHash and CityHash, but what about SpookyHash? My first uneducated guess is that it would be much harder to ...
4
votes
1answer
603 views

Commitment scheme using hash functions

Let's say Alice and Bob are playing a game where Bob is trying to guess a number Alice has chosen. Alice chooses a key $K$ and a number $N$ at random and performs $C=Commit(K, N)$ where $Commit(K, ...
6
votes
4answers
757 views

What is the difference between a hash and a permutation?

As defined by Wikipedia a hash function is [...] any algorithm or subroutine that maps large data sets of variable length to smaller data sets of a fixed length. For example, a person's name, ...
6
votes
4answers
246 views

Could a very long password theoretically eliminate the need for a slow hash?

Before I provide details, I want to clarify that I am not looking to implement this practically, but I'm only asking to get a better understanding. The way I currently understand it, we use slow ...
1
vote
1answer
131 views

Selecting a large NUMS Safe prime

Suppose I want to use the following simple hash function. For a mesage $m$, take some public $a$ and prime $p$ and raise $a^m \bmod p$ (never mind the computational expense of this operation). This ...
0
votes
0answers
61 views

Strength of Combining Hash functions [duplicate]

If I combine two hash functions, what will the impact on the strength of the resulting function. If I combine in following way: H1*H2 (multiply) H1 + H2 (concat) H1 Xor H2 H1 (H2) EDIT: Lets say H1 ...
3
votes
0answers
83 views

Is SHA-1 collision free on data up to 20 bytes long? [duplicate]

Is SHA-1 collision free on data up to 20 bytes long (lenght of hash / internal state)? That means that every input produce unique output, but you surely know that, i just write it in order my question ...
5
votes
2answers
269 views

Is SHA-1 still practical secure under specific scenarios?

It is conjectured that SHA-1 has been broken from the "research" perspective but no in real world. That is that there is an algebraic attack that explores weaknesses on its algrebraic construction. ...
4
votes
1answer
560 views

Are there any practical implementation of a homomorphic hashing or signature scheme?

A homomorphic hash function is a function $H : A \to B$ between two sets with some algebraic structure $(A, *)$ and $(B, \star)$ such that $H$ is collision resistant, i.e. it is hard to find $x \neq ...
2
votes
3answers
339 views

What is the difference between a HMAC and a hash of data?

On a recent question it became apparent that there's a significant difference between an HMAC of input data and a hash of input data. What exactly is the difference between an HMAC and a hash of a ...
8
votes
7answers
577 views

Turning a cipher into a hashing function

This is theoretical question. I'd like to know if it's possible (and what are eventually the consequences), not that I'm going to do it in one of my projects. ;) The first hashing functions created ...
8
votes
2answers
1k views

Why are the constants so simple in Keccak?

Keccak, the construction selected for SHA-3 is very interesting. It seems unlike other primitives and has chosen very simple constants. (Keccak talk PDF) The initial values of the state in Keccak is ...
2
votes
0answers
101 views

How hard is a known prefix hash preimage attack?

Suppose the attacker knows $X, Z$ such that $H(X || Y) = Z$ If bit-length(Y) < 60 then a brute force attack is possible. What if ...
7
votes
1answer
867 views

Can I find two specific words with the same md5 hash?

I want to find two strings containing special words like "yes" or "no", mixed with random characters, for which the MD5 hash is equal. An example of what I'm looking for: ...
8
votes
1answer
1k views

From hash to Cryptographic hash

After reading some excellent papers on SipHash, I understood that good non-cryptographic hashes such as MurmurHash and CityHash are not secure for MAC usage, due to a certain type of DDos attack ...
1
vote
0answers
44 views

Is there a way to analyse xxHash and tell, either by human analysis, or with an automated tool, that this hash function is or is not cryptographic? [duplicate]

After reading some excellent papers on SipHash, I understood that good non-cryptographic hashes such as MurmurHash and CityHash are not secure for Internet usage, due to a certain type of DDos attack ...
2
votes
2answers
1k views

what kind of hash function can provide a short hash and be collision resistant?

When you try to connect via SSH, you see a signature which is short but I heard it is even stronger than sha256. It is perhaps stronger because it uses more rounds. Is there a hash function or a ...
5
votes
2answers
155 views

Can the hash of one message be used to make it easier to find the hash of a very similar message?

Background: I am trying to get an understanding of using a hash of a passphrase as a secret. Example: ...
-1
votes
2answers
204 views

What are alternatives to the random oracle model for modelling hash functions? [closed]

I was looking for more realistic alternatives to the ROM for describing hash functions in theoretical proofs. I came across the common reference string model (where hash functions can be modeled as ...
0
votes
1answer
187 views

Is there a problem with constructing a CSPRNG using MD5 or SHA1?

Is there any security concerns with building a CSPRNG using a broken hash function like MD5 or SHA1? The design is such that a CRC-like function is used for mixing entropy and MD5 is used as the ...
1
vote
1answer
114 views

Trapdoor implementation

Please refer to this secure index paper. On page#6, a trapdoor is defined as ...
1
vote
2answers
276 views

Store hashed email and compare hash values

I have a number of different systems sending me email addresses, but I don't actually need the underlying email, just a hash of the email address. I know I can compare hash values to find matches ...
4
votes
2answers
250 views

Commutativity of keyed hashes

Definition ${H_1}^{K_1}(X)$ means data $X$ hashed by keyed hashing algorithm $H_1$ with key $K_1$. Short question Is $H_1^{K_1}(H_2^{K_2}(X))$ equal to $H_2^{K_2}(H_1^{K_1}(X))$? Is ...
4
votes
1answer
193 views

How do you construct a practical full-domain hash function?

I am looking for practical constructions for Full Domain Hash. I have read Random Oracles are Practical by M. Bellare and P. Rogaway, the construction suggested on page 8, under "Uniformity: a ...
4
votes
1answer
247 views

Why is feed-forward mechanism used in hash functions?

The compression function of SHA-1 when used in Davies-Meyer mode adds its input to the chaining values at the final step. For the first message block, the IV is used as the input and in the next step, ...
1
vote
0answers
42 views

School exercise on untrusted channel comunication [duplicate]

Possible Duplicate: Why is H(k||x) not a secure MAC construction? I've the following problem: two parties, A and B, share a secret key Kab. M is a plaintext message, H an unkeyed hash ...
4
votes
1answer
495 views

Hashing passwords with a salt - why use different salt for everyone?

Given a database where we have usernames and passwords, we want to secure users' passwords by hashing them. We should not use only username and passwords in this hash, as someone having data from ...
-1
votes
1answer
125 views

Cryptographic Primitive Method

Is there any cryptographic primitive bijective (one-to-one and onto) function for creating cryptographic tools like symmetric encryption/decryption, Hash code generator, MAC, HMAC and Random number ...
3
votes
1answer
112 views

Hashing a password with the password?

I was wondering if hashing a password with the password would be a good way of encrypting the password. So, the user must know his/her password to get the same result as the one in the database. Also, ...
3
votes
2answers
356 views

How does using salt reduce rainbow table attack?

I could create a rainbow table for a particular salt value and still create a successful attack similar to one without salt value.
2
votes
1answer
171 views

Finding a collision for a hash function

I'm trying to find a collision for the following (modified) Merkle-Damgard hash function. Suppose we already have a hash function $h : \mathbb{Z}_2^{2·n} \to \mathbb{Z}_2^n$ for fixed length bit ...
0
votes
4answers
432 views

Is the One Time Pad (OTP) considered a cryptographic hash function?

As the title states, would the One Time Pad (OTP) be considered a cryptographic hash function?
4
votes
2answers
272 views

Is it possible to break a hash-based block cipher?

Let's define the following block cipher: $C_n = M_n \oplus H(k + n)$ where $C_n$ is the nth block of ciphertext, $M_n$ is the nth block of plaintext, $H$ is a cryptographic hash function, and $k$ is ...
6
votes
1answer
238 views

How secure is the knapsack?

Can the knapsack be used in cryptography in a secure sense (described below)? Knapsack problem: Given some number $X$ and a set $W$ of weights $w_1, w_2, ... w_n$, find a subset $S$ of $W$ (if it ...
8
votes
2answers
466 views

Why xor the message into the state for sponge hashes?

Sponge hashes like Keccak(SHA-3) and CubeHash, xor a message block into part of the internal state. Why use a reversible operation like xor for that, instead of replacing that part of the state with ...
6
votes
1answer
3k views

Example Rainbow Table Generation

I have read up on rainbow tables and think I understand the idea behind them. However, I find that it would be better for me to actually attempt to implement a (very basic) rainbow table generator in ...
4
votes
2answers
1k views

Difference between symmetric and asymmetric hash function?

The Linux kernel supports symmetric and asymmetric hash functions. E.g. sha1, sha256, ... See tcrypt.c and search for test_hash_speed and ...
5
votes
3answers
286 views

How many bits of hash are realistically needed for key verification?

Say I'm connecting to a web server secured with TLS but with a self-signed certificate. Accordingly, I call the owner of the server and ask him what SHA1 fingerprint he has. He starts reading out the ...
1
vote
0answers
52 views

P-Complete hashes, hashing to a larger set

Historically hashes have been from a large set (say 256 characters) to a smaller set (256 bits). Also, hash functions that are P-complete have no known parallel algorithm; they must be computed ...
2
votes
3answers
358 views

Can one build a one-way function from AES?

We change the AES block cipher encryption: we delete the key schedule algorithm the user now provides a string of 1408 bits we divide the string to 11 sub keys, and use them directly in the ...
3
votes
1answer
201 views

A question regarding relevance of vulnerability of MD5 when linking multiple records together

I have been studying a Supreme Court case "IMS Health vs Sorrel". In this case a Friend of Court brief filled by "Electronic Privacy Information Center" states that use of MD5 hash function to link ...
4
votes
2answers
291 views

Good enough deterministic PRNG based on hashes

Lets say I have a seed named iv which has a decent amount of entropy. Are there any glaring issues with the following? First 64 bytes are generated by SHA512(iv) Next 64 bytes are generated by ...
6
votes
1answer
211 views

Did Merkle invent cryptographic hashing?

Chapter II of Merkle's 1979 PhD thesis is titled "One Way Hash Functions." The chapter appears to be the first reference to cryptographic hashing. The chapter has no references. Is there an earlier ...
5
votes
1answer
954 views

A single password manager vs password generator/hash

I have been wondering about the options available for managing passwords. However, they all seem to fail if the master password is compromised (which isn't a big surprise). On one hand you have ...
13
votes
1answer
6k views

What are the differences between a digital signature, a MAC and a hash?

A message may be accompanied with a digital signature, a MAC or a message hash, as a proof of some kind. Which assurances does each primitive provide to the recipient? What kind of keys are needed?
2
votes
1answer
250 views

Why are protocols often proven secure under the random oracle model instead of a hash assumption?

Is this true that whenever you design a protocol using a hash function, you must prove its security under the random oracle? I mean, is it possible to devise a protocol $P$ using a function $H$, and ...
5
votes
2answers
199 views

Is there any research on the problem of making a number more memorable to humans?

Authentication protocols often rely on humans dealing with large numbers correctly. For example, when a user logs into a remote machine using SSH for the first time, she is prompted to confirm that ...
1
vote
1answer
99 views

Ensuring integrity of a client side script

I want a script that is running on the client to compute a collision resistant hash and send it to a server. I need to ensure that the script which performs this hash is not altered in any malicious ...
4
votes
1answer
381 views

Exhausting the entropy of a hash function

In the case of password storage, consider the following: I have an idea that one can exhaust the entropy of input to the MD5 function by using a 128 bit random value as the password (indeed, any hash ...
4
votes
4answers
313 views

How to prove membership of a list without disclosing the list members?

I'm designing a messaging system where the sender A sends a message m with a signature s to n Receivers. A Receiver Ri should then be able to prove to a Verifier V that he is one of the receivers of ...