Rudloff / alltube

Web GUI for youtube-dl
GNU General Public License v3.0
2.96k stars 582 forks source link

Fix image 403 #387

Closed mikagrand closed 2 years ago

mikagrand commented 2 years ago

New issue

Your environment

Please answer these questions when reporting a new issue:

What is your operating system (Windows, Linux, OSX, etc.)?

What is your web server (Apache, IIS, etc.)?

What version of AllTube are you using?

How did you install AllTube (with Git or with a release package)?

What version of PHP are you using?

What version of Python are you using?

What version of youtube-dl are you using?

Do you get any PHP-related errors in your webserver's logs?

What is the content of your config/config.yml file?

# Insert content here.

Please provide the URL of a video that causes the issue.

Hello, Can you please help me fix thumbnail error 403 i get this error from some videos sources: error: "Failed to load resource: the server responded with a status of 403 ()" i think we can use some php ut what php file i can do this change? php to use to fix thumnail 403 error: echo base64_encode(file_get_contents("$video->thumbnail") So where we can put change for thumnail ?

Thanks.

Rudloff commented 2 years ago

Can you please provide an example URL?

mikagrand commented 2 years ago

Ok, no problem: https://dl.utilitiesappsios.com/info?url=https%3A%2F%2Fwww.instagram.com%2Fp%2FCKCasNOnvdr%2F&from=&to=

Thanks.

mikagrand commented 2 years ago

Hello. Ok, if you can not fix, no problem, ut your script have a very big security issue, because of direct download files generator, i mean look this url: https://alltubedownload.net/download?url=https://www.youtube.com/watch?v=lwoN6KiThiU&stream=on&customFormat=mp3&customBitrate=128 if anyone load this url and just change the source, they can use it on any website or directly to download video, and this can hurt your server without having any visitor. Can you help me rewrite only this url i mean only this (https://alltubedownload.net/download) url show on browser when user press Download.

Thanks.

Rudloff commented 2 years ago

I'm not sure how this a security issue. If you don't want people to use URLs to you server, you are free to password-protect it. (Also please create a separate issue when you want to discuss a separate topic.)

As for the Instagram 403 error, I can reproduce it but I am not sure what the problem is. I suppose the image must be fetched with the same cookies as the youtube-dl request. We could theoretically stream the image through the server but I am not really sure that's worth it. Displaying the thumbnail is just a cosmetic feature.