Can not retrive Source code of a website(getting another source code instead)

116 views Asked by At

I'm trying to retrive source code for this website but instead I'm getting another source code where it says " Please wait while we try to verify your browser...
If you are stuck on this page disable your browser addons ..." is there any way around that? P.s (I'm runing that on my phone that has no addons)

Code:

recTorrentsURl = new URL("https://rarbg.to/torrents.php");
HttpsURLConnection con = null;
con = (HttpsURLConnection) recTorrentsURl.openConnection();
con.setRequestMethod("GET");

is = con.getInputStream();
        BufferedReader br = new BufferedReader(new InputStreamReader(is));
        StringBuilder total= new StringBuilder();
        String line;

        while((line= br.readLine())!=null){
            total.append(line).append('\n');

        }
1

There are 1 answers

1
iCeptic On

it looks like the website has some for of ddos/script protection(cloudflare i think)

if you can change your "tool" to change the headers then it should be able to bypass this.

for example httrak(tool) you can change your request headers and set a delay to wait x amount of seconds before pulling all the content which will bypass this issue of please wait whilst we verify your browser..