remote-torrent-adder icon indicating copy to clipboard operation
remote-torrent-adder copied to clipboard

Not working on yggtorrent.cool

Open NathanIfinity opened this issue 1 year ago • 44 comments

Been using the extension forever with the same setting but last couple days it has stopped working but only on that site all the other torrent site work just as they should.

here is the url for a torrent download: https://www3.yggtorrent.cool/engine/download_torrent?id=1172880 link catcher doesn't work and right click add to torrent client either.

use to send it to rutorrent on my seedbox

NathanIfinity avatar May 11 '24 12:05 NathanIfinity

seems to require a login, so i can't test it. what actually happens when you click the link?

if it just downloads a link, it might be that the link is generated dynamically, after RTA's content script is injected into the website. in that case, it can't register an action on the link. but then, right-clicking and sending it via RTA that way should work. do you see any error messages in the extension's background page? -> chrome://extensions/?id=oabphaconndgibllomdcjbfdghcmenci, developer mode on, background page, then try adding a torrent via context menu from the page

bogenpirat avatar May 12 '24 11:05 bogenpirat

It actually never worked by clicking on that site always used the right-click menu and addto remote torrent but for a few days now even that doesn't work.

This is what I see in the dev mode

image

NathanIfinity avatar May 12 '24 13:05 NathanIfinity

Vs if I try with iptorrent that works

image

NathanIfinity avatar May 12 '24 14:05 NathanIfinity

well, hard to say why exactly the server won't let us fetch the file. might be that some particular header needs to be set. i assume the torrent file downloads fine if you just click on it? if so, it might be worth it to compare two requests:

  1. the one made by the extension in that window you have open - opened from the extension's settings (it'll show in the network tab)
  2. the one made by chrome when you're just left-clicking a link on the website (f12 while you're on it)

that's typically where you can see differences.

bogenpirat avatar May 12 '24 22:05 bogenpirat

Yeah if I click on it it downloads fine! I'll look the 2 request and report back Thanks

NathanIfinity avatar May 12 '24 22:05 NathanIfinity

I'm having the same issue as described by Nathan. Not sure what I could link to help the proccess. image image image

NetixQc avatar May 13 '24 01:05 NetixQc

@NathanIfinity i've taken the liberty of deleting that post since its screenshots may have contained some of your authentication data. i saw however that the extension doesn't send a referer field - that might be it. perhaps i can write something together for that in a bit.

bogenpirat avatar May 13 '24 06:05 bogenpirat

Perfect ! glad it could shed some light, let me know if you need me to test anything

NathanIfinity avatar May 13 '24 13:05 NathanIfinity

Exactly the same issue :) Did you happen to be able to find a workaround? Thanks all.

ImTheEZ3KieL avatar May 15 '24 18:05 ImTheEZ3KieL

Hi, same issue here, I don't know what they changed to their website, but it broke the plugin :(

geeknessfr avatar May 16 '24 13:05 geeknessfr

and absolutely no feedback from the admin there... of course

campones avatar May 16 '24 20:05 campones

Not sure if it can help ( because I like torrent adder more) but Torrent Control seems to work fine on Firefox if you need any log I could send them

NathanIfinity avatar May 16 '24 22:05 NathanIfinity

Yggtorrent switched domain again. They went private to ygg.re and the problem is now solved. Remote Torrent Adder works like before.

NetixQc avatar May 17 '24 13:05 NetixQc

huh, procrastination clearly solved the issue. can the others confirm that it's fixed? if not, i'll have time on the weekend to finally zip a test build

bogenpirat avatar May 17 '24 16:05 bogenpirat

I confirm that on the new private domain it works as expected

NathanIfinity avatar May 17 '24 23:05 NathanIfinity

It started happening again since yesterday, any chance you had time to implement the fix so it doesn't break everytime they make a change :P

Thanks

NathanIfinity avatar Jun 04 '24 11:06 NathanIfinity

Can confirm what Nathan said. It's broken again.

NetixQc avatar Jun 04 '24 14:06 NetixQc

alright, i fear i need to ask for a sampling of this again - i had deleted the prior one. make sure to censor any header that looks like a session hash or credentials. in the cookies header, feel free to censor what you wish, but leaving the cookie names might help (format is name1=value1; name2=value2)

