Rather than performing out-of-band bulk packet captures, configure the Manager to automatically capture relevant network traffic from each clone, in order to detect when a compromise occurs. This data should be in PCAP format and should be eventually provided to the Drone web service, referenced by the fingerprint generated.
Net::Packet::Dump looks promising, but currently has a hardcoded snaplen of 1514. I'm trying to contact the author to make this snaplen configurable (65535).
Here's a possible (untested) patch to Dump.pm (Net::Packet::Dump v3.25)
-
Dump.pm
| old |
new |
|
| 35 | 35 | noLayerWipe |
|---|
| 36 | 36 | mode |
|---|
| 37 | 37 | keepTimestamp |
|---|
| | 38 | snaplen |
|---|
| 38 | 39 | _pid |
|---|
| 39 | 40 | _pcapd |
|---|
| 40 | 41 | _dumper |
| … | … | |
| 82 | 83 | frames => [], |
|---|
| 83 | 84 | mode => NP_DUMP_MODE_ONLINE, |
|---|
| 84 | 85 | keepTimestamp => 0, |
|---|
| | 86 | snaplen => 1514, |
|---|
| 85 | 87 | _sDataAwaiting => 0, |
|---|
| 86 | 88 | _sName => "netpacket-tmp-$$.@{[getRandom32bitsInt()]}.storable", |
|---|
| 87 | 89 | @_, |
| … | … | |
| 219 | 221 | my $err; |
|---|
| 220 | 222 | my $pd = Net::Pcap::open_live( |
|---|
| 221 | 223 | $self->[$__dev], |
|---|
| 222 | | 1514, |
|---|
| | 224 | $self->[$__snaplen], |
|---|
| 223 | 225 | $self->[$__promisc], |
|---|
| 224 | 226 | 1000, |
|---|
| 225 | 227 | \$err, |
| … | … | |
| 641 | 643 | file => 'live.pcap', |
|---|
| 642 | 644 | filter => 'tcp', |
|---|
| 643 | 645 | promisc => 1, |
|---|
| | 646 | snaplen => 1514, |
|---|
| 644 | 647 | noStore => 1, |
|---|
| 645 | 648 | keepTimestamp => 1, |
|---|
| 646 | 649 | unlinkOnClean => 0, |
| … | … | |
| 757 | 760 | |
|---|
| 758 | 761 | If you want to capture in promiscuous mode, set it to 1. Default to 0. |
|---|
| 759 | 762 | |
|---|
| | 763 | =item B<snaplen> |
|---|
| | 764 | |
|---|
| | 765 | If you want to capture a different snaplen, set it a number. Default to 1514. |
|---|
| | 766 | |
|---|
| 760 | 767 | =item B<link> |
|---|
| 761 | 768 | |
|---|
| 762 | 769 | This attribute tells which datalink type is used for .pcap files. |
| … | … | |
| 829 | 836 | |
|---|
| 830 | 837 | promisc: 0 |
|---|
| 831 | 838 | |
|---|
| | 839 | snaplen: 1514 |
|---|
| | 840 | |
|---|
| 832 | 841 | timeoutOnNext: 3 |
|---|
| 833 | 842 | |
|---|
| 834 | 843 | isRunning: 0 |