Skip to content

Add optional file hash validation for downloads #72

@Tosox

Description

@Tosox

Task Description

As a modlist maintainer, I need the ability to provide a file hash for mod entries so that downloaded archives can be validated for integrity. Since ModDB exposes an MD5 hash on the download page, validation can happen before the download for those entries, saving bandwidth. For all other sources the hash is computed post-download.

Acceptance Criteria

  • Mod entries in the modlist optionally accept a hash field
  • Entries without a hash field skip validation entirely
  • For ModDB sources, the MD5 hash is scraped from the addon page and compared against the previously installed hash, if they match, the re-download is skipped entirely
  • For all other sources, the hash is computed from the downloaded archive and compared against the declared hash post-download
  • Hash mismatches are collected throughout the installation and presented in a summary dialog at the end
  • The summary dialog offers to write the actual hashes back into modlist.yaml for mismatched entries

Additional Information

Relevant code: ModDbUrlSource.resolve() for pre-download MD5 scraping, HttpArchiveDownloader.download() for post-download hash computation, and InstallCoordinator.runInstallation() for the end-of-install summary

Metadata

Metadata

Assignees

Labels

taskNew feature or request

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions