1
$\begingroup$

What's the use of SHA on Non Digital Signature applications? Why is SHA1 not a risk for Non Digital Signature applications? What's the difference between Non Digital Signature applications vs. Digital Signature?

$\endgroup$
3
2
$\begingroup$

SHA1 can be used for error detecting just like CRC32, but with much stronger message integrity guarantee (though not as strong as SHA-256).

SHA1 can also be used for generating random bits. This can be done by instantiating NIST-SP-800-90Ar1 Hash_DRBG and HMAC_DRBG with SHA1 and HMAC-SHA1 respectively.

SHA1 can also be used in key derivation functions. PBKDF2 and HKDF can be instantiated from it.

The security requirement difference between digital signature and non digital signature application is that: the hash that directly process the input message must be collision resistant, which SHA1 can provides a maximum of 63-bit security due to its structural weakness; non digital signature applications often only require appearant randomess of the output.

$\endgroup$
2
  • 1
    $\begingroup$ Addition: there are some applications beyond digital signature where the broken collision-resistance of SHA-1 matters. An example is file integrity by displaying a hash, when adversaries can prepare some content of the file, and predict what's before that. There also are convoluted way to use SHA-1 securely in signature applications, by forcing a random prefix (e.g. random serial number in X.509 certs). It remains that SHA-1 should not be used in any new application, and must not be used when collision-resistance (including with chosen prefix) matters. $\endgroup$
    – fgrieu
    Jun 3 at 8:17
  • $\begingroup$ I'd also note that Blake3 is pretty much always going to be faster than SHA-1, and is far more secure. The only use of SHA-1 is for legacy systems that can't be upgraded. $\endgroup$ Jun 3 at 14:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.