Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Iptables logging
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
Blue Fox
Apprentice
Apprentice


Joined: 09 Apr 2004
Posts: 216

PostPosted: Sat Jul 10, 2004 7:43 pm    Post subject: Iptables logging Reply with quote

Hi guys, i've googled, searched, seeked, looked for but no tutorial, howto or article have done this sucessfully.

What I want
Make the iptables' related stuff go to the file /var/log/iptables and be removed from the dmesg output.

What I have
Syslog-ng and made my iptables' rules in fwbuilder, so all my log entries looks like this
Code:
 RULE 2 -- DENY IN=eth0 OUT= MAC=xxxxxxxxxxx SRC=xxxxx DST=xxxxx LEN=xx TOS=xxxx PREC=xxxx TTL=xx ID=xxxxx PROTO=xxx SPT=xxxxx DPT=x LEN=x


Anyone can help me?
_________________
"Never argue with and idiot cuz he bring you down to his level and beat you with experience"
Back to top
View user's profile Send private message
megalomani
Tux's lil' helper
Tux's lil' helper


Joined: 08 Jun 2004
Posts: 77

PostPosted: Sat Jul 10, 2004 8:01 pm    Post subject: Reply with quote

See

http://groups.google.com/groups?q=syslog-ng&hl=en&lr=&ie=UTF-8&selm=slrnar61cb.296.msz%40fire.csn.tu-chemnitz.de&rnum=5

you need to change syslog-ng so that the lines:

filter f_firewall { match("IN=") and match("OUT="); };
filter f_no_firewall {not match("IN=") and not match("OUT="); };

destination firewall { file("/var/log/firewall.log" owner("root") \
group("adm") perm(0640)); };


log { source(src); filter(f_no_firewall); destination(console); };
log { source(src); filter(f_firewall); destination(firewall); };

are included
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum