compute message digest, like MD5 and SHA256, etc, for potentially large files