mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-26 02:42:58 +02:00
Fix regex to extract firewall chain for ipv6 in showrequestfrom*.dat
If bridged ipv6 is used, $iface is taken from PHYSIN In the log line the order of fields is "... IN=XY OUT=XY PHYSIN=XY ..." Signed-off-by: Michael Eitelwein <michael@eitelwein.net>
This commit is contained in:
@@ -303,7 +303,7 @@ foreach $_ (@slice)
|
||||
my $srcport = ''; my $dstport = '';
|
||||
|
||||
# If ipv6 uses bridge, the use PHYSIN, otherwise use IN
|
||||
if ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(PHYSIN=.*)$/) {}
|
||||
if ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)(PHYSIN=.*)$/) {}
|
||||
elsif ($_ =~ /(^.* ..:..:..) [\w\-]+ kernel:(.*)(IN=.*)$/) {}
|
||||
my $timestamp = $1; my $chain = $2; my $packet = $3;
|
||||
$timestamp =~ /(...) (..) (..:..:..)/;
|
||||
|
||||
Reference in New Issue
Block a user