Commit graph

11657 commits

Author SHA1 Message Date
Johanna Amann
2f39b66828 CI: Add OpenSUSE Leap 15.2 2021-03-31 16:00:33 +01:00
Jon Siwek
75ebc5bca1 Merge branch 'fix_timeval' of https://github.com/abenson/zeek
* 'fix_timeval' of https://github.com/abenson/zeek:
  Fix incomplete-type for struct timeval
2021-03-30 14:58:00 -07:00
Andrew Benson
2ad482535e Fix incomplete-type for struct timeval 2021-03-29 22:41:31 -05:00
Jon Siwek
c033bd20aa Merge remote-tracking branch 'origin/topic/vern/global-stmts'
* origin/topic/vern/global-stmts:
  whitespace adjustment
  "balance" tests with multiple Zeek scripts to load the same elements
  put global statements into a quasi-function to support script optimization
2021-03-29 15:42:43 -07:00
Jon Siwek
b5d1c4342e Merge remote-tracking branch 'origin/topic/jsiwek/misc-val-tweaks'
* origin/topic/jsiwek/misc-val-tweaks:
  Fix sign-compare compiler warning in coerce_to_record()
  Fix maybe-uninitialized warning in ZVal::ToVal()
  Change RecordVal::GetFieldAs() to use std::vector::operator[]
  Add RecordVal::AssignField() and use it in supervisor code
2021-03-29 13:19:57 -07:00
Jon Siwek
e7b8609613 Merge remote-tracking branch 'origin/topic/jsiwek/gh-960-auxil-include-order'
* origin/topic/jsiwek/gh-960-auxil-include-order:
  GH-960: Fix include order of bundled header files
2021-03-29 13:15:51 -07:00
Jon Siwek
a5e7b2fec7 Update bundled CAF to 0.18.2 2021-03-27 14:18:30 -07:00
Jon Siwek
43d9bda007 Fix sign-compare compiler warning in coerce_to_record() 2021-03-26 21:59:30 -07:00
Jon Siwek
db975ac08e Fix maybe-uninitialized warning in ZVal::ToVal()
Some compilers warn that 'v' may be used uninitialized but shouldn't be
the case in practice since all cases are handled, making it impossible.
2021-03-26 19:10:36 -07:00
Jon Siwek
7047eb92d8 Change RecordVal::GetFieldAs() to use std::vector::operator[]
Since the method claims it's up to the user to ensure the field exists
before calling, the extra bounds-checking done by std::vector::at()
isn't needed.
2021-03-26 19:02:24 -07:00
Jon Siwek
2855df63ce Add RecordVal::AssignField() and use it in supervisor code
This is a convenience method to assign a known record field value by
field name.  May also be useful to reduce warnings from static analysis
(e.g. Coverity) about not checking for negative return values before
assigning since that now flows through a [[noreturn]] error path.
2021-03-26 18:57:42 -07:00
Jon Siwek
7bf885b0b8 Merge remote-tracking branch 'origin/topic/vlad/expose_supervisor_rotation_func'
- Restored a deprecated version of 'supervisor_rotation_format_func'
  during merge.

* origin/topic/vlad/expose_supervisor_rotation_func:
  Rename supervisor_rotation_format_func to archiver_rotation_format_func, and expose it for non-supervised setups
2021-03-26 17:18:52 -07:00
Jon Siwek
0eaeca6569 Update submodule(s) [nomail] [skip ci] 2021-03-26 16:51:30 -07:00
Jon Siwek
867abd0b99 Merge remote-tracking branch 'origin/topic/johanna/gh-1454'
* origin/topic/johanna/gh-1454:
  Heartbleed: fix substraction order.
2021-03-26 16:46:42 -07:00
Jon Siwek
a0859276bf Merge remote-tracking branch 'origin/topic/timw/analyzer-crash'
* origin/topic/timw/analyzer-crash:
  Fix crash in Analyzer::ForwardPacket due to recursive analyzer calls.
