Bloqueio de anúncios Youtube e Spotify no Router Technicolor tg784n v3

Escrevo este tópico porque detesto anuncios e estou farto de ter de instalar mil e um adblockers em dispositivos diferentes...
Por isso aqui vai:
1º Ter o Router technicolor tg784n v3 com acesso root (quem não tiver é só procurar no fórum, eu próprio segui um)
2º Entrar no modem por telnet e na conta com acesso root
3º Criar uma nova entrada na firewall para as novas regras:
Código
firewall level add name=Anuncios readonly=disabled udptrackmode=loose service=enabled proxy=enabled text="As minhas regras" policy=accept
4º Criar as regras (como o modem não aceita o url dos anúncios temos de colocar os ip)
Código
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=104.20.85.235
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=104.20.86.235
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=104.68.181.188
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=107.23.83.89
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=108.177.15.95
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=151.101.16.246
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=152.163.66.131
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=162.248.16.53
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=184.106.2.94
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=184.86.209.54
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.196.114
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.196.178
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.196.226
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.196.227
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.196.98
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.198.115
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.198.165
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=194.132.198.198
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=213.30.18.143
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.198.162
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.198.226
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.33
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.34
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.38
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.210.34
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.212.66
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=23.212.108.127
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=23.212.108.143
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=23.214.151.213
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=23.23.141.33
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=23.23.151.147
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=37.157.4.28
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=37.157.6.234
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=37.157.6.236
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.0.7.137
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.1.67.159
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.200.11.20
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.200.21.172
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.203.153.120
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.205.89.20
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.206.170.25
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.207.87.109
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.72.138.239
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.72.223.96
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.73.179.4
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=52.73.239.37
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.163.241.177
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.173.255.40
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.127
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.131
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.143
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.229
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.37
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.70
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.78
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.230.11.94
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.236.196.248
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.72.119.111
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=54.87.99.213
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=68.232.34.151
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=69.172.216.55
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.218.238
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.218.230
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.218.226
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=104.64.68.240
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=23.13.225.70
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.217.168
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.218.238
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=209.85.144.156
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.217.162
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.218.232
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=209.85.201.95
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=66.102.1.95
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.210.162
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.211.194
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.214.162
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=74.125.100.168
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.138
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=74.125.133.95
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.210.130
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.130
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=74.125.8.155

5º Ativar a nova firewall criada
Código
firewall level set name=Anuncios
 
Última edição:
Aqui ficam mais uns do spotify

firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.210.130
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.211.226
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.130
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.210.134
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.214.166
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.201.134
firewall rule add chain=forward_level_Anuncios index=1 name=YouSpoti srcintf=lan dstintf=wan log=disabled state=enabled action=deny dstip=216.58.210.166


Se souberem mais endereços é favor partilhar! Gracias
 
Última edição:
Eu iria antes para uma solução tipo Pi-hole.net que podes por a correr facilmente numa maquina virtual ou mesmo no rasp ou qq máquina que corra linux lol
 
Obrigado pela dica!
Só tentei fazer a custo zero...
Desconhecia por completo e gostei do que vi no site da Pi-hole!
O problema é mesmo não ter um Raspberry...nem linux....e máquina virtual...
Será que poderias me indicar se é possível fazer em sistema OSX?
 
Obrigado pela dica!
Só tentei fazer a custo zero...
Desconhecia por completo e gostei do que vi no site da Pi-hole!
O problema é mesmo não ter um Raspberry...nem linux....e máquina virtual...
Será que poderias me indicar se é possível fazer em sistema OSX?

Boas sim é possível, instala o oracle virtual box + o iso do ubuntu server por exemplo, configuras a máquina com 1 core e 512 de ram.
 
Claro que não!
Estás a falar em fazer a configuração numa só máquina contra a configuração em N máquinas.
mesmo que seja em 5 maquinas para 99% do pessoal penso que é mais fácil fazê lo que do que conseguir acesso root ao router, fazer uma ligação telnet (que só isso requer um bom tutorial) e intruduzir tinha a linha.

