[FUG-BR] Problema de firewall PF

Diogo Dalfovo b1n4r1w0rm em gmail.com
Segunda Outubro 7 18:50:35 BRT 2013


Boa noite pessoal,

Bom eu acredito que seja algo simples de resolver mas não estou achando uma
solução.
Estou montando um firewall com a seguinte configuração:

root em fw:~ # pfctl -sr
...
block drop in log inet all label "BLOQUEIO PADRAO ENTRADA IPV4"
block drop out log inet all label "BLOQUEIO PADRAO SAIDA IPV4"
pass in log quick on vlan3 inet proto icmp from $IP_EXTERNO to 10.2.2.30
icmp-type echoreq code 0 keep state label "libera icmp WAN" rtable 1

root em fw:~ # pfctl -sn
binat on vlan3 inet from 10.2.2.30 to any -> $IP_EXTERNO

Neste IP eu tenho nat 1:1

Disparo ping para o $IP_EXTERNO funciona sem problema algum. Depois eu
removo a regra de liberação, mando recarregar as regras e maldito continua
pingando.
Se depois de um tempo sem ping volto a disparar dai sim ele faz o bloqueio.

00:00:04.999486 rule 2..16777216/0(match): block in on vlan3: x.x.x.x >
10.2.2.30: ICMP echo request, id 11861, seq 8081, length 40
00:00:05.000195 rule 7..16777216/0(match): pass in on vlan3: x.x.x.x >
10.2.2.30: ICMP echo request, id 11861, seq 8082, length 40
00:20:08.074826 rule 2..16777216/0(match): block in on vlan3: x.x.x.x >
10.2.2.30: ICMP echo request, id 47373, seq 9262, length 40

Precisa de alguma configuração no "options"? set timeout qualquer coisa
para quando eu remover a regra e recarregar ele ja fazer o bloqueio?
Como se ele tivesse mantendo a sessão anterior ainda liberada.

Diogo Dalfovo


Mais detalhes sobre a lista de discussão freebsd