Remova Propagandas E Temporizadores Ao Baixar Filmes

Desativa Temporizadores Decrescentes e Ads em sites brasileiros para baixar filmes em sites de torrent que te redirecionam para outros sites antes de liberar o download.

目前为 2021-04-17 提交的版本。查看 最新版本

// ==UserScript==
// @name         Remova Propagandas E Temporizadores Ao Baixar Filmes
// @namespace    hacker09
// @version      1.0.0.20
// @description  Desativa Temporizadores Decrescentes e Ads em sites brasileiros para baixar filmes em sites de torrent que te redirecionam para outros sites antes de liberar o download.
// @author       hacker09
//@noframes
// @include      *://www.google.*
// @include      *://www.arnolds.com.br/*
// @include      /^(https?:\/\/)(www\.)?(adrenalinagames|mastercuriosidadesbr|agregadordigital)(\.com)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(ondebaixa|ondebaixo|vmstorrent|clubetorrent|blurayfilmes|baixotorrents|lacraiatorrent|torrentdublado|completotorrent|adorocinematorrent|seriesfilmestorrents|filmebaixar|pirate-filmes|trixfilmes|aoseugosto|bludvtorrent|acervotorrents|filmestorrentbr|cinefilmesbrasil|topfilmestorrents)(\.com)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(filmesmega|ondeeubaixo|megatorrentshd|wolverdonfilmes|comandofilmes4k|thepiratesfilmes|thepiratefilmestorrent|lapumia|supertorrent|lapumiatorrent|baixafilme|comandotorrent|baixarfilmetorrent|torrentdosfilmes2|seriesfilmestorrent)(\.net)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(torrentool|torrentoon|hidratorrent|ondeeubaixo|thepirate-day|todosfilmeshd)(\.org)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(thepiratefilmetorrent|thepiratefilmestorrent|comandotorrent)(\.tv)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(bluraytorrent|filmestorrentbrasil)(\.com\.br)(\/.*)?/
// @match        *://baixar.club/*
// @match        *://megatorrents.co/*
// @match        *://www.bluf.online/*
// @match        *://baixarfilmes.top/*
// @match        *://filmestorrent.vip/*
// @match        *://www.baixarfilmes.ws/*
// @match        *://torrentdosfilmes.in/*
// @match        *://filmesviatorrents.biz/*
// @match        *://br.filmestorrent.gratis/*
// @match        *://www.thepiratefilmestorrent.me/*
// @exclude      /^(https:\/\/thepirate-day\.org\/)(novidades-torrent-\d+|atividade|.+-torrent-magnet|livros-pdf-download|top-100-torrent-the-pirate-day|lancamentos-torrent|atores|atrizes|em-breve-para-download|netflix|filmes-vencedores-do-oscar|series-\d+-torrent|filmes-dublados-torrent|series-dublado|estou-com-sorte-the-pirate-day-download-torrent-\d+|filmes-e-series-dublados-dual-audio-legendados-download-torrent|pedidos|avaliacoes|dmca|category|membros|filmes-\d+-torrent-magnet|filmes-torrent-\d+|series-torrent-\d+|filmes-tecnologia-torrent|filmes-.+-torrent-\d+)(\/.*)?/

