erickutcher / httpdownloader

HTTP(S) download manager that uses input/output completion ports (IOCP).
https://erickutcher.github.io/#HTTP_Downloader
571 stars 61 forks source link

Http Downloader shows 403 error but download url is correct. #302

Closed Dhyfer1 closed 4 months ago

Dhyfer1 commented 4 months ago

Hi @erickutcher 👋

I'm using your app as a replacement for IDM and I like it, although I miss not being able to download videos like IDM does.

The reason for this issue is that HTTP Downloader has some problem downloading the TakeOwnershipEx file from Winaero, as you can see in the screenshot it throws error 403, I have even edited the download link removing ?amp at the end but I have no success, the file just won't download.

Screenshot 2024-06-30 220518.png

That's all for now, I await your response.

erickutcher commented 4 months ago

That site expects a Referer header value.

Right click on that download and select "Update Download..." Click on the Headers tab and add this line: Referer: https://winaero.com/download-takeownershipex-allows-you-to-get-full-access-to-files-and-folders/ Click Update and then right click on the download again and select Restart.

That should get it going.

If you use the browser extension to intercept the download, then it'll fill in all the cookie/header values that the download requires to work.

Dhyfer1 commented 4 months ago

Thank you very much, I have followed your instructions and it works as you say, the same with the extension. I'll keep the Headers tab in mind next time I find a file that doesn't download normally.

By the way, another thing I would like to see in your app is that it can categorize downloaded files. For example, IDM created several folders: documents, images, videos, music, compressed and programs, and the downloaded files were sent to one of these folders depending on the type of content. Don't you think it would be a useful feature in HTTP Downloader?

Also, if possible, I would like to see the actual icons of the downloaded file in the download list.

Since my problem has been solved, I will close this issue.

erickutcher commented 4 months ago

I've thought about a category list, but I didn't want to turn the program too much into a file manager. I feel like Explorer can handle that better. If you were downloading audio files, for example, you want to save them in the Music folder that Windows has set up. Maybe one day, but it's kind of a big overhaul.

The file's icon appears in the second column next to its name.

Dhyfer1 commented 4 months ago

I've thought about a category list, but I didn't want to turn the program too much into a file manager. I feel like Explorer can handle that better. If you were downloading audio files, for example, you want to save them in the Music folder that Windows has set up. Maybe one day, but it's kind of a big overhaul.

Ok. I only said this because IDM could automatically move downloaded files to their respective folder depending on their extension. However, with Http Downloader I have to do this process manually, and it's tedious when I have many downloaded files in the Downloads folder and then move them by groups to other folders: Documents, Images, Videos etc.

The file's icon appears in the second column next to its name.

I know, but I think you misunderstood me. I will use 7zip as an example, in 7zip there is an option in its settings called "Show real file icons" which is disabled by default. When disabled, this is how the exe files appear.

7zFM_HtBIlHnaRd.png

and when that option is activated, the actual icons of each file are shown.

7zFM_zKz397ew8L.png

I am referring to the latter, that HTTP Downloader can show the real icon of the .exe files and not a generic icon.

erickutcher commented 4 months ago

If I ever add the ability to filter the download list, then I'll consider adding the category list. All of that would be a lot of work though and I'm actually pretty content with where the program is at the moment. Plus, I've switched to Linux so I don't get on my Windows machine as often.

As for the file icons, I've got that working. It'll only do it for .exe files. Might be a while until I have it ready though.

Dhyfer1 commented 4 months ago

Okay, I hope you take my suggestions into account. I've read a lot of your comments saying that you want to keep it simple, but there are some features that are missing and it would be great to see Http Downloader with more features.

Well, I'll be waiting for the next version Thanks.

erickutcher commented 4 months ago

Here's a beta you can try: HTTP_Downloader_1.0.6.3_Beta_1_64.zip

I added an option at the end of the Appearance options that will "Show executable's embedded icon". It doesn't update icons that are already showing, but if you restart the program then it should set them correctly.

Dhyfer1 commented 4 months ago

