devonfw / ide

Tool to automate setup and update of development environment (esp. for Java projects).
Apache License 2.0
35 stars 101 forks source link

verify checksum in doDownload #1182

Closed hohwille closed 1 year ago

hohwille commented 1 year ago

In ide-urls we have now SHA256 checksums of all our downloads. For #941 we also need to implement a verification of the checksum. Simply call sha256sum on the downloaded file and get the raw checksum (without the filename) from that. Then compare the with *.sha256 file from ide-urls.

NOTE: doDownload is a generic function and can also be called with a direct download (e.g. for a custom tool not available in ide-urls). In that case we cannot verify the checksum and should skip the check. We should print a message that we could not verify the checksum then.

hohwille commented 1 year ago

Implemented with PR #1208