2021-03-26 16:40:12 -07:00
Jon Siwek
444fd8ff43 GH-960: Fix include order of bundled header files
Previously, a system-wide installation of any bundled auxil/ software
(like CAF) may get found/included rather than the bundled version and
possibly break the build.
2021-03-26 16:26:49 -07:00
Vlad Grigorescu
acfb21c5a6 Rename supervisor_rotation_format_func to archiver_rotation_format_func, and expose it for non-supervised setups
Closes #1463
2021-03-26 15:26:48 -05:00
Tim Wojtulewicz
fdf34c1f7b Include git sha in request to benchmark host 2021-03-25 17:38:02 -07:00
zeek-bot
cbd84dbe52 Update doc submodule [nomail] [skip ci] 2021-03-26 00:35:30 +00:00
Tim Wojtulewicz
d724df0b03 Merge remote-tracking branch 'origin/topic/vern/cpp-prep-factoring'
* origin/topic/vern/cpp-prep-factoring:
  test suite update due to factoring out coerce_to_record()
  removal of vestigial #include's (breaking an include loop in the process)
  better method name: HasCopySemantics()
  Use STL functionality to initialize coercion map
  comments for factored-out index slice functions
  support for subclassing ScriptFunc's, esp. for alternate lambda closures
  factor out record coercion; modernize management of coercion "map"
  lower-level method for adding fields to records
  factor out "print" statement's execution functionality
  functions for indexing slices and strings
  new function for getting the location, if any, associated with the current call
2021-03-25 11:38:33 -07:00
Tim Wojtulewicz
4015beb732 Fix crash in Analyzer::ForwardPacket due to recursive analyzer calls.
The change in 44f558df7b that made analyzer_list
a std::vector instead of a std::list doesn't take into account that in some
cases an analyzer may chain back into itself, such as with UDP-in-UDP tunnels.
In these cases, the second call to ForwardPacket may cause iterator
invalidation, leading to a crash.
2021-03-25 08:45:38 -07:00
Johanna Amann
c23e3ca105 Heartbleed: fix substraction order.
The larger number was substracted from the smaller one leading to an
integer overflow. However, no information was lost due to everything
also being present in the notice message.

Fixes GH-1454
2021-03-25 13:41:12 +00:00
Vern Paxson
e5a0b2c04c whitespace adjustment 2021-03-24 21:52:20 -07:00
Vern Paxson
3139cf2594 "balance" tests with multiple Zeek scripts to load the same elements 2021-03-24 21:37:26 -07:00
Vern Paxson
95b89be571 put global statements into a quasi-function to support script optimization 2021-03-24 21:22:03 -07:00
Jon Siwek
9ff3abb72c Update submodule(s) [nomail] [skip ci] 2021-03-24 18:05:46 -07:00
Jon Siwek
a31ad5d9da Merge branch 'master' of https://github.com/dopheide-esnet/zeek
* 'master' of https://github.com/dopheide-esnet/zeek:
  Sometimes user_agent is missing