well, hard to say why exactly the server won't let us fetch the file. might be that some particular header needs to be set. i assume the torrent file downloads fine if you just click on it? if so, it might be worth it to compare two requests:

  1. the one made by the extension in that window you have open - opened from the extension's settings (it'll show in the network tab)
  2. the one made by chrome when you're just left-clicking a link on the website (f12 while you're on it)

that's typically where you can see differences.

NB: it's not the referer or origin fields as i originally suspected - i checked and the extension actually already sets those on requests.

bogenpirat avatar Jun 04 '24 16:06 bogenpirat

image

image

image

image

Hopefully this helps and I blocked all the correct info let me know if you need more or need to test anything

NathanIfinity avatar Jun 06 '24 01:06 NathanIfinity

thanks, that's a good start. now could you open a tab to the torrent site, hit f12/network tab, then normally download the torrent file (i presume since RTA doesn't properly register the left-click action, you can just left-click? if not, do ctrl+leftclick) and please show me what the request headers look like for that request (so like images 2+3 from your post)

bogenpirat avatar Jun 06 '24 22:06 bogenpirat

let me know if this is ok

image

image

NathanIfinity avatar Jun 06 '24 22:06 NathanIfinity

at first glance, it seems that RTA isn't sending most of the cookies that the browser does. this should happen though, because RTA's requests towards the server are just executed through the browser which already has all of the cookie data. if this part didn't work, no website requiring a login should work, and i'm certain that they do.

but there's something fishy here - your response headers for the browser request show a content-type of text/html - you wouldn't be getting a torrent file from that response. can you take a look at the "response" tab right above the headers - it should show you a bunch of garbage symbols if it is a torrent file. i'm suspecting you might be seeing some html/javascript code instead.

fwiw, these two problems are completely separate. if my suspicion is correct, i'm not certain that RTA can circumvent this... "behavior" to download the torrent file. let me know what you find.

bogenpirat avatar Jun 07 '24 14:06 bogenpirat

yeah in the response tab I have html/java I don't see anything when i click or right click on the torrent file

!DOCTYPE html.txt

NathanIfinity avatar Jun 07 '24 15:06 NathanIfinity

at first glance, it seems that RTA isn't sending most of the cookies that the browser does. this should happen though, because RTA's requests towards the server are just executed through the browser which already has all of the cookie data. if this part didn't work, no website requiring a login should work, and i'm certain that they do.

but there's something fishy here - your response headers for the browser request show a content-type of text/html - you wouldn't be getting a torrent file from that response. can you take a look at the "response" tab right above the headers - it should show you a bunch of garbage symbols if it is a torrent file. i'm suspecting you might be seeing some html/javascript code instead.

fwiw, these two problems are completely separate. if my suspicion is correct, i'm not certain that RTA can circumvent this... "behavior" to download the torrent file. let me know what you find.

Thanks for taking the time to troubleshoot this issue. Users at Ygg.re are reporting that everything works on Firefox using the extension Torrent Control so not sure if it does something different then RTA.

NetixQc avatar Jun 07 '24 15:06 NetixQc

yeah in the response tab I have html/java I don't see anything when i click or right click on the torrent file

!DOCTYPE html.txt

sorry, this is the response you get when you click on the download link for a torrent file in the browser?

bogenpirat avatar Jun 07 '24 16:06 bogenpirat

Thanks for taking the time to troubleshoot this issue. Users at Ygg.re are reporting that everything works on Firefox using the extension Torrent Control so not sure if it does something different then RTA.

doesn't seem to be doing anything special, so it may be down to how the browsers are handling things.

bogenpirat avatar Jun 07 '24 16:06 bogenpirat

is this what you wanted ?

image

NathanIfinity avatar Jun 07 '24 17:06 NathanIfinity

yep, that's your browser downloading the torrent file.

can you show me the (redacted, again) request headers for that?

bogenpirat avatar Jun 07 '24 17:06 bogenpirat

image

NathanIfinity avatar Jun 07 '24 17:06 NathanIfinity

that looks correct. so i think the central issue is that the extension doesn't automatically send the cookies for the site along with the request that gets the torrent file, resulting in a 403. i'm not sure why that is, i presume it's got to do with the configuration of the server. i'm taking a stab in the dark at circumventing that with this build: remote-torrent-adder.git.zip please check https://github.com/bogenpirat/remote-torrent-adder/wiki/Try-new-code on how to try it out.

bogenpirat avatar Jun 07 '24 19:06 bogenpirat