Thank you, I followed the instructions and and it works very well. Now I can see the exe file icons without problem. So I think this little change can now be implemented in stable version.

erickutcher commented 4 months ago

I've been implementing a filter for a categories tree. It's slow going, but there's progress. Right now I'm getting it to filter the download status (Downloading, Paused, Stopped, etc.). There's some issues with the TreeListView updating itself when the status changes, but I think I have an efficient solution for it.

Dhyfer1 commented 4 months ago

Ask: What you have said will only help filter downloads within the program but will not move the downloaded files to specific folders?

erickutcher commented 4 months ago

It'll filter downloads based on their status as well as a user defined category that you can assigned each download. Each category can have their own download location. I haven't gotten that far, but that's the plan.

The TreeView looks like this:

-- All -- Status -------- Downloading -------- Paused -------- Stopped -------- . -------- . -------- etc. -- Categories -------- Music -------- Pictures -------- Movies

Dhyfer1 commented 4 months ago

Ok, I will wait for the next beta version to try it

erickutcher commented 2 months ago

Here's another beta that has the categories working. You can add custom categories by right clicking on the Categories tree item in the categories list. It'll ask for a category name and download directory. The categories act similarly to the Site Manager in that it'll use the download directory if a category is set in the Add URL(s) window. The category download directory takes precedence over the Site Manager's download directory.

You can set a category and also have it download to a directory that is different than the one that was originally set for that category. In that sense, the category acts as a tag/label.

If you select items in the download list and then hold Alt while dragging the selected items, you can drag and drop them over a category and have them all use that category. You can also update a download's category in the Update Download window.

It's easier to play around with it to see what it all does. I made this beta a portable release as the settings have changed slightly and it won't be able to load the older settings just yet. I'll probably have another release before I release a version with all these new features.

HTTP_Downloader_1.0.6.4_Beta_1_64.zip

Dhyfer1 commented 2 months ago

Thanks for the new version, the categories are very useful. I just wish HTTP Downloader could automatically move each download to its respective folder according to the extension type, just like IDM does.

I say this because I have a list with all the download URLs of many files that I download after a new installation of Windows, my list is unordered because i have links to zip, .msi, .exe files scattered randomly, there are more than 30 links on my list. When IDM uses my list of urls, it downloads each file to its respective folder automatically (IDM creates 5 folders in the Downloads folder) depending on the extension type and IDM doesn't care if my list is unordered. If I want to use my list with HTTP DOWNLOADER I would have to sort my list, which is tedious since I have too many URLs.

I would just like to see HTTP Downloader be able to work with an unordered list of links, and put each download into a folder according to its extension type, all this automatically.

erickutcher commented 1 month ago

Might take a while to implement that. It's another overhaul of the code.

In the meantime, if you have the time, you could create a copy of your list and format it exclusively for HTTP Downloader. The order of the URLs doesn't matter either. Each URL can have parameters assigned to it and one of them is the download directory. For example:

https://www.example.com/test.jpg
--download-directory C:\Users\User\Photos
https://www.steampowered.com/SteamInstaller.exe
--download-directory D:\Games
https://www.youtube.com/lord_of_the_rings.mkv
--download-directory: D:\Movies

If you were to use a list like that, then it would save each of the URLs to the respective download directory.

Dhyfer1 commented 1 month ago

Might take a while to implement that. It's another overhaul of the code.

Ok. I hope to see this function in a future version

In the meantime, if you have the time, you could create a copy of your list and format it exclusively for HTTP Downloader. The order of the URLs doesn't matter either. Each URL can have parameters assigned to it and one of them is the download directory. For example:

https://www.example.com/test.jpg
--download-directory C:\Users\User\Photos
https://www.steampowered.com/SteamInstaller.exe
--download-directory D:\Games
https://www.youtube.com/lord_of_the_rings.mkv
--download-directory: D:\Movies

If you were to use a list like that, then it would save each of the URLs to the respective download directory.

