Bugswriter / notflix

Notflix is a shell script to search and stream torrent.
GNU General Public License v3.0
1.9k stars 176 forks source link

Fix 1337x.to impostor #15

Closed Willy-JL closed 2 years ago

Willy-JL commented 2 years ago

1337x.wtf is NOT an official domain for 1337x. The official website is 1337x.to and you can check the official domains here

Bugswriter commented 2 years ago

but 1337x.to is ban most of the places 1337x.wtf is working for me. :( should we still change?

LamprosPitsillos commented 2 years ago

Just add a comment in the script, and those who have problems just uncomment it.And maybe ad some FAQ later on explain it.

Willy-JL commented 2 years ago

Perhaps keep an array of the official domains and loop through them to see the first that works (?)

1337x.to is not blocked for me so I can't easily test how a loop like this would work :/, otherwise I'd do this myself

Also @Bugswriter what DNS are you using? Cos it might be simply blocked by your ISP's DNS...

Willy-JL commented 2 years ago

I made a little test script, but I don't know if a ping will be sufficient...

#!/bin/bash

declare -a domains
domains+=("1337x.to")
domains+=("1337x.st")
domains+=("1337x.ws")
domains+=("1337x.eu")
domains+=("1337x.se")
domains+=("1337x.is")
domains+=("1337x.gd")
domains+=("1337x.wtf")  # This is not an official 1337x domain, be careful when using it!

i=0
while true ; do
  domain="${domains[$i]}"
  ((i+=1))
  ping -i 0.002 -c 1 "$domain" > /dev/null 2>&1 || continue
  break
done
echo "Found domain '$domain'"

Please @Bugswriter or someone else with 1337x.to blocked can confirm if this works?

vveig4 commented 2 years ago

Your script does work in bash for selecting an unblocked domain. However all the official 1337x domains have Cloudflare ddos protection, which messes up the curl request for some systems.

Willy-JL commented 2 years ago

Your script does work in bash for selecting an unblocked domain. However all the official 1337x domains have Cloudflare ddos protection, which messes up the curl request for some systems.

ah, you mean that pinging and sending a request right after messes up the request? then instead of ping + curl it could just run the actual curl request in the loop...? also i just realized that if all domains fail, then this loop will stall...

Willy-JL commented 2 years ago

@vveig4 can you try the latest push i made?

Zekiah-A commented 2 years ago

When the imposter is sus