Maximum MD5 Value for 20-Character Password

I'm writing an application that stores encrypted passwords using the MD5 functionality provided in .NET.

I've restricted the plain-text password field in the application to 20 characters and I now need to know if the MD5 hash value itself will ever exceed 20 characters (for storage purposes).

If the user can type 20-characters into a plain-text field, what is the maximum length of the MD5 character string that could be generated?

Who is Participating?
MD5 is a fixed size 128-bit hash. So it is always 128/8 = 16 bytes long. It is usually represented as a 32 hex character string.
So if you will store it as a binary then the size is always 16.
If you will store it as hex then the size is always 32.

I don't have anything to add to PowerIT's excellent answer, but in case you want to know more about MD5, this is a nice source of information :
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.