2021-03-24 17:03:26 -07:00
Jon Siwek
c553df5dfe Add bin_dir setting for default zkg config file
Which defaults to `${zeek_install_prefix}/bin`, same as what a
standalone `zkg autoconfig` would use.
2021-03-24 15:53:10 -07:00
Vern Paxson
a288800b41 test suite update due to factoring out coerce_to_record() 2021-03-24 15:16:03 -07:00
Vern Paxson
a2e7dd82c4 removal of vestigial #include's (breaking an include loop in the process) 2021-03-24 15:15:19 -07:00
Vern Paxson
3e07564fb9 better method name: HasCopySemantics() 2021-03-24 15:03:03 -07:00
Vern Paxson
a7fcc7a5d8 Use STL functionality to initialize coercion map 2021-03-24 15:03:03 -07:00
Vern Paxson
8782894d7d comments for factored-out index slice functions 2021-03-24 15:03:03 -07:00
Vern Paxson
78f18b4fa6 support for subclassing ScriptFunc's, esp. for alternate lambda closures 2021-03-24 15:03:03 -07:00
Vern Paxson
91c2e05099 factor out record coercion; modernize management of coercion "map" 2021-03-24 15:03:00 -07:00
Vern Paxson
5f5ba3881c lower-level method for adding fields to records 2021-03-24 15:01:33 -07:00
Vern Paxson
22776167bb factor out "print" statement's execution functionality 2021-03-24 15:01:33 -07:00
Vern Paxson
b792feccab functions for indexing slices and strings 2021-03-24 15:01:19 -07:00
Michael Dopheide
83d5b44462 Sometimes user_agent is missing 2021-03-24 15:48:09 -05:00
Vern Paxson
8f2637decb new function for getting the location, if any, associated with the current call 2021-03-24 09:36:21 -07:00
Tim Wojtulewicz
8fb30f1d62 Update CHANGES and VERSION since git failed to update the merge commit 2021-03-23 20:46:00 -07:00
Tim Wojtulewicz
f45df63cd0 Merge remote-tracking branch 'origin/topic/vern/zval'
* origin/topic/vern/zval: (42 commits)
  whitespace tweaks
  resolved some TODO comments
  remove unnecessary casts, and change necessary ones to use static_cast<>
  explain cmp_func default
  change functions for ZVal type management to static members
  fix some unsigned/signed integer warnings
  address lint concern about uninitialized variable
  Remove use of obsolete forward-declaration macros
  fix #include's that lack zeek/ prefixes
  explicitly populate holes created in vectors
  fixes for now-incorrect assumption that GetField always returns an existing ValPtr
  memory management for assignment to vector elements
  memory management for assignment to record fields
  destructor cleanup from ZAM_vector/ZAM_record
  fix #include's that lack zeek/ prefixes
  overlooked another way in which vector holes can be created
  initialize vector holes to the correct corresponding type
  explicitly populate holes created in vectors
  fix other instances of GetField().get() assuming long-lived ValPtr's
  fix for now-incorrect assumption that GetField always returns an existing ValPtr
  ...
2021-03-23 20:44:19 -07:00
Jon Siwek
569830526f Increase timeout of openflow.log-cluster btest 2021-03-23 19:34:34 -07:00
Jon Siwek
f46d3dec8f Merge remote-tracking branch 'origin/topic/vern/cpp-new-func'
- Removed a couple of dead statements during merge

* origin/topic/vern/cpp-new-func:
  option for deterministic descriptions of sets & tables
  determinism for concurrent Zeek test suite invocations; split out deprecations
  disambiguate descriptions of enums; include attributes when describing records
  more liberal view of attribute equality; allow suppressing attr type-checking
  support for operations on sets that return new values
  low-level addition of enum values
  sundry accessors/cast-ers; RE_Matcher's track their construction values
  convenience functions for comparing IP addresses
2021-03-23 19:27:11 -07:00
Jon Siwek
52b3e159a4 Merge remote-tracking branch 'origin/topic/vlad/configure_plugin_dir'
* origin/topic/vlad/configure_plugin_dir:
  Expose a configure-time option to set the plugin path.
2021-03-23 17:29:35 -07:00
Jon Siwek
fd7402e8d6 Merge remote-tracking branch 'origin/topic/timw/analyzer-iterators'
- During merge, simplified the API docs for Analyzer::DeleteChild()
  (found it unclear/unnecessary to refer to any `std` container types)

* origin/topic/timw/analyzer-iterators:
  Clean up iterator usage in Analyzer
2021-03-23 16:33:17 -07:00
Vern Paxson
d5b523cd2c whitespace tweaks 2021-03-22 21:23:15 -07:00
Vern Paxson
46e303b000 resolved some TODO comments 2021-03-22 21:20:52 -07:00
zeek-bot
94b03d4edd Update doc submodule [nomail] [skip ci] 2021-03-19 00:43:01 +00:00
Vern Paxson
9e4c87b112 option for deterministic descriptions of sets & tables 2021-03-18 16:18:32 -07:00