This pushes the unit test kickoff down in the Zeek startup sequence, to give
plugins a chance to register. It also enforces deterministic mode for unit
testing, since without it some unit tests start to have nondeterministic results
at that stage.
* origin/topic/vern/CPP-cond:
fix btest comment to more accurately describe the test
clang-format issue
btests for erroneous script conditionals
avoid compiling-to-C++ for functions potentially influenced by conditionals
track the use of conditionals in functions and files
AST profiles track the associated function/body/expression
1466460: Uninitialized field in gtp-analyzer.pac
1462465: Null pointer dereference in CompositeHash::SingleValHash
1462463: Copy/paste error in TCPSessionAdapter::build_syn_packet_val
1462067: Uninitialized fields in Zinst
We also add a very basic yapf configuration file. Most of the changes in
this patch were performed automatically, but we broke one overly long
string into multiple components on `src/make_dbg_constants.py`.
All changes in this patch were performed automatically with `shfmt` with
configuration flags specified in `.pre-commit-config.yaml`.
In addition to fixing whitespace the roundtrip through shfmt's AST also
transforms command substitutions
`cmd`
# becomes
$(cmd)
and some redirects
>&2 echo "msg"
# becomes
echo >&2 "msg"
* origin/topic/vern/CPP-speedup:
use iterator-based idiom for check-if-present-then-access
const-ify member function
switch looping over vectors to use iterators
remove unused local variables
efficiency fix - return a reference rather than a copy of a map
fix for case-sensitive file systems
geez sometimes it's signed sometimes it's not
documentation updates
remove -O add-C++ and -O update-C++ options
extensive rewrite of generation & execution of run-time initialization
factoring out CPPEscape to be a standalone function
removing unused SubNetType class
* origin/topic/timw/1571-move-tunnel-analyzers-2:
Update NEWS and some minor fixes for docs/zeekygen
Remove the old session-based tunnel analyzers
Add GTPv1 packet analyzer, disable old analyzer
Add Teredo packet analyzer, disable old analyzer
Add VXLAN packet analyzer, disable old analyzer
Add Geneve packet analyzer, disable old analyzer
Add AYIYA packet analyzer, disable old analyzer
Add PacketAnalyzer::register_for_port(s) functions
Add analyzer_confirmation and analyzer_violation events
Add utility function for tunnel analyzers to setup encapsulation
Store some additional information in the packet during processing
Minor fix in UDP to avoid duplicating tunnels
Fix error text in IPTunnel analyzer
Change Packet::ip_hdr to be a shared_ptr so it can be copied into EncapsulatingConn
Add method for packet analyzers to register for protocol detection
Add concept of "parent" tag namespaces
Unify plugin::Component and plugin::TaggedComponent into a single class
Remove uses of deprecated Tag types
Unify all of the Tag types into one type
These allow packet analyzers to register ports as identifiers to forward from
parent analyzers, while also adding those ports to the now-global
Analyzer::ports table at the same time.
This allows us to create an EnumType that groups all of the analyzer
tag values into a single type, while still having the existing types
that split them up. We can then use this for certain events that benefit
from taking all of the tag types at once.
These two are almost always used in conjunction with each other, and
TaggedComponent is never used by itself. Combining them together into
a single class will help simplify some of the code around managing
the mapping between Tags and Components.
- Remove tag types for each component type (analyzer, etc)
- Add deprecated versions of the old types
- Remove unnecessary tag element from templates for TaggedComponent and ComponentManager
- Enable TaggedComponent to pass an EnumType when initializing Tag objects
- Update some tests that are affected by the tag enum values changing order
* origin/topic/johanna/openssl-3-compat:
Update cmake submodule for OpenSSL 3.0 changes
OpenSSL 3: normalize self-signed-cert error message
Make cmake & ci like OpenSSL 3.0
Add OpenSSL 3.0 CI test
OpenSSL 3: fix warnings and tests
Switch OpaqueVal hashing back to legacy OpenSSL implementation
Fixes GH-1379