Commit graph

2051 commits

Author SHA1 Message Date
Jon Siwek
25dcf210b1 Disable Broker tests in Coverity Scan cronjob build
Coverity has trouble analyzing them and they're contributing to
bringing the overall successfully-analyzed-compilation-unit ratio
below the required 85%.
2021-04-07 18:34:12 -07:00
Jon Siwek
c9874be22a Merge remote-tracking branch 'origin/topic/timw/1493-mobile-ipv6'
* origin/topic/timw/1493-mobile-ipv6:
  GH-1493: Fix build with -DENABLE_MOBILE_IPV6
2021-04-07 15:54:40 -07:00
Tim Wojtulewicz
2f69e32233 Merge remote-tracking branch 'origin/topic/jsiwek/intrusiveptr-hash'
* origin/topic/jsiwek/intrusiveptr-hash:
  Change TableVal::ToMap() to return ValPtr-indexed maps
  Add std::hash specialization for IntrusivePtr
  Move IntrusivePtr relational operators to zeek namespace
2021-04-07 11:13:05 -07:00
Jon Siwek
cd8f19328a Merge remote-tracking branch 'origin/topic/neverlord/gh-1408'
- Minor adjustments to header includes, whitespace, and a
  compiler warning fix during merge

* origin/topic/neverlord/gh-1408:
  Add new Timer class to the telemetry API
  Fix build with latest VectorVal API
  Update baselines
  Prefix telemetry BIFs with __
  Expose telemetry API to scripting land
  Add handle types for histogram metrics
  Move duplicated code to detail header
  Adhere to Zeek coding style
  Apply suggestions from code review
  Add telemetry Manager to Zeek setup / teardown
  Add missing whitespaces for Zeek coding style
  Add gauge metric types
  Add scaffold for new metrics API with counters
2021-04-05 14:21:44 -07:00
Jon Siwek
e6955d55dd Increase timeout of plugins.reader btest 2021-04-03 09:40:45 -07:00
Jon Siwek
fe6fd61468 Merge remote-tracking branch 'origin/topic/vern/cpp-prep-profiling'
* origin/topic/vern/cpp-prep-profiling:
  Add missing errno include to ProfileFunc.cc
  Adjust GetAttrs() usage in ProfileFunc::PreExpr() to const-reference
  Fix whitespace in ProfileFunc::PreExpr()
  Avoid redundant map/set searches in various ProfileFunc methods
  Improve detail::script_specific_filename()
  Use std::string_view in p_hash() to avoid string copies
  function profiling rewritten - more detailed info, supports global profiling
  track whether a given function/body should be included/skipped for optimization
2021-04-01 14:14:59 -07:00
Jon Siwek
2beaee9318 Add ssh to Alpine Dockerfile for retrieving external test repos 2021-03-31 11:59:04 -07:00
Jon Siwek
631f19377e Change ci/init-external-repos.sh to use base64 -d
The BusyBox version of `base64` does not have `--decode`.
2021-03-31 10:48:07 -07:00
Jon Siwek
ade37c1dfc Teach ci/init-external-repos.sh to consider user permissions
Any errors while setting up external/private test repo should fail the
task for PRs submitted by a user with write/admin permission.
2021-03-31 10:31:39 -07:00
Jon Siwek
f75da8bb08 Merge remote-tracking branch 'origin/topic/johanna/opensuse-leap'
* origin/topic/johanna/opensuse-leap:
  CI: Add OpenSUSE Leap 15.2
2021-03-31 09:56:30 -07: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
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
a5e7b2fec7 Update bundled CAF to 0.18.2 2021-03-27 14:18:30 -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
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
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
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
Tim Wojtulewicz
8fb30f1d62 Update CHANGES and VERSION since git failed to update the merge commit 2021-03-23 20:46:00 -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
Tim Wojtulewicz
4f24c02cd5 Merge remote-tracking branch 'origin/topic/vern/cpp-prep-fixes'
* origin/topic/vern/cpp-prep-fixes:
  fix for associating current scope with the name of enums; name tidying
  avoid infinite recursion in same_type() if it is analyzing recursive types
  remove iffy reliance on type punning that relies on interpreter's behavior
  fixes for propagating optimization options, and pruning script function analysis
2021-03-18 12:53:14 -07:00
Tim Wojtulewicz
9fc8f491ff Merge remote-tracking branch 'origin/topic/jsiwek/freebsd-lsan-disable'
* origin/topic/jsiwek/freebsd-lsan-disable:
  Prevent use of LeakSanitizer on FreeBSD
2021-03-17 13:48:51 -07:00
Tim Wojtulewicz
f53fb9a22e Merge remote-tracking branch 'olaldiko/master'
* olaldiko/master:
  Add tests for ERSPAN Type I patch
  Add ERSPAN Type I patch
2021-03-17 10:37:14 -07:00
Jon Siwek
07bad2d40e Merge remote-tracking branch 'origin/topic/seth/fix-smb-ts-fields'
* origin/topic/seth/fix-smb-ts-fields:
  Updating external test commit pointers
  ts fields in SMB logs now default to network_time()
2021-03-11 12:44:04 -08:00
Jon Siwek
6a0eae28a2 Merge remote-tracking branch 'origin/topic/jsiwek/gh-1432-file-extraction-buffered-io'
* origin/topic/jsiwek/gh-1432-file-extraction-buffered-io:
  GH-1432: Use buffered IO for file extraction
2021-03-10 12:29:35 -08:00
Jon Siwek
04f7259e97 Merge remote-tracking branch 'origin/topic/jsiwek/faster-plugin-search'
* origin/topic/jsiwek/faster-plugin-search:
  Avoid searching a directory for dynamic plugins multiple times
2021-03-10 12:06:05 -08:00
Johanna Amann
1d46bcbb81 Merge remote-tracking branch 'origin/topic/johanna/file-framework-mime-type-detection'
* origin/topic/johanna/file-framework-mime-type-detection:
  Fix potential mime type detection bug in IRC/FTP file_transferred event
2021-03-10 13:00:59 +00:00
Jon Siwek
f2d3bf3037 Merge remote-tracking branch 'origin/topic/vern/ast-opt'
- Removed a stray `printf()` from script-opt Reduce code

* origin/topic/vern/ast-opt: (23 commits)
  Tweak minor const-ref/std::move things in script-opt code
  Add alternative 'xform' baseline for test: broker.store.create-failure
  Add explicit return value to Reducer::SameOp()
  fixed AST transformation logic for boolean expressions
  don't know how I overlooked these minor test suite updates
  "opt" btest baseline updates due to AST optimizations changing printed code
  "opt" baseline exceptions due to incompatibility with optimize-AST and -u
  new "opt" btest alternative
  update to "xform" test suite baseline due to recent line number changes
  logic for driving AST optimization when requested
  methods implementing AST optimization (aliasing, constant propagation, CSE)
  helper class checking if common-subexpression elimination opportunity is valid
  helper function for comparing collections of definition points
  track more information about temporary variables
  simplify and tidy up some interfaces
  enable setting "-O optimize-AST" option
  fix for reducing operations on boolean vectors
  control whether checking for type-equivalence generates warnings
  remove unneeded virtual method (same as inherited method)
  accessors for additional Expr subclasses
  ...
2021-03-08 18:33:04 -08:00
Jon Siwek
285aaa53d7 Merge remote-tracking branch 'origin/topic/jsiwek/improve-broker-store-creation'
* origin/topic/jsiwek/improve-broker-store-creation:
  GH-1426: Improve handling of Broker data store creation failures
2021-03-08 12:29:56 -08:00
Johanna Amann
358d82eb38 Merge branch 'topic/keithjjones/openvpn' of https://github.com/keithjjones/zeek
* 'topic/keithjjones/openvpn' of https://github.com/keithjjones/zeek:
  Replace assert with if statement so OpenVPN can use this over UDP.  And fix spelling.
2021-03-08 11:25:32 +00:00
Jon Siwek
6946cffde2 Simplify some copy_string() usages in threading::Field 2021-03-05 17:38:36 -08:00
Jon Siwek
5f7fc043de Merge remote-tracking branch 'origin/topic/christian/canonicalize-zeek-config-includes'
* origin/topic/christian/canonicalize-zeek-config-includes:
  Avoid reporting paths repeatedly in zeek-config --include_dir
2021-03-05 16:14:37 -08:00
Jon Siwek
e2d2c75fe7 Merge remote-tracking branch 'origin/topic/jsiwek/zeekygen-code-links'
- Applied minor spelling/grammar suggestions from Johanna during merge

* origin/topic/jsiwek/zeekygen-code-links:
  Change update-zeekygen-docs.sh to set release branch in Sphinx config
  Teach Zeekygen to produce source-code-range information
  Add normalize_script_path() zeek::zeekygen::detail namespace
  Add starts_with()/ends_with() to zeek::util namespace
