S
S
SimBioT192017-03-25 15:26:41
PHP
SimBioT19, 2017-03-25 15:26:41

Getting the hash of a string?

I need to get a hash for strings that users will enter.
The hashes of different strings should never match. Question: is md5
suitable for my purposes , given that the length of the string can be up to 400 characters? Or are there better solutions?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
G
GavriKos, 2017-03-25
@GavriKos

is md5 suitable for my purposes

No. MD5 does not guarantee the absence of collisions. Their probability is small, but still there.

A
Andrey Nikolaev, 2017-03-25
@gromdron

I don't think there are algorithms for which there are no vulnerabilities. They probably just haven't been found yet.
You can try https://ru.wikipedia.org/wiki/RIPEMD-320. It is in php and, as Wikipedia says, no vulnerabilities have been found in it yet.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question