"Eugene M. Minkovskii" <[EMAIL PROTECTED]> writes: > block in log on $ext_ip inet from any to $ext_ip label $ext_ip > pass in on $ext_ip inet from any to $ext_ip port 22 keep sate > > As you can see, ssh packets match to all rule and pass in because > last rule win. Does it mean, that I can't see ssh's packet using > command > # pfctl -sl
here you label the blocked packets but not the ones you pass, which means your ssh packets would count toward the packets passed counter only. > And if I use > > block in log on $ext_ip inet from any to $ext_ip label $ext_ip > pass in on $ext_ip inet from any to $ext_ip port 22 keep sate label > $ext_ip > > ... I see label twice ? No. But both rules would increment the $ext_ip counter, which means that your $ext_ip counter would be essentially packet totals. Last matching rule wins (with state instead of sate it would work), so each packet increments the relevant counters only once. > Perhaps you know where I can find workable example of this? Randal Schwartz has a nice article called "Monitoring Net Traffic with OpenBSD's Packet Filter" at http://www.samag.com/documents/s=9053/sam0403j/0403j.htm -- Peter N. M. Hansteen, member of the first RFC 1149 implementation team http://www.blug.linux.no/rfc1149/ http://www.datadok.no/ http://www.nuug.no/ "First, we kill all the spammers" The Usenet Bard, "Twice-forwarded tales" _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"