O ficheiro host crias apenas um, e é so copiar para os vários computadores. Claro que se for para mais do que isso, já é uma opcao a ponderar.
 
Mas para telemóveis e tablets novos implica acesso root, logo perda da garantia...
E na TV com youtube? Como colocas o ficheiro host? (Cá em casa é o mais utilizado pelos miúdos)
A ideia é mesmo reduzir o tempo que se dedica a cada máquina .
 
dai que eu disse excluindo equipamentos moveis... also, nao perdes a garantia por fazer root.

Seja como for isso é um tutorial util mas para um equipamento especifico, devias partilhar como obter o acesso root e como fazer o telnet, visto que hoje em dia nem o telnet esta activo no windows.
 
Boas sim é possível, instala o oracle virtual box + o iso do ubuntu server por exemplo, configuras a máquina com 1 core e 512 de ram.
Obrigado!
Acho que vou partir para a solução do Raspberry! Só preciso é de satisfazer uma dúvida que não consigo encontrar resposta...
Para utilizar o pi-hole tenho que alterar o DHCP no router e forçar a atribuição do dns para o Raspberry.
Ao alterar o dns no router não vou perder o sinal de televisão?
 
dai que eu disse excluindo equipamentos moveis... also, nao perdes a garantia por fazer root.

Seja como for isso é um tutorial util mas para um equipamento especifico, devias partilhar como obter o acesso root e como fazer o telnet, visto que hoje em dia nem o telnet esta activo no windows.
Segui este tutorial que é para Vodafone.
https://forum.zwame.pt/threads/acesso-root-aos-routers-thompson-vodafone-tg784n-v3-8-g-m-1.896695/
Fiquei um pouco assustado porque depois de fazer demora uns 5 a 10 min até o modem repor todas as configurações, mas funciona.
Quanto ao Windows se for o 10 ativa seguindo este tutorial :
https://www.rootusers.com/how-to-enable-the-telnet-client-in-windows-10/
 
Última edição:
Obrigado!
Acho que vou partir para a solução do Raspberry! Só preciso é de satisfazer uma dúvida que não consigo encontrar resposta...
Para utilizar o pi-hole tenho que alterar o DHCP no router e forçar a atribuição do dns para o Raspberry.
Ao alterar o dns no router não vou perder o sinal de televisão?

Isso da tv não te sei responder.
Como te disse podes testar numa máquina virtual antes de gastares dinheiro.
Outra coisa é que não é necessário ser um Raspberry PI , podes por exemplo comprar um OrangePI One que custa cerca de 13€ que serve perfeitamente ou um raspberry pi zero se o arranjares a bom preço.

Estou neste momento a fazer a instalação numa máquina virtual, se conseguir deixar isto com um tamanho aceitável posso partilhar um link para quem quiser fazer download e experimentar.
 
Conforme prometido aqui fica a imagem pronta a usar.
Usei Oracle VirtualBox.
Descompactem e no virtualbox vão a File, Import appliance.
User: pi-hole
pass: 123456
Ip:192.168.1.250 <--- Este é o ip para configurarem como dns
gateway : 192.168.1.1

Se estes settings de rede não servem para quem estiver a testar entrem na consola do virtualbox e editem o ficheiro /etc/network/interfaces.

https://drive.google.com/open?id=0B7x90MRmDa1cNG54UjRKRXpEeE0
 
Conforme prometido aqui fica a imagem pronta a usar.
Usei Oracle VirtualBox.
Descompactem e no virtualbox vão a File, Import appliance.
User: pi-hole
pass: 123456
Ip:192.168.1.250 <--- Este é o ip para configurarem como dns
gateway : 192.168.1.1

Se estes settings de rede não servem para quem estiver a testar entrem na consola do virtualbox e editem o ficheiro /etc/network/interfaces.

https://drive.google.com/open?id=0B7x90MRmDa1cNG54UjRKRXpEeE0
Obrigado kasmafan! Mas isto já é demais para os meus conhecimentos... esbarrei por completo no Ubuntu. Nunca trabalhei com sistemas Linux e as minhas capacidades são limitadas.... Obrigado na mesma!
 
Back
Topo