Checking file integrity with md5.
On Windows machine
1. Create a directory on your windows machine
C:\Users\sam\Desktop\md5>
2. Download the md5sum application from internet.eg,
https://www.microsoft.com/en-us/download/details.aspx?id=11533
3. Create a myhashFile.txt file and add the content "Testing md5 checksum with the utility!!!"
4. Now run the md5 application to genetate the hashing algorithm.
C:\Users\sam\Desktop\md5>dir
05/27/2015 11:40 AM <DIR> .
05/27/2015 11:40 AM <DIR> ..
05/13/2004 01:26 PM 84,784 fciv.exe
05/27/2015 11:44 AM 42 myhashFile.txt
05/13/2004 01:26 PM 3,627 ReadMe.txt
3 File(s) 88,468 bytes
2 Dir(s) 420,039,544,832 bytes free
C:\Users\sam\Desktop\md5>fciv.exe myhashFile.txt
0c4e7e7f69128d826092ed20d4fecf5a myhashfile.txt
You can run multiple time to compare the output but you will find the same result.
5. Now, edit a file and add some extra content say "I modify file"
type notepad myhashfile.txt and it will open notepad.
Re-run the md5 check command.
C:\Users\sam\Desktop\md5>fciv.exe myhashFile.txt
264e9b0f8e37ded3b39e38b6695b658c myhashfile.txt
Now, the output is different than the previous one.
This is tell you if file/data is modify somewhere while downloading ..
On Linux
Just run the md5 command followed by a file name
$ md5sum createUser.sh
4fca82ac747f49b968828087de061f20 createUser.sh
On Windows machine
1. Create a directory on your windows machine
C:\Users\sam\Desktop\md5>
2. Download the md5sum application from internet.eg,
https://www.microsoft.com/en-us/download/details.aspx?id=11533
3. Create a myhashFile.txt file and add the content "Testing md5 checksum with the utility!!!"
4. Now run the md5 application to genetate the hashing algorithm.
C:\Users\sam\Desktop\md5>dir
05/27/2015 11:40 AM <DIR> .
05/27/2015 11:40 AM <DIR> ..
05/13/2004 01:26 PM 84,784 fciv.exe
05/27/2015 11:44 AM 42 myhashFile.txt
05/13/2004 01:26 PM 3,627 ReadMe.txt
3 File(s) 88,468 bytes
2 Dir(s) 420,039,544,832 bytes free
C:\Users\sam\Desktop\md5>fciv.exe myhashFile.txt
0c4e7e7f69128d826092ed20d4fecf5a myhashfile.txt
You can run multiple time to compare the output but you will find the same result.
5. Now, edit a file and add some extra content say "I modify file"
type notepad myhashfile.txt and it will open notepad.
Re-run the md5 check command.
C:\Users\sam\Desktop\md5>fciv.exe myhashFile.txt
264e9b0f8e37ded3b39e38b6695b658c myhashfile.txt
Now, the output is different than the previous one.
This is tell you if file/data is modify somewhere while downloading ..
On Linux
Just run the md5 command followed by a file name
$ md5sum createUser.sh
4fca82ac747f49b968828087de061f20 createUser.sh
No comments:
Post a Comment