The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

IPTables::Log - Parse iptables/netfilter syslog messages.

SYNOPSIS

  use IPTables::Log;
  my $l = IPTables::Log->new;
  my $s = $l->create_set;
  my $r = $s->create_record({text => '...IN=eth0 OUT=eth1 MAC=00:...'});
  $r->parse;
  $s->add($r);
  

DEPENDENCIES

  • Carp - for error generation

  • Class::Accessor - for accessor methods

  • Data::GUID - for GUID generation

  • NetAddr::IP - for the src and dst methods

CONSTRUCTORS

Log->new

Creates a new IPTables::Log object.

METHODS

$log->create_set(no_header = 0|1>)

Creates a new IPTables::Log::Set object.

Setting no_header to 1 makes IPTables::Log::Set::Record assume that the timestamp and hostname at the beginning of the message is missing (for example, if it's already been processed by another utility).

See IPTables::Log::Set and IPTables::Log::Set::Record for further details.

CAVEATS

It parses log entries. It doesn't do much else, yet.

BUGS

None that I'm aware of ;-)

AUTHOR

This module was written by Andy Smith <andy.smith@netprojects.org.uk>.

COPYRIGHT

$Id: Log.pm 21 2010-12-17 21:07:37Z andys $

(c)2009 Andy Smith (http://andys.org.uk/)

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.