Fastest checksum for file comparison

If you need to just quickly check if two files are same you can use cksum instead of the usual sha*sum or md5sum.

cksum is much faster. The prices is that it is not cryptographically safe: it is possible to intentionally construct collisions.

However, for all non-adversarial situations this is totally fine and you gain significant speed compared to the crypto-hashes.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s