SYNOPSIS
dgstsum
[
dgstsum
[
md2sum
[
md2sum
[
md4sum
[
md4sum
[
md5sum
[
md5sum
[
mdc2sum
[
mdc2sum
[
ripemd160sum
[
ripemd160sum
[
shasum
[
shasum
[
sha1sum
[
sha1sum
[
sha224sum
[
sha224sum
[
sha512sum
[
sha512sum
[
sha384sum
[
sha384sum
[
sha512sum
[
sha512sum
[
whirlpoolsum
[
whirlpoolsum
[
DESCRIPTION
The dgstsum utility takes each specified input file and produces a checksum called a message digest. By default, dgstsum uses the md5 digest format. Alternatively, it can compare previously generated output to see if the message digests are still the same (that is, the files have not changed).
The md2sum, md4sum,
md5sum, mdc2sum,
ripemd160sum,
shasum, sha1sum, sha224sum, sha256sum,
sha384sum, sha512sum, and
whirlpoolsum utilities
are similar to dgstsum except that instead of specifying
the digest format with the
Options
-b --binary -
Treats all files as binary. No end-of-file or end-of-line conversions take place. When comparing against text files from UNIX systems, this may yield different checksums.
-c file--check= file-
Specifies a check file. This check file contains the output from a previous dgstsum command. Each line in the check file contains a message digest, a flag specifying if the file is binary or text, and a file name. dgstsum opens each listed file, calculates its current message digest and compares it to the corresponding digest from the previous output. As each file's digests are compared, dgstsum displays the file's name and either OK if the digests match or FAILED if they do not. However, the
--status option, described below, can suppress this display.- Note:
-
For this option to work correctly, both the previous and new digests must use the same digest format. For example, if you created a saved output file named md2out from a dgstsum
-d md2 command, you could use either of the following commands to compare the current digests to those in md2out:dgstsum -d md2 -c md2out md2sum -c md2out
-d digesttype-
Specifies the digest format to be used when calculating message digests. The following formats may be specified for digesttype:
md2 md4 md5 mdc2 ripemd160 rmd160 sha sha1 sha224 sha256 sha384 sha512 whirlpool
- Note:
-
rmd160 is simply an another name for the ripemd160 format.
-h --help -
Displays a usage message and exits.
-s string--string= string-
Computes the message digest for just the specified string rather than for a file. The message digest generated is identical to that of a file containing just string.
--status -
Suppresses the display of file names and either OK or FAILED for each line in the check file. Instead, the utility returns an exit status of 0 when all files in the check file generate the same message digest as in the check file or an exit status of 1 when at least one file generates a different message digest. This option is only applicable with
-c or--check . -t --text -
Treats all input files as text files. This is the opposite of
-b . End-of-file and end-of-line conversions are performed so that UNIX and Windows text files whose only differences are the end-of-line characters used produce identical message digests.- Note:
-
This option is not recommended for binary files.
-V --verbose -
Does nothing. This option is provided for compatibility with other versions of these utilities.
-v --version -
Displays version number.
-w --warn -
Displays warnings about malformed lines in the check file specified with the
-c (or--check ) option. Normally, when this option is not specified, malformed lines are simply ignored.This option is only applicable with
-c or--check .
DIAGNOSTICS
Possible exit status values are:
- 0
-
Successful completion.
- 1
-
An error occurred or when
-c or--check is specified, one or more files listed in the check file now generate a different checksum. - 2
-
A usage error occurred.
NOTE
These commands are provided as KornShell executable scripts. MKS cannot be responsible for proper functionality of this code if you alter these scripts (dgstsum.sh, md2sum.sh, md4sum.sh, and so on) in any way.
PORTABILITY
Windows 10. Windows Server 2016. Windows Server 2019. Windows 11. Windows Server 2022. Windows Server 2025.
AVAILABILITY
PTC MKS Toolkit for System Administrators
PTC MKS Toolkit for Developers
PTC MKS Toolkit for Interoperability
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition
SEE ALSO
- Commands:
- openssl dgst
PTC MKS Toolkit 10.5 Documentation Build 40.