You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
suricata/doc/userguide
Samaresh Kumar Singh 565e138754 pcap-file: skip setvbuf on non-seekable streams
Reading a pcap from /dev/stdin or a named pipe currently fails with "failed to get first packet timestamp. pcap_next_ex(): -1" because InitPcapFile calls setvbuf on the FILE* underlying the pcap handle after libpcap has already consumed the pcap header. On a non-seekable fd glibc cannot recover from that and the next read returns -1.

Detect non-regular files via fstat and skip setvbuf in that case so the read keeps working on pipes, fifos and stdin.

Accept pcap-file.buffer-size values of 0, which disables setvbuf buffering as an explicit opt-out, or PCAP_FILE_BUFFER_SIZE_MIN (4 KiB) to PCAP_FILE_BUFFER_SIZE_MAX (64 MiB). Treat any non-zero setvbuf return value as an error, not just negative values.

When pcap-file.buffer-size fails to parse, retain the default buffer size instead of falling through and setting it to 0. The branches are now mutually exclusive so only one of the parse-error, accepted, or out-of-range messages is logged.

Update the user guide: --pcap-file-buffer-size now documents valid values of 0 (disables setvbuf buffering) or 4 KiB to 64 MiB, and pcap-file.rst notes that 0 is the opt-out for non-seekable sources such as stdin and named pipes.
Bug: #8464.
3 months ago
..
3rd-party-integration doc/userguide: new 3rd party section, add bluecoat 8 years ago
_static doc/userguide: avoid horizontal scroll on rtd 3 years ago
appendix doc: adjust for master to main rename 1 year ago
capture-hardware pcap-file: skip setvbuf on non-seekable streams 3 months ago
configuration doc/firewall: update hooks & configuration examples 3 months ago
devguide http2: split progress per direction 3 months ago
file-extraction doc: minor verbiage tweaks and reST fix 11 months ago
firewall doc/firewall: update hooks & configuration examples 3 months ago
install doc/userguide: update windivert instructions 9 months ago
ips src: doc: remove double-space typos 8 months ago
licenses doc: convert fancy quotes to straight quotes 7 years ago
lua http-log: remove support for http-log 3 months ago
manpages doc: improve manpage of suricatasc 4 months ago
output doc: dhcp eve note for option 52 overload 3 months ago
partials pcap-file: skip setvbuf on non-seekable streams 3 months ago
performance http-log: remove support for http-log 3 months ago
plugins doc/ndpi: move ndpi docs to new plugins section 1 year ago
protocols doc/userguide: add initial protocols overview 12 months ago
reputation doc: spelling 3 years ago
rule-management userguide: add references to rules/README to docs 6 months ago
rules doc/sctp: add sctp keywords 3 months ago
upgrade doc: upgrade notes for changes to ike output 11 months ago
.gitignore doc/userguide: generate eve documentation 2 years ago
Makefile.am userguide/Makefile: don't add "install" to EXTRA_DIST 7 months ago
Makefile.sphinx doc: hook sphinx into build 10 years ago
README.md devguide: move into userguide as last chapter 5 years ago
acknowledgements.rst doc: Add missing contributors to ack file 1 year ago
command-line-options.rst doc: Improve grammar, spelling and clarifications 6 years ago
conf.py doc: address config conversion note 4 months ago
convert.py doc/optimization: move "convert.py" to Python3 3 years ago
docutils.conf doc: add docutils.conf to disable smart quotes 3 years ago
generate-evedoc.sh doc/userguide: generate eve documentation 2 years ago
index.rst doc/userguide: add initial protocols overview 12 months ago
initscripts.rst doc: Improve grammar, spelling and clarifications 6 years ago
install.rst docs: use correct suricata version mentions 8 months ago
make-sense-alerts.rst doc: Improve grammar, spelling and clarifications 6 years ago
public-data-sets.rst doc: add more public datasets 7 months ago
quickstart.rst doc: move more rules to dedicated css container 5 months ago
requirements.txt docs: adjust readthedocs config to new options 3 years ago
security.rst doc: fix typo /var/run/suricata in file permissions docs. 12 months ago
support-status.rst devguide: make 'contributing' a chapter 3 years ago
unix-socket.rst doc: adjust for master to main rename 1 year ago
upgrade.rst flowbits: deprecate toggle command 3 months ago
verifying-source-files.rst docs: use correct suricata version mentions 8 months ago
what-is-suricata.rst doc: Improve grammar, spelling and clarifications 6 years ago

README.md

Suricata User Guide

This directory contains the Suricata Guide. The Suricata Developer's guide is included as a chapter of the Guide. The Sphinx Document Generator is used to build the documentation. For a primer os reStructuredText see the reStructuredText Primer.

Verifying Changes

There are a number of output formats to choose from when making the source documentation locally (e.g. html, pdf, man).

The documentation source can be built with make -f Makefile.sphinx html. Substitute the 'html' word for desired output format.

There are different application dependencies based on the output desired.