// Abaixo segue a lista dos piores websites para se baixar e ver filmes, eles serão automaticamente redirecionados para o google. São todos sites cheios de propagandas, e que teoricamente deveriam permitir assistir e/ou baixar filmes, porem não e possível fazer isso nesse sites falsos.
// @include      /^(https?:\/\/)(www\.)?(boutv|yts-yts|yikiking|gumroad|bulktorrent|laostelephone|filmesdetv|dubladotorrent)(\.com)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(yify-yify|baixartorrent)(\.net)(\/.*)?/
// @include      /^(https?:\/\/)(www\.)?(kristi0520|boardiweb|webtorrentnet|theexconsofymm)(\.blogspot\.com)(\/.*)?/
// @match        *://katmoviehd.world/*
// @match        *://aquitemfilmes.info/*
// @match        *://elitedosdownloads.club/*
// @match        *://baixarfilmestorrents.biz/*
// @match        *://filmestvdublado.home.blog/*
// @match        *://filmestorrentdownload.com.br/*
// @match        *://filmeshdcompletos1.podbean.com/*
// @icon         https://www.pngitem.com/pimgs/m/464-4640800_adblock-block-ads-icon-png-transparent-png.png
// @grant        GM_registerMenuCommand
// @grant        GM_setValue
// @grant        GM_getValue
// @grant        window.close
// @run-at       document-idle
// ==/UserScript==
(function() {
  'use strict';
  if (top.location.host.match('www.google')) /*Make sure to run only on google */ { //Starts the if condition
    GM_registerMenuCommand("Desativar/Ativar Marcação", ActivateOnGoogle); // Adds an option to the menu
  } // Finishes the if condition

  if (GM_getValue("ActivateOnGoogle") !== true && GM_getValue("ActivateOnGoogle") !== false) //If the value doesn't exist define it as true
  { //Starts the if condition
    GM_setValue("ActivateOnGoogle", true); // Defines the variable as true
  } // Finishes the if condition

  function ActivateOnGoogle() // Function to activate/deactivate the highlight on google
  { //Starts the function ActivateOnGoogle
    if (GM_getValue("ActivateOnGoogle") === true) //If the last config was true, define as false
    { //Starts the if condition
      GM_setValue("ActivateOnGoogle", false); //Defines the variable as false
    } // Finishes the if condition
    else { // If the last config was false, define as true
      GM_setValue("ActivateOnGoogle", true); //Defines the variable as true
      location.reload(); //Reloads the page
    } // Finishes the else condition
  } // Finishes the function ActivateOnGoogle

  var BlockedWebsites = new RegExp(/^(https?:\/\/)?(www\.)?(todosfilmeshd.org|filmestvdublado.home.blog|aquitemfilmes.info|filmesdetv.com|filmeshdcompletos1.podbean.com|elitedosdownloads.club|laostelephone.com|kristi0520.blogspot.com|theexconsofymm.blogspot.com|dubladotorrent.com|boutv.com|webtorrentnet.blogspot.com|boardiweb.blogspot.com|gumroad.com|yts-yts.com|yify-yify.net|yikiking.com|bulktorrent.com|katmoviehd.world|baixartorrent.net|baixarfilmestorrents.biz|filmestorrentdownload.com.br)/);

  if (top.location.host.match('www.google') && GM_getValue("ActivateOnGoogle") === true) /*Make sure to run only on google */ { //Starts the if condition
    function HighLight() //Creates a function to HighLight the websites
    { //Starts the function HighLight
      var PageLinks = document.querySelectorAll("cite"); //Add all page links total number to a variable
      for (var i = PageLinks.length; i--;) { //Starts the for condition
        if (PageLinks[i].innerHTML.match(/^(https?:\/\/)?(www\.)?(thepirate-day.org|ondebaixa.com|ondebaixo.com|torrentool.org|torrentoon.org|filmesmega.net|megatorrents.co|ondeeubaixo.net|ondeeubaixo.org|hidratorrent.org|blurayfilmes.com|megatorrentshd.net|lacraiatorrent.com|torrentdublado.com|completotorrent.com|seriesfilmestorrents.com|trixfilmes.com|baixarfilmetorrent.net|bludvtorrent.com|filmebaixar.com|baixar.club|bluraytorrent.com.br|supertorrent.net|baixafilme.net|aoseugosto.com|br.filmestorrent.gratis|pirate-filmes.com|baixarfilmes.ws|thepiratefilmestorrent.tv|thepiratefilmestorrent.me|thepiratefilmestorrent.net|thepiratesfilmes.net|filmestorrent.vip|filmesviatorrents.biz|comandofilmes4k.net|lapumia.net|lapumiatorrent.net|baixarfilmes.top|torrentdosfilmes.in|bluf.online|vmstorrent.com|clubetorrent.com|baixotorrents.com|wolverdonfilmes.net|adorocinematorrent.com|comandotorrent.net|thepiratefilmetorrent.tv|torrentdosfilmes2.net|acervotorrents.com|filmestorrentbr.com|filmestorrentbrasil.com.br|cinefilmesbrasil.com|topfilmestorrents.com|comandotorrent.tv|seriesfilmestorrent.net)/) !== null) //If the Result contains any of these links
        { //Starts the if condition
          PageLinks[i].style.backgroundColor = 'rgba(255, 255, 0, 0.5)'; //Change the element background to Yellow
        } //Finishes the if condition
        if (PageLinks[i].innerHTML.match(BlockedWebsites) !== null) //If the Result contains any of the Blocked Websites
        { //Starts the else condition
          PageLinks[i].style.backgroundColor = 'rgba(255, 0, 0, 0.2)'; //Change the element background to Red
        } //Finishes the else condition
      } //Finishes the for condtiion
    } //Finishes the function HighLight
    HighLight(); //Starts the HighLight Function

    new MutationObserver(async function() { //If the results page changes anything (If the user uses anything like the endless google scripts)
      HighLight(); //Starts the HighLight Function
    }).observe(document.querySelector("#rcnt"), { //Defines the element and characteristics to be observed
      attributes: true,
      attributeOldValue: true,
      characterData: true,
      characterDataOldValue: true,
      childList: true,
      subtree: true
    }); //Finishes the definitions that will be observed

  } //Finishes the if condition

  // The codes below closes the trash websites
  if (top.location.host.match(BlockedWebsites) !== null || top.location.host.match('agregadordigital.com') !== null) /*Make sure to run only on the blocked websites*/ { //Starts the if condition
    window.top.close(); //Close the actual tab
  } // Finishes the if condition

  if (!top.location.host.match('www.google')) /*Make sure to not run only on google */ { //Starts the if condition
    if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) /*If the browser is using the dark theme */ { //Starts the if condition
      document.title = '🏳️☠️ ' + document.title; //Add the pirate flag emoji the tab title
    } // Finishes the if condition
    else //If the browser is using the light theme
    { //Starts the else condition
      document.title = '🏴‍☠️ ' + document.title; //Add the pirate flag emoji the tab title
    } // Finishes the else condition
  } // Finishes the if condition

  if (!top.location.host.match('www.google') && top.location.host.match(/(^(www\.)?(trixfilmes|baixarfilmetorrent|bludvtorrent|filmebaixar|baixar|bluraytorrent|supertorrent|baixafilmes?|aoseugosto|filmestorrent|pirate-filmes|thepiratesfilmes|filmesviatorrents|thepiratefilmes?torrent.tv|thepiratefilmestorrent|comandofilmes4k|lapumia|lapumiatorrent|torrentdosfilmes|bluf|torrentdosfilmes2|acervotorrents|filmestorrentbr|filmestorrentbrasil|cinefilmesbrasil|topfilmestorrents|comandotorrent|seriesfilmestorrent))(.*)?/) === null) /*Make sure to not run on google, neither on websites that should only be highlighted on google (The thepiratefilmestorrent.tv,thepiratefilmetorrent.tv,thepiratefilmestorrent.me,thepiratefilmestorrent.net,filmestorrent.vip,filmesviatorrents.biz,comandofilmes4k.net,torrentdosfilmes2.net,acervotorrents.com,filmestorrentbr.com,filmestorrentbrasil.com.br,cinefilmesbrasil.com,topfilmestorrents.com,www.comandotorrent.tv,seriesfilmestorrent.net sites shouldn't only be highlighted, but the codes below doesn't work on them) */ { //Starts the if condition
    /*Function.prototype.call = function(){};*/
    Function.prototype.apply = function() {}; //Disable JS on the website so that the download buttons will load without ads
    /*Function.prototype.bind = function(){};*/
  } // Finishes the if condition

  if (top.location.host === 'www.mastercuriosidadesbr.com' || top.location.host === 'www.arnolds.com.br') /*Make sure to run only on mastercuriosidadesbr.com and on www.arnolds.com.br */ { //Starts the if condition
    document.querySelector("#colunas").remove(); //Remove the page ads
    document.querySelector("#colunas").remove(); //Remove the page ads
    window.open(document.querySelector('a[href*="magnet"]').href, "_self"); //Open the unprotected link
    document.querySelector("#aviso").style.display = "none"; //Disable Counter Text
    document.querySelector("#loko").style.display = "none"; //Disable Fake Download Button
    document.querySelector("#baixar").style.display = ""; //Enable the Real Download Button
    document.oncontextmenu = function() {}; /*Enables the Right Click */
  } // Finishes the if condition

  if (top.location.host === 'www.adrenalinagames.com') /*Make sure to run only on adrenalinagames.com */ { //Starts the if condition
    document.getElementById('link0').style.display = "none"; //Hides the fake download button
    document.getElementById('link').style.display = "block"; //Shows the real download button
    document.getElementById('msg').style.display = "none"; /*Disable the message "Clique uma vez em um dos anuncios,aguarde 20 segundos na pagina que ira abrir, apos isso o seu download sera liberado" */
  } // Finishes the if condition

  if (top.location.host.match(/(^(www\.)?(megatorrents|megatorrentshd|thepiratefilmestorrent|filmestorrent|filmesviatorrents|lapumia|baixarfilmes|comandofilmes4k|thepiratesfilmes|wolverdonfilmes|bluf|pirate-filmes|baixafilme|bludvtorrent|baixarfilmetorrent))(.*)?/) !== null) /*Make sure to run on the correct websites only */ { //Starts the if condition
    Array.from(document.querySelectorAll('a[target="_blank"]')).forEach(link => link.removeAttribute('target')); //Disable target = "_blank" on the website
  } //Finishes the if condition

  if (top.location.host === 'www.torrentdosfilmes2.net' || top.location.host === 'www.comandotorrent.tv') /*Make sure to run only on torrentdosfilmes2.net or on www.comandotorrent.tv */ { //Starts the if condition
    Array.from(document.querySelectorAll("a[href*='javascript:void();']")).forEach(Element => Element.onclick = async function() { //To all "fake" link elements and add an advent listener to the fake link elements
      setTimeout(function() {
        window.open(document.querySelector("#down").value, "_self");
      }, 0); //Get and open the real unprotected magnet link
    }); //Finishes the forEach condition
  } // Finishes the if condition

  if (top.location.host === 'seriesfilmestorrent.net') /*Make sure to run only on seriesfilmestorrent.net */ { //Starts the if condition
    Array.from(document.querySelectorAll("a[href*='?code=']")).forEach(function(element, index) { //To all encoded link elements
      element.addEventListener("click", function(e) { //Add an advent listener to the encoded link elements
        if (index === 0 && index.length > 1) { //If it's the first element
          var RemoveStrings = reverseString(btoa("@X" + document.title.replace('🏳️☠️ ', '').replace('🏴‍☠️ ', ''))); //Remove these strings
          var Base64String = reverseString(this.href.split(RemoveStrings)[1]); //Get the reverse Base64String code
        } //Finishes the if condition
        else { //Starts the else condition if it's NOT the first element
          Base64String = reverseString(this.href.split('?code=')[1]); //Get the reverse Base64String code
        } //Finishes the else condition

        var DecodedLink = decodeURIComponent(atob(Base64String)); //Decode the Base64 Encoded link
        window.open(DecodedLink, "_self"); //Open the decoded download link
        e.preventDefault(); //Prevent the default encoded link from being opened
      }); //Finishes the onclick event listener

    }); //Finishes the forEach condition
  } //Finishes the if condition

  if (top.location.host === 'filmestorrentbrasil.com.br') /*Make sure to run only on filmestorrentbrasil.com.br */ { //Starts the if condition
    Array.from(document.querySelectorAll("a[href*='?id=']")).forEach(Element => Element.onclick = async function(e) { //To all encoded link elements and add an advent listener to the encoded link elements
      window.open(atob(this.href.split('?id=')[1]), "_self"); //Decode and open the real unprotected download link
      e.preventDefault(); //Prevent the default encoded link from being opened
    }); //Finishes the forEach condition
  } // Finishes the if condition

  if (top.location.host === 'topfilmestorrents.com') /*Make sure to run only on topfilmestorrents.com */ { //Starts the if condition
    Array.from(document.querySelectorAll("a[href*='?token=']")).forEach(Element => Element.onclick = async function(e) { //To all encoded link elements and add an advent listener to the encoded link elements
      window.open(CryptoJS.AES.decrypt(atob(this.href.split('?token=')[1]), '391si8WU89ghkDB5').toString(CryptoJS.enc.Utf8), "_self"); //Decode,do the reverse cryptographic AES process and finally open the real unprotected download link
      e.preventDefault(); //Prevent the default encoded link from being opened
    }); //Finishes the forEach condition
  } // Finishes the if condition

  if (top.location.host === 'acervotorrents.com' || top.location.host === 'filmestorrentbr.com' || top.location.host === 'cinefilmesbrasil.com') /*Make sure to run only on acervotorrents.com,filmestorrentbr.com or on cinefilmesbrasil.com */ { //Starts the if condition
    Array.from(document.querySelectorAll("a[href*='?token=']")).forEach(Element => Element.onclick = async function(e) { //To all encoded link elements and add an advent listener to the encoded link elements
      window.open(atob(this.href.split('?token=')[1]), "_self"); //Decode and open the real unprotected download link
      e.preventDefault(); //Prevent the default encoded link from being opened
    }); //Finishes the forEach condition
  } // Finishes the if condition

  if (top.location.host === 'completotorrent.com') /*Make sure to run only on completotorrent.com */ { //Starts the if condition
    document.querySelector("#myNavbar > ul > li:nth-child(5)").remove(); //Removes the fake "Jogos" download button
  } //Finishes the if condition

  if (top.location.host === 'megatorrentshd.net' && document.querySelector("div#categoria.box_item.center-widget") !== null) /*Make sure to run only on megatorrentshd.net */ { //Starts the if condition
    document.querySelector("div#categoria.box_item.center-widget").innerHTML = document.querySelector("div#categoria.box_item.center-widget").innerHTML; //Remove the advent listeners
    for (var i = document.querySelectorAll("input[onclick='this.focus();this.select()']").length; i--;) { //Starts the for condition
      document.querySelectorAll("[href*='javascript:void();']")[i].href = document.querySelectorAll("input[onclick='this.focus();this.select()']")[i].value; //Removes the fake link and adds the correct unprotected link for all buttons
    } // Finishes the for condition
  } // Finishes the if condition

  if (top.location.host.match('thepiratesfilmes.net') !== null) /*Make sure to run only on thepiratesfilmes.net */ { //Starts the if condition
    Array.from(document.querySelectorAll("a[href*='magnet']")).forEach(Element => Element.onmouseover = async function() { //To all magnet link elements and add an advent listener to the link element
      this.href = this.href.match(/(?:(http)?(magnet.*))/); //Erase anything in from of the magnet link and change the element link to have only the correct link
    }); //Finishes the forEach condition
  } // Finishes the if condition

  if (top.location.host.match(/(^(www\.)?(thepiratefilmes?torrent|thepiratesfilmes|filmestorrent|filmesviatorrents|comandofilmes4k|wolverdonfilmes))(.*)?/) !== null) /*Make sure to run on the correct websites only */ { //Starts the if condition
    var SavedUnprotectedLinks = []; //Creates a new global array
    var AllPageLinks = document.querySelectorAll("a[href*='magnet:?xt=urn:btih:']"); //Select and store all unprotected magnet links on the page
    for (var i = 0, max = AllPageLinks.length; i < max; i++) /*For every single link Do... */ { //Starts the for condition
      SavedUnprotectedLinks.push(AllPageLinks[i].href); //Add the unprotected direct magnet link to the array
    } //Finishes the for condition

    window.onload = function() { //Starts the function when the website finished loading
      for (var i = 0, max = AllPageLinks.length; i < max; i++) /*For every single link Do... */ { //Starts the for condition
        AllPageLinks[i].href = SavedUnprotectedLinks[i]; //Add the Saved Unprotected Link to AllPageLinks
      } //Finishes the for condition
    }; //Finishes the onload function
  } //Finishes the if condition

  if (top.location.host.match(/thepiratefilmes?torrent/) !== null) /*Make sure to run only the thepiratefilmestorrent websites and on thepiratefilmetorrent.tv */ { //Starts the if condition
    var DownloadBTNs = document.querySelectorAll('img.alignnone.wp-image-7.size-medium'); //Select and store the total buttons number
    for (var i = 0, max = DownloadBTNs.length; i < max; i++) /*For every single button Do... */ {
      DownloadBTNs[i].src = 'https://' + location.host + '/wp-content/uploads/2016/05/MAGNET-LINK.fw_-300x77.png';
    } /*Finishes the for condition */
  } //Finishes the if condition

  if (top.location.host === 'thepirate-day.org') /*Make sure to run only on thepirate-day.org */ { //Starts the if condition
    var SavedProtectedLink = document.querySelector("div.entry-content > a").href; //Create a new variable to save the protected link

    window.onload = function() { //Starts the function when the website finished loading
      document.querySelector("div.entry-content > a").removeAttribute("onclick"); //Remove the onclick attribute of the element
      document.querySelector("div.entry-content > a").href = 'javascript:void(0);' //Remove the link of the element
    }; //Finishes the onload function

    document.querySelector("div.entry-content > a").addEventListener("click", async function() { //Starts the onclick advent listener function
      (async () => { //Creates a function to get the unprotected magnet link and Starts the function
        const response = await (await fetch('https://api.allorigins.win/raw?url=' + SavedProtectedLink)).text(); //Fetch
        const newDocument = new DOMParser().parseFromString(response, 'text/html'); //Parses the fetch response

        if (newDocument.querySelectorAll("img.alignnone").length === 1) //If there's only 1 download button
        { //Starts the if condition
          window.open(newDocument.body.innerHTML.match(/['"](magnet.*?)['"]/g)[0].replace(/"/g, ''), "_self"); //Open the unprotected magnet link
        } // Finishes the if condition
        else //If there's more than 1 download button
        { //Starts the else condition
          window.open(SavedProtectedLink, "_blank"); //Open the "protected magnet link"
        } // Finishes the else condition
      })(); //Finishes the async function
    }); //Finishes the onclick advent listener function
  } // Finishes the if condition

})();