是独立的哈希平台(PC/Android/iPhone/等)。

发布于 2025-01-21 16:03:35 字数 189 浏览 2 评论 0原文

正如问题所说,如果我要下载不同的硬件上的zip文件&设备,移动/Windows/Mac。我可以确定,例如,MD5或SHA哈希在所有平台上都是相同的。我担心的是在解压缩此文件夹时平台之间的文件系统/差异。

理想情况下,我正在按字母顺序排列所有文件,&将它们组合在一起,然后对数据库哈希字符串检查,以确保在应用程序运行时永远不会更改内容。

As the question says, if I'm downloading let's say a zip file on different hardware & devices, mobile/windows/mac. Can I be certain that for example an MD5 or SHA hash will be identical across all platforms. My worry is file system/differences between platforms when unzipping this folder.

Ideally I'm hashing through all files in alphabetical order & combining them, and then checking that against a database hash string to ensure contents are never changed whenever the application runs.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

七七 2025-01-28 16:03:35

是的,对于MD5和SHA。普通公共使用的障碍的实现为所有这些系统产生了预期输出。

我还可以说,与iPhone + Windows的组合在生产中正确工作时,我已经有这种情况。

这也已经被问到并已经回答了,所以我说的是重复:

Yes for md5 and sha. Implementations of common public used hashfunctions produce the expected output for all these systems.

I can additionally say that I have had this in working correctly in production with the combination of iphone + windows.

This also has been asked and answered already so id say is a duplicate:
Is a hash function (e.g. SHA) platform independent?

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文