Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can a SHA-1 hash be all-zeroes?

Tags:

sha1

Is there any input that SHA-1 will compute to a hex value of fourty-zeros, i.e. "0000000000000000000000000000000000000000"?

like image 468
mckamey Avatar asked Dec 14 '09 17:12

mckamey


People also ask

Is SHA1 hash always the same?

SHA1 is a message hashing or digest algorithm where it generates a 160-bit unique value from the input. The size of the input does not matter, because SHA1 always generates a message hash of the same size, which is 160 bits.

How many bits is an SHA1 hash value?

The hash size for the SHA1 algorithm is 160 bits.

How many characters is a SHA1 hash?

The length of a SHA1 hash is 160 bits or 20 bytes. In this application it is represented by 40 characters in hexadecimal form.


1 Answers

Yes, it's just incredibly unlikely. I.e. one in 2^160, or 0.00000000000000000000000000000000000000000000006842277657836021%.

like image 113
daf Avatar answered Oct 12 '22 15:10

daf