2021-03-01 11:37:29 -08:00
Tim Wojtulewicz
b8ec65ccf7 Merge remote-tracking branch 'origin/topic/jsiwek/coverity-lint'
* origin/topic/jsiwek/coverity-lint:
  Avoid superfluous string copies when adding to zeek::detail::sig_files
  Initialize an RD_Decorate member via std::move
  Fix invalid iterator comparison in UseDefs::FindSuccUsage()
2021-02-25 08:46:14 -07:00
Jon Siwek
39efbab3a4 Merge remote-tracking branch 'origin/topic/timw/remove-declaration-macros'
- Fixed forward decl. of ScriptInfo in zeekygen/Manager.h during merge

* origin/topic/timw/remove-declaration-macros:
  Remove obsolete ZEEK_FORWARD_DECLARE_NAMESPACED macros
2021-02-24 15:53:25 -08:00
Tim Wojtulewicz
e997eeeaab Merge remote-tracking branch 'origin/topic/christian/ci-add-centos-stream'
* origin/topic/christian/ci-add-centos-stream:
  Minor Fedora 32/33 updates in CI
  Add CentOS Stream 8 to CI
2021-02-24 15:11:10 -07:00
Jon Siwek
3179df9ab2 Merge remote-tracking branch 'origin/topic/jsiwek/file-analyzer-disabling'
* origin/topic/jsiwek/file-analyzer-disabling:
  Support explicit disabling of file analyzers
2021-02-24 12:37:24 -08:00
Jon Siwek
80221cb958 Merge remote-tracking branch 'origin/topic/vern/use-defs'
- Added explicit test case of "unused assignement" warning and
  &is_used suppression during merge.

* origin/topic/vern/use-defs:
  activate &is_used
  removed unnecessary statement flagged by Coverity (thanks, Jon!)
  Adjust reference/move nitpicks in use-def/reduce code
  Adjust some whitespace in UseDefs.cc
  updates to "usage" test suite alternative now that more warnings are generated
  suppress usage warning in baseline script
  "xform" alternative baseline update, needed for recent change to master
  baseline update due to shift in number of lines in base intel framework script
  environment variable (which has precedence) not flags for baseline usage test
  splitting out "usage" test suite alternative into -u/-uu versions
  adding &is_used attribute for base scripts - not actually needed yet, but will be once optimization is added
  removing unused assignments from base scripts
  driver glue for invoking use-def construction
  classes for managing and propagating use-defs
  enhancements/changes to the Reduce class in preparation for use-defs
  some tidying with smart pointers
  flag/environment variable for dumping use-defs
  &is_used attribute to suppress set-but-not-used usage warnings
  whitespace micro-preening
2021-02-23 12:11:24 -08:00
Jon Siwek
666afc58ed Update Broker submodule for performance/credit-tracking fixes 2021-02-16 12:34:11 -08:00
Jon Siwek
ba46ed25d9 Merge remote-tracking branch 'origin/topic/jsiwek/fix-pe-major-subsys'
* origin/topic/jsiwek/fix-pe-major-subsys:
  Fix `major_subsys_version` field in `pe_optional_header` event
2021-02-16 11:10:57 -08:00
Jon Siwek
f420cc2544 Fix CentOS 8 CI Dockerfile
The "PowerTools" repoid changed to "powertools":
https://bugs.centos.org/view.php?id=17920
2021-02-12 14:40:52 -08:00
Jon Siwek
a636f8edbd Merge fix for GH-1398 allowing null-bytes in ASCII input files
* Commits:
  Ascii reader test with 0-bytes
  Fix buffer overread in ascii formatter
2021-02-12 11:30:15 -08:00
Jon Siwek
3405b961b9 Remove RocksDB configure script options
Fixes GH-1399
2021-02-11 11:13:17 -08:00
Jon Siwek
0717e01b6b Merge remote-tracking branch 'origin/topic/timw/coverage-loop-fixes'
* origin/topic/timw/coverage-loop-fixes:
  Add a script to cleanup the file listing before sending to Coveralls
2021-02-11 10:56:42 -08:00
Jon Siwek
419c68b188 Merge remote-tracking branch 'origin/topic/jsiwek/parse-only-usage-errors'
* origin/topic/jsiwek/parse-only-usage-errors:
  Allow --parse-only to work with --usage-issues flag
2021-02-08 13:06:23 -08:00