Partial match group skipped

This commit is contained in:
Alexandre Dulaunoy 2015-02-01 14:41:15 +01:00
parent 8411b99e9c
commit 19ee42fa3e

View file

@ -34,10 +34,11 @@ for l in fileinput.input(args.r):
cert = None cert = None
if flow.search(l): if flow.search(l):
m = flow.match(l) m = flow.match(l)
session = m.group(1) if m is not None:
srcip = m.group(2) session = m.group(1)
dstip = m.group(3) srcip = m.group(2)
dstport = m.group(4) dstip = m.group(3)
dstport = m.group(4)
if (cert is True): if (cert is True):
certstring += l.rstrip('\n') certstring += l.rstrip('\n')