1

I'm familiar with the concept of downloading a file and manually checking it against a published checksum. See How to verify the checksum of a downloaded file (pgp, sha, etc.)? and Is there a command line method by which I can check whether a downloaded file is complete or broken? for examples.

I would now like to maintain my own list of target URLs and expected checksums, something like:

https://example.com/file.tar.gz, SHA123456...
https://example.org/list.txt, SHA1A1A1A...

...and automate the download-and-check process.

Before I make the mistake of hacking my own solution, is there an established way to do this on a Debian-based distro?

lofidevops
  • 3,590
  • 6
  • 24
  • 32
  • 1
    Hi David, this looks more a programing question from my point of view. You have your file with URLs and hashes and other process (python requests) downloads and check the file. – camp0 Oct 31 '19 at 16:59
  • @camp0 That's actually exactly what I'm trying to avoid (programming a solution). Is there an existing tool for this? Or even better an existing strategy / file format? (so that this isn't a suggest-an-application question) – lofidevops Oct 31 '19 at 17:58
  • @camp0 Happy to take suggestions on how to word the question more clearly – lofidevops Oct 31 '19 at 17:59
  • please check this post https://superuser.com/questions/655346/wget-execute-script-after-download, the solution is really easy on bash and on python – camp0 Nov 01 '19 at 08:23
  • Interesting question. I cooked up a short python script to do this. See https://pastebin.com/3iBHnT3q – mti2935 Nov 01 '19 at 18:29

0 Answers0