I did what you said, but it doesn't work that way. I formatted my download list like the example you showed me, and created two new folders in the Downloads folder: programs2 to save msi and exe files, and compressed2 to save 7z, zip and rar files. I then copy my list into HTTP Downloader and start the download, but all downloads are saved in the Downloads folder instead of the two folders I created.

Here is a part of my download list, formatted according to the example:

https://download.gimp.org/gimp/v2.99/windows/gimp-2.99.18-setup.exe
--download-directory C:\users\diego\downloads\programs2

https://cdn.kde.org/ci-builds/network/kdeconnect-kde/release-24.08/windows/kdeconnect-kde-release_24.08-4217-windows-cl-msvc2022-x86_64.exe
--download-directory C:\users\diego\downloads\programs2

https://github.com/MicaForEveryone/MicaForEveryone/releases/download/v1.3.1.2/MicaForEveryone-x64-Release.zip
--download-directory C:\users\diego\downloads\compressed2

https://github.com/krlvm/AcrylicMenus/releases/download/v1.0.8/AcrylicMenus.zip
--download-directory C:\users\diego\downloads\compressed2

https://github.com/krlvm/DragDropNormalizer/releases/download/v1.0/DragDropNormalizer.zip
--download-directory C:\users\diego\downloads\compressed2

https://github.com/krlvm/AccentColorizer-E11/releases/download/v1.2.0/AccentColorizer-E11.exe
--download-directory C:\users\diego\downloads\programs2

https://github.com/krlvm/AccentColorizer/releases/download/v1.2.0/AccentColorizer-Installer.zip
--download-directory C:\users\diego\downloads\compressed2

https://github.com/bmmlms/whatthelock/files/12192836/WhatTheLock_Setup.zip
--download-directory C:\users\diego\downloads\compressed2

https://github.com/rounk-ctrl/TranslucentSM/releases/download/0.6.9/start.zip
--download-directory C:\users\diego\downloads\compressed2

https://github.com/namazso/SecureUxTheme/releases/download/v2.2.0/ThemeTool.exe
--download-directory C:\users\diego\downloads\programs2

https://www.smoothscroll.net/win/download/SmoothScroll_Setup.exe
--download-directory C:\users\diego\downloads\programs2

https://codesector.com/files/teracopy3.17.exe
--download-directory C:\users\diego\downloads\programs2

https://codesector.com/files/teracopy4b.exe
--download-directory C:\users\diego\downloads\programs2
erickutcher commented 1 month ago

My bad. It should be --output-directory

https://www.example.com/test.jpg
--output-directory C:\Users\User\Photos
https://www.steampowered.com/SteamInstaller.exe
--output-directory D:\Games
https://www.youtube.com/lord_of_the_rings.mkv
--output-directory: D:\Movies

Now that I think about it, I should probably change that flag to --download-directory for the sake of consistency. I'll do that for the next release.

Dhyfer1 commented 1 month ago

My bad. It should be --output-directory

Thanks, I made the change and the downloads go to the folders I created.

Now that I think about it, I should probably change that flag to --download-directory for the sake of consistency. I'll do that for the next release.

That's right, I also think --download-directory is more appropriate.

Edit: By the way, I forgot to tell you that the icons of the downloaded programs still appear in the list as generic icons, that also happened since the previous beta version

erickutcher commented 1 month ago

There's a bug with the icons not updating during the session. If you were to restart the program after the files have been downloaded, then they'll load correctly. Might take a while to get a new beta up because I'm adding DPI awareness support first.

Dhyfer1 commented 1 month ago

There's a bug with the icons not updating during the session. If you were to restart the program after the files have been downloaded, then they'll load correctly.

Yes, you've told me this before, but it doesn't work. The icons are still generic.

erickutcher commented 1 month ago

Do you have Show executable's embedded icon enabled in the Appearance options?

Dhyfer1 commented 1 month ago

That's right, but after a few reboots it no longer shows the icons of the downloaded programs

erickutcher commented 1 month ago

My only guess is that the file is missing when the program is loaded. Icons are extracted when the program loads and when a download finishes. The icons don't get cached so if a file no longer exists in the same path that it was downloaded to, then it'll use the default system icon for its file type.