Which is the best overall hashing algorithm in terms of complexity and security? md5 or sha1?
From what I know md5 is faster than sha1 but SHA1 is more complex than md5.
Am I missing anything?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
First of all, MD5 is broken – you can generate a collision, so MD5 should not be used for any security applications. SHA1 is not known to be broken and is believed to be secure. Other than that – yes, MD5 is faster but has 128-bit output, while SHA1 has 160-bit output.
Update: SHA1 has been broken: a team of researchers at Google and CWI have published a collision – https://shattered.io/static/shattered.pdf