# Tag Info

Accepted

### Has SHA256 been broken by Treadwell Stanton DuPont?

[Update, 2019-09-12: Upon being exposed, and/or after taking advantage of market manipulation by their fraudulent announcements, the scam artists of Treadwell Stanton DuPont have retracted their claim,...

### How do hashes really ensure uniqueness?

The simple answer is that hashes don't ensure uniqueness. Very broadly, hashes behave like "deterministic random numbers" – deterministic in the sense that hashing the same data always ...
• 1,211
Accepted

### SHA-512 faster than SHA-256?

This isn't necessarily unexpected. 32-bit platforms vs 64-bit platforms can make a significant difference, as well as the amount of data you're hashing. ...
• 10.7k

### Cryptography algorithms that take longer to solve on a GPU than a CPU

This specific situation is a central part of the analysis of password hashing functions. Indeed, for hashing a password, we want a function which is: slow in a tunable way; such that the most cost-...
• 84.8k
Accepted

### How can hashes be unique if they are limited in number?

how can for example SHA-256 be unique if there is only a limited number of them?! Where your issue occurs is that they're not unique. It's just very improbable that they'll reoccur. Unique in ...
• 14k
Accepted

### How does hashing twice protect against birthday attacks?

A collision in any hash function gives a collision in a "squared" variant of the hash function. This is easy to see. If hash(x)==hash(y), then hashing the outputs ...
• 37.8k

### SHA-512 faster than SHA-256?

SHA-512 has 25% more rounds than SHA-256. On a 64-bit processor each round takes the same amount of operations, yet can process double the data per round, because the instructions process 64-bit words ...
• 12.7k
Accepted

### SHA-256 hash of null input?

The result of SHA-256 of an empty string is: e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 Accordingly to this and this
• 6,369
Accepted

### What is the difference between SHA-3 and SHA-256?

The main differences between the older SHA-256 of the SHA-2 family of FIPS 180, and the newer SHA3-256 of the SHA-3 family of FIPS 202, are: Resistance to length extension attacks. With SHA-256, ...
Accepted

### Key size for HMAC-SHA256

Short answer: 32 bytes of full-entropy key is enough. Assuming full-entropy key (that is, each bit of key is chosen independently of the others by an equivalent of fair coin toss), the security of ...
• 125k

### Has SHA256 been broken by Treadwell Stanton DuPont?

This is firmly in "put up or shut up" territory. It's easy to prove this claim. I will provide them with a string and its hash. They must provide a collision. They could also mine bitcoin and earn a ...

### Is it easy to crack a hashed phone number?

No, it is not a good idea to hash phone numbers. There are only a limited number of phone numbers, so it is pretty easy for an adversary to try and hash all of them. Then you can simply compare the ...
• 85.9k

### Fixed point of the SHA-256 compression function

SHA-256 is based on a Davies–Meyer compression function. Easy to find fixed-points are a known property of this construction. A notable property of the Davies–Meyer construction is that even if the ...
• 24.1k

### How do hashes really ensure uniqueness?

Firstly, some definitions; Pre-image resistant: given a hash value $h$ find a message $m$ such that $h=Hash(m)$. Consider storing the hashes of passwords on the server. Eg. an attacker will try to ...
• 43.5k

### How can hashes be unique if they are limited in number?

You are right, hashes won't be all unique as you already have shown. The important part are practical collisions - how many SHA-512 hashes can the whole earth generate in its lifetime? Definitely much ...
• 3,820
Accepted

### Cycles in SHA-256

$\text{SHA256}$ is designed to behave as a random function. Under that assumption, it is expected that for most 256-bit $v$, there is no positive integer $n$ with $\text{SHA256}^n(v)$ equal to $v$. ...
• 125k
Accepted

### Why hashing twice?

A common rationale for hashing twice is to guard against the length-extension property of the hash (if it has that property, as many hashes before SHA-3 did). For SHA-256, this property allows to ...
• 125k
Accepted

### Do identical strings always have the same SHA-256 value?

Yes, if you hash the same input with the same function, you will always get the same result. This follows from the fact that it is a hash-function. By definition a function is a relation between a ...
• 6,424
Accepted

### SHA-256 "almost unique"?

Theoretically, since the domain of SHA-256 contains $2^{2^{64}-1}$ different messages and the value set only contains $2^{256}$ different message digests, there must exist at least one possible output ...
• 10.2k
Accepted

### What are the consequences of removing a single byte from a sha256 hash?

Does this bias the hash in any way? We want the avalanche criteria on the output bits, that is a change in the any of input bit must randomly affect half of the output bits. Each bit of the hash ...
• 43.5k

### HMAC-SHA1 vs HMAC-SHA256

I would use HMAC-SHA256. While poncho's answer that both are secure is reasonable, there are several reasons I would prefer to use SHA-256 as the hash: Attacks only get better. SHA-1 collision ...
• 31.3k
Accepted

### Are hash functions strong against quantum cryptanalysis and/or independent enough of mathematics?

This depends on what kind of hash function you mean and what kind of security you want. Poly1305 is an almost-universal hash family, which, when used with a uniform random key for a single message, ...
Accepted

### How many hex digits do I need to compare when manually checking hash functions?

How many hex digits do I need to compare when manually checking hash functions? If you actually want the full security guarantees of the hash function to apply: all of them. I usually just look ...
• 44.7k
Accepted

### What makes SHA-256 secure?

It's worth pointing out that in the case of SHA2 and most other hashes the compression function has a block cipher (keyed permutation) as its core. Basically what you are asking is identical to ...
• 246

### Has SHA256 been broken by Treadwell Stanton DuPont?

As of today (12th September 2019) Tradwell Stanton DuPont have retracted their claim: Sorry for the image link, but the text on their site doesn't seem to be permalinkable, and I wanted a more ...
• 331

### What size should the HMAC key be with SHA-256?

The only rule for the key is that it should at least contain 256 bits of randomness. If the key is smaller you may not get the full security of HMAC-SHA-256. The full security of HMAC is basically ...
• 85.9k

### Can one use a reversible hash algorithm as a compression function?

Strictly speaking, all hash functions are compressing since the output can be smaller than the input, but I imagine you're asking about compressing data that can later be losslessly decompressed. This ...
• 13.5k
Accepted

### Is it possible that a SHA256 hash has the same hex character over and over again?

First of all, the output of SHA-256 is binary and consists of 32 bytes (256 denotes the output size in bits). What you are talking about is apparently the hexadecimal encoding of these bytes. The ...
• 85.9k