TASEmulators / TASEmulators/BizHawk

Hashes aren't well handled.

Open
#2,336 8 comments 0 reactions 1 assignee View on GitHub

@YoshiRulz is already working on this.

Since May 5, 2022.

App: EmuHawk Meta
Dominant language
C#
Stars
2.8k
Forks
468
PR merge metrics
No merged PRs in 30d

Description

Both IGameInfo and IMovie have a field called Hash without a defined type.

They are not necessarily the same type: IGameInfo's value can be a CRC32 checksum, an MD5 hash, or a SHA-1 hash depending on which one matches a game in the database, while IMovie's header value is labeled "SHA1".

Going to a more practical issue, there are hash problems when importing fm2, fcm, and mmv movie types. These imported movies will not initialize the movie's Hash field, but instead stuff their data into the otherwise unused MD5 header value. Every time such a movie is opened, the hash comparison fails because the movie file has no hash. However, even if it did setup the hash, there's no guarantee the hash would be the same type because of the earlier-mentioned issues.

This leads to the erroneous message "the movie hash doesn't match the ROM hash" just because the hash was not properly initialized, unrelated to the actual correspondence between the movie and the ROM.

#2328 reminded me of this issue.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.