On the Cisco switch:
Switch# verify /md5 flash:/filename.bin .......................................................................................... ....................................................Done! verify /md5 (flash:/filename.bin) = 512564b05cecc2041d00890caa18224c
On the POSIX-like operating system the file was copied from using TFTP:
$ md5sum /var/lib/tftpboot/filename.bin 512564b05cecc2041d00890caa18224c filename.bin