sum - display file checksums and block counts
sum [ -o 0|1|2 ] [ -h ] [ filename ... ]
sum outputs three space seperated values: file CRC, file size, and file name. Can be used to find errors in transmitted files. You should not use sum for security checks as they are easily fooled. Look into md5sum for something a bit more secure. If no file names are specified, stdin is used and no file name will displayed in the output.
0
1
2
sum returns 0 on success or 1 if an error occurred.
The program checks the name in which it was called. If it is anything except "cksum", the output will default to BSD Historic Algorithm 1 unless otherwise specified. Otherwise, the default is CRC32 mode.
Algorithms 1 and 2 will round up to the next block count for partial blocks.
CRC 32 algorithm ported directly from OpenBSD cksum C source code.
Perl version rewritten for the Perl Power Tools project from the description of the cksum program in OpenBSD.
Theo Van Dinter (felicity@kluge.net)
md5sum(1)
To install PerlPowerTools, copy and paste the appropriate command in to your terminal.
cpanm
cpanm PerlPowerTools
CPAN shell
perl -MCPAN -e shell install PerlPowerTools
For more information on module installation, please visit the detailed CPAN module installation guide.