-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wrong checksum in ide-urls #1142
Comments
For ide/url-updater/src/main/java/com/devonfw/tools/ide/url/updater/npm/NpmUrlUpdater.java Line 21 in eed1f40
|
If I am not mistaken then only problem left that I could find is gcviewer. Example URL: https://sourceforge.net/projects/gcviewer/files/gcviewer-1.36.jar |
|
more redirects:
|
With the last URL finally |
When testing I just got an error in version 1.34.1
|
So the final summary is that we can now close this issue. |
For the record also for Docker-Desktop and other "latest" download urls this bug was present. |
…ms (#9) Update GCViewer urls with checksums
Expected behavior
Our update process populating
ide-urls
shall compute correct sha256 checksums for each download file so thatdevonfw-ide
will be able to verify that checksum. Therefore when I download the according file and compute the checksum withsha256sum
, I should get the exact same hash.Actual behavior
For some tools the checksums are computed wrong. According to my analysis some download URLs lead to HTML websites that themselves contain some JavaScript redirecting to the actual download on a mirror. This especially applies to sourceforge.net.
Tools like
curl
can magically handle this and do the actual download. However, our accordingUrlUpdater
s cannot handle this situation. As a result they consider the HTML content as the actual download file. Therefore they compute the SHA256 checksum of the HTML content instead of the binary download file.I have already changed the code such that the SHA256 checksum computation will fail if the content type header is present and its value starts with
text
(such astext/html
).Steps to reproduce (bug) / Use Case of feature request (enhancement)
$ sha256sum ~/Downloads/devonfw-ide/npm-9.6.0-windows.tgz
628f7650e50a4081746a681c74aeca48f9d1cebb333d4d69fdffaa1a487c3ada *...
$ cat urls/npm/npm/9.6.0/windows_x64.urls.sha256
5f1da1ef6ba776449900c931e7acc3b60e47f3080425bf0e6a1c0c5a07dbd6fd
https://github.com/devonfw/ide-urls/blob/master/npm/npm/9.6.0/windows_x64.urls.sha256
Related/Dependent Issues
#1009
Comments/Hints:
Affected version:
2023.04.001
The text was updated successfully, but these errors were encountered: