actual i have some Problems with the analysis of PCAP's. My goal is to get the logs without using tcpreplay.
I know Bro and Snort both have functions for this purpose. Are there any experiences with it ?
When i run snort with a PCAP file than the following WARNING ist generated for nearly every packet:
WARNING: No preprocessors configured for policy 0.
03/31-22:35:01.779999 xxx.xxx.xxx.xxx:443 -> xxx.xxx.xxx.xxx:55496
TCP TTL:239 TOS:0x0 ID:12567 IpLen:20 DgmLen:306 DF
***AP*** Seq: 0x624A3DCB Ack: 0xE62123B1 Win: 0x175A TcpLen: 32
TCP Options (3) => NOP NOP TS: 3469726148 272270
=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+
What can i do ?
Tim
Tim,
Have you tried running Snort with the configuration file defined?
Ex. snort -c /etc/nsm/hostname-interface/snort.conf
Thanks,
Wes
You may need to stop the other Snort process, then do this, or copy the conf file, and run it from that.
Thanks,
Wes
--
Follow Security Onion on Twitter!
https://twitter.com/securityonion
---
You received this message because you are subscribed to the Google Groups "security-onion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to security-onion+unsubscribe@googlegroups.com.
To post to this group, send email to security-onion@googlegroups.com.
Visit this group at https://groups.google.com/group/security-onion.
For more options, visit https://groups.google.com/d/optout.
Tim,
I can successfully do this with the following:
--Copy snort.conf file in /etc/nsm/hostname-interface/
"sudo cp /etc/nsm/hostname-interface/snort.conf /etc/nsm/hostname-interface/snort2.conf"
--Run snort
sudo snort -c /etc/nsm/hostname-interface/snort2.conf -r pcap.pcap
You could, of course, copy the conf file to another dir, but you would need to make sure you are able to access classification.config, etc -- I would try it like this first to see if it works and change it from there, if necessary.
Thanks,
Wes
To add, is there any reason you don't want to use tcpreplay?
Thanks,
Wes
...
WARNING: flowbits key 'irc.start' is set but not ever checked.
WARNING: flowbits key 'ET.TorIP' is set but not ever checked.
WARNING: flowbits key 'file.crx' is set but not ever checked.
WARNING: flowbits key 'file.wri' is set but not ever checked.
WARNING: flowbits key 'file.abc' is set but not ever checked.
WARNING: flowbits key 'ET.Evil' is set but not ever checked.
WARNING: flowbits key 'file.esignal' is set but not ever checked.
WARNING: flowbits key 'file.qcp' is set but not ever checked.
WARNING: flowbits key 'file.rtx' is set but not ever checked.
WARNING: flowbits key 'file.s3m' is set but not ever checked.
...
and this is the end of output:
531 out of 1024 flowbits in use.
[ Port Based Pattern Matching Memory ]
+- [ Aho-Corasick Summary ] -------------------------------------
| Storage Format : Full-Q
| Finite Automaton : DFA
| Alphabet Size : 256 Chars
| Sizeof State : Variable (1,2,4 bytes)
| Instances : 395
| 1 byte states : 372
| 2 byte states : 21
| 4 byte states : 2
| Characters : 528658
| States : 333270
| Transitions : 48163449
| State Density : 56.5%
| Patterns : 31939
| Match States : 31675
| Memory (MB) : 246.00
| Patterns : 3.45
| Match Lists : 11.20
| DFA
| 1 byte states : 2.74
| 2 byte states : 93.33
| 4 byte states : 134.59
+----------------------------------------------------------------
[ Number of patterns truncated to 20 bytes: 5460 ]
ERROR: pfring DAQ does not support read-file.
Fatal Error, Quitting..
So i am not sure whats the problem. Perhaps because of my upgrade of Ubuntu and the Update (soup)?
The normal detection over the listening interface seems to work fine.
I think tcpreplay would be easiest, and you wouldn't have to modify any files -- as far as dropping packets, I think that would be dependent on the amount of resources you have available and how well the sensor is tuned. You can tune PF_RING/IDS processes here:
https://github.com/Security-Onion-Solutions/security-onion/wiki/PF_RING
I'm not sure about the DAQ read-file error mentioned in your output -- if you can post the output of sostat-redacted (attached as a text file) for your machine, it may help to identify if there is something different with your installation of PF_RING, compared to what should be the currently installed version.
Thanks,
Wes
Your pf_ring version looks okay -- I'm not sure why you would get that error (mine says pfring DAQ configured to passive). Do you see the same type of output in /var/log/nsm/hostname-interface/snortu-1.log?
I would check the log(s) to make sure the instance you have already have running is configured correctly.
Thanks,
Wes
Okay, I lied, I had a typo in my command. It did the same thing for me (pfring DAQ error). Your pf_ring version looks fine, however, you may want to follow the associated guidance for the large amount of ELSA buffers and ELSA Index Date Range.
You will need to tell it to use the pcap read-file DAQ mode as follows:
Add the following: --daq pcap --daq-mode read-file
and '-r pcap.pcap'
to the way snort is already run (should be able to find with 'ps aux | grep snort')
to get the following (or similar):
sudo snort --daq pcap --daq-mode read-file -c /etc/nsm/hostname-interface/snort.conf -r pcap.pcap -u sguil -g sguil -i eth1 -l /nsm/sensor_data/hostname-interface/snort-1 --perfmon-file /nsm/sensor_data/hostname-interface/snort1-stats -U --snaplen 1524
See if that works for you.
Thanks,
Wes
Are you pointing to the original snort configuration file?
Wow that seems to work better ... but still not sure because i can not find the alerts in sguil :(
Nearly the same as yours but without -i eth1. This also wasn't in the 'ps aux | grep snort' version.
sudo snort --daq pcap --daq-mode read-file -c /etc/nsm/seconion-eth1/snort.conf -r byod.pcapng -u sguil -g sguil -i eth1 -l /nsm/sensor_data/seconion-eth1/snort-1 --perfmon-file /nsm/sensor_data/seconion-eth1/snort-1.stats -U --snaplen 1524 -N
As you can see i use the original one.