0

I have a file, file.txt and inside it I have a text computer. When I use openssl to make a MD5 hash out of it, it gives me:

openssl dgst -md5 file.txt 
MD5(file.txt)= 6accefe4a7ff62bd935f25a053c5fd3c

And when I use http://www.md5.cz/ to make hash from the word computer it gives me df53ca268240ca76670c8566ee54568a and I dont know why.

In my file theres no newlines and spaces. What is the problem here?

yak
  • 3,770
  • 19
  • 60
  • 111
  • Stack Overflow is a site for programming and development questions. This question appears to be off-topic because it is not about programming or development. See [What topics can I ask about here](http://stackoverflow.com/help/on-topic) in the Help Center. Perhaps [Super User](http://superuser.com/) or [Unix & Linux Stack Exchange](http://unix.stackexchange.com/) would be a better place to ask. – jww Jan 20 '18 at 11:54
  • [MD5 hash with different results](https://stackoverflow.com/q/6839969/608639), [openssl sha256 diff](https://stackoverflow.com/q/11742460/608639), [OpenSSL create SHA hash from shell stdin](https://stackoverflow.com/q/11066171/608639), [Generating a sha256 from the Linux command line](https://stackoverflow.com/q/3358420/608639), [Equivalent of md5 hashing in linux commands](https://stackoverflow.com/q/16446306/608639), [How to remove newline from output?](https://stackoverflow.com/q/35799684/608639), etc – jww Jan 20 '18 at 11:58

1 Answers1

1

MD5 of computer is df53ca268240ca76670c8566ee54568a.

MD5 of computer\n is 6accefe4a7ff62bd935f25a053c5fd3c.

Your file.txt is having a new line character \n at the end.

Vivek
  • 2,665
  • 1
  • 18
  • 20