Hello everyone,
I am trying to create a custom alert action where tcpdump capture will be triggered for the event's src and dest IPs.
I created a simple bash script for that:
#!/bin/bash
#Initiate tcpdump (3 dumps for 5mins each)
tcpdump -i ens33 -G 300 -W 3 -w /mnt/nfs/pcaps/pcap-%Y-%m-%d_%H.%M.%S
My problem is that this does not contain the src and dest IPs of the correlation event triggered. How can I pass these variables here in order not to capture the whole traffic, but only the one related between these two hosts?
Thanks
Chris
Hi,
The alert action script receives the configuration and results from the stdin in json format..
example:
in "result" there are your search results.. read this in python like:
result = sys.stdin.read() settings = json.loads(result)regards,
Andreas