To check and verify the MD5, SHA1, or SHA256 checksum of a downloaded file on macOS, follow these steps:
- Download the checksum file for the file you want to verify. This file should contain the expected checksum values for the file you have downloaded.
- Open a terminal window.
- Change the current working directory to the directory where the file and the checksum file are located.
- Use the
openssl
command to calculate the checksum of the file. For example, to calculate the SHA256 checksum, use the following command:
openssl sha256 <filename>
- Compare the checksum calculated in step 4 with the expected checksum value in the checksum file. If the checksums match, the file has been downloaded correctly.
Note: On macOS, the openssl
command is included by default and can be used to calculate MD5, SHA1, and SHA256 checksums. If the openssl
command is not available, you can install it using a package manager such as Homebrew.