Buscar
 
 

Resultados por:
 


Rechercher Busca avançada

Últimos assuntos
Relogio

Bloquear Facebook

Ver o tópico anterior Ver o tópico seguinte Ir em baixo

Bloquear Facebook

Mensagem  juk em Seg Jun 03, 2013 4:41 pm

Código:

#Desbloqueio do https://facebook.com para IP´s especifico
#PEGA LISTA DE IP´S LIBERADOS NO DANSGUARDIAN
for IPList in `grep -v "^#" /etc/brazilfw/dansguardian/exceptioniplist`; do
iptables -A FORWARD -p tcp -s $IPList -d 69.63.176.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s $IPList -d 69.63.176.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s $IPList -d 66.220.144.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s $IPList -d 66.220.144.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s $IPList -d 66.220.158.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s $IPList -d 66.220.158.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s $IPList -d 69.171.224.0/19 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s $IPList -d 69.171.224.0/19 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s $IPList -d 69.171.229.0/19 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s $IPList -d 69.171.229.0/19 --dport 443 -j ACCEPT
done
#Bloqueio do https://www.facebook.com (bloqueio geral)
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 69.63.176.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 69.63.176.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 66.220.144.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 66.220.144.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 66.220.158.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 66.220.158.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 69.171.224.0/19 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 69.171.224.0/19 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 69.171.229.0/19 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 69.171.229.0/19 --dport 443 -j REJECT

Desta maneira ele pega os ips que estão na lista do exception do dansguardian, ou se preferir vc mesmo colocar um ip
Código:

#Desbloqueio do https://facebook.com para IP´s especifico
iptables -A FORWARD -p tcp -s 192.168.0.20 -d 69.63.176.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s 192.168.0.20 -d 69.63.176.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s 192.168.0.20 -d 66.220.144.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s 192.168.0.20 -d 66.220.144.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s 192.168.0.20 -d 66.220.158.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s 192.168.0.20 -d 66.220.158.0/20 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s 192.168.0.20 -d 69.171.224.0/19 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s 192.168.0.20 -d 69.171.224.0/19 --dport 443 -j ACCEPT
iptables -A FORWARD -p tcp -s 192.168.0.20 -d 69.171.229.0/19 --dport 443 -j ACCEPT
iptables -A FORWARD -p udp -s 192.168.0.20 -d 69.171.229.0/19 --dport 443 -j ACCEPT
done
#Bloqueio do https://www.facebook.com (bloqueio geral)

iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 69.63.176.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 69.63.176.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 66.220.144.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 66.220.144.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 66.220.158.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 66.220.158.0/20 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 69.171.224.0/19 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 69.171.224.0/19 --dport 443 -j REJECT
iptables -A FORWARD -p tcp -s 192.168.0.0/24 -d 69.171.229.0/19 --dport 443 -j REJECT
iptables -A FORWARD -p udp -s 192.168.0.0/24 -d 69.171.229.0/19 --dport 443 -j REJECT
retirado de: http://www.brazilfw.com.br/forum/viewtopic.php?f=77&t=84528
avatar
juk

Mensagens : 225
Data de inscrição : 02/04/2012

Ver perfil do usuário

Voltar ao Topo Ir em baixo

Ver o tópico anterior Ver o tópico seguinte Voltar ao Topo


 
Permissão deste fórum:
Você não pode responder aos tópicos neste fórum