Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

C 

"compare" two files?

I remember some time ago there was some software named something like "cmpare" or some shit, to test the difference between two executables, was mainly made to check if build is unique etc, anybody knows what its named or any similar software?
[Image: scK6Gck.gif]

It's better to create a checksum of the two files and compare those.
[Image: m7EgqG6.png]
You can also use the 'diff' program that's common on unix-like systems. The 'diff' program exists on my Windows installation as well, not sure if that's due to git-bash or not.
[img]http://66.media.tumblr.com/acfffd664b499bccaea0a5bcfd0debf0/tumblr_of816spRTW1twdas2o1_400.jpg[/img]

On Windows, it's fc fileA fileB
(Feb 28, 2017 03:54 AM)Masm4ever Wrote:  On Windows, it's fc fileA fileB

Or you could not use the shell and make your own program or function that does i, it's childsplay.
Calculate the md5/sha1 hash of the code section in the PE header of the two specific files and compare them
(Mar 2, 2017 05:34 AM)maldev0 Wrote:  Calculate the md5/sha1 hash of the code section in the PE header of the two specific files and compare them

That won't cover the data section though.
Why can't you just use sha256sum or another checksum hash function? Preferably not an MD5 or SHA1 checksum, as collisions have been proven (recently with SHA1), and there is even code out there to make two C programs have the exact same MD5 sum yet do completely different things (you can check that out here), I know it wasn't the question, but it is relevant, and damn cool.

There are no proven sha256 or sha512 collision algorithms though that I am aware of (afaik SHA1 doesn't have an algorithm to make two do different things, other than just not work at all... yet).

You can compare the files with
Code
sha256sum file1 file2
Simple, works, and you don't have to reinvent the wheel. Relatively secure.


Possibly Related Threads...
Thread / Author Replies Views Last Post
[C#] by gigajewNov 26, 2018 05:51 AM 1 249 Nov 26, 2018 05:51 AM
Last Post: Nick (Name)
[C] by F.A.S.TNov 2, 2018 03:35 PM 1 149 Nov 2, 2018 03:35 PM
Last Post: Auriana
[Shell] by HackooMay 16, 2018 01:05 PM 14 414 May 16, 2018 01:05 PM
Last